~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/branch.py

  • Committer: Andrew Bennetts
  • Date: 2006-08-10 01:52:46 UTC
  • mto: (2018.5.1 split-smart)
  • mto: This revision was merged to the branch mainline in revision 2435.
  • Revision ID: andrew.bennetts@canonical.com-20060810015246-f155b70b3aecb0c4
Flesh out more Remote* methods needed to open and initialise remote branches/trees/repositories.

Show diffs side-by-side

added added

removed removed

Lines of Context:
760
760
        if not _found:
761
761
            format = BranchFormat.find_format(a_bzrdir)
762
762
            assert format.__class__ == self.__class__
763
 
        transport = a_bzrdir.get_branch_transport(None)
764
 
        control_files = LockableFiles(transport, 'lock', lockdir.LockDir)
765
 
        return BzrBranch5(_format=self,
766
 
                          _control_files=control_files,
767
 
                          a_bzrdir=a_bzrdir,
768
 
                          _repository=a_bzrdir.find_repository())
 
763
        try:
 
764
            transport = a_bzrdir.get_branch_transport(None)
 
765
            control_files = LockableFiles(transport, 'lock', lockdir.LockDir)
 
766
            return BzrBranch5(_format=self,
 
767
                              _control_files=control_files,
 
768
                              a_bzrdir=a_bzrdir,
 
769
                              _repository=a_bzrdir.find_repository())
 
770
        except NoSuchFile:
 
771
            raise NotBranchError(path=transport.base)
769
772
 
770
773
    def __str__(self):
771
774
        return "Bazaar-NG Metadir branch format 5"