/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to errors.py

Fix regression in git-import.

Show diffs side-by-side

added added

removed removed

Lines of Context:
27
27
    """The base-level exception for bzr-git errors."""
28
28
 
29
29
 
30
 
class GitCommandError(BzrGitError):
31
 
    """Raised when spawning 'git' does not return normally."""
32
 
 
33
 
    _fmt = 'Command failed (%(returncode)s): command %(command)s\n%(stderr)s'
34
 
 
35
 
    def __init__(self, command, returncode, stderr):
36
 
        self.command = command
37
 
        self.returncode = returncode
38
 
        self.stderr = stderr
39
 
 
40
 
 
41
30
class NoSuchRef(BzrGitError):
42
 
    """Raised when a ref can not be found.""" 
 
31
    """Raised when a ref can not be found."""
43
32
 
44
33
    _fmt = "The ref %(ref)s was not found."
45
 
    
 
34
 
46
35
    def __init__(self, ref, present_refs=None):
47
36
        self.ref = ref
48
37
        self.present_refs = present_refs
62
51
 
63
52
class GitSmartRemoteNotSupported(bzr_errors.BzrError):
64
53
    _fmt = "This operation is not supported by the Git smart server protocol."
65
 
 
66
 
 
67
 
class GhostRevision(bzr_errors.NoSuchRevision):
68
 
    _fmt = "Revision %(revision)s is a ghost; unable to represent in Git."""