~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/errors.py

  • Committer: Vincent Ladeuil
  • Date: 2009-06-22 12:52:39 UTC
  • mto: (4471.1.1 integration)
  • mto: This revision was merged to the branch mainline in revision 4472.
  • Revision ID: v.ladeuil+lp@free.fr-20090622125239-kabo9smxt9c3vnir
Use a consistent scheme for naming pyrex source files.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1173
1173
class DivergedBranches(BzrError):
1174
1174
 
1175
1175
    _fmt = ("These branches have diverged."
1176
 
            " Use the merge command to reconcile them.")
 
1176
            " Use the missing command to see how.\n"
 
1177
            "Use the merge command to reconcile them.")
1177
1178
 
1178
1179
    def __init__(self, branch1, branch2):
1179
1180
        self.branch1 = branch1
1227
1228
            not_ancestor_id=not_ancestor_id)
1228
1229
 
1229
1230
 
1230
 
class InstallFailed(BzrError):
1231
 
 
1232
 
    def __init__(self, revisions):
1233
 
        revision_str = ", ".join(str(r) for r in revisions)
1234
 
        msg = "Could not install revisions:\n%s" % revision_str
1235
 
        BzrError.__init__(self, msg)
1236
 
        self.revisions = revisions
1237
 
 
1238
 
 
1239
1231
class AmbiguousBase(BzrError):
1240
1232
 
1241
1233
    def __init__(self, bases):
2169
2161
    _fmt = "To use this feature you must upgrade your repository at %(path)s."
2170
2162
 
2171
2163
 
 
2164
class RichRootUpgradeRequired(UpgradeRequired):
 
2165
 
 
2166
    _fmt = ("To use this feature you must upgrade your branch at %(path)s to"
 
2167
           " a format which supports rich roots.")
 
2168
 
 
2169
 
2172
2170
class LocalRequiresBoundBranch(BzrError):
2173
2171
 
2174
2172
    _fmt = "Cannot perform local-only commits on unbound branches."
2175
2173
 
2176
2174
 
2177
 
class InvalidProgressBarType(BzrError):
2178
 
 
2179
 
    _fmt = ("Environment variable BZR_PROGRESS_BAR='%(bar_type)s"
2180
 
            " is not a supported type Select one of: %(valid_types)s")
2181
 
 
2182
 
    def __init__(self, bar_type, valid_types):
2183
 
        BzrError.__init__(self, bar_type=bar_type, valid_types=valid_types)
2184
 
 
2185
 
 
2186
2175
class UnsupportedOperation(BzrError):
2187
2176
 
2188
2177
    _fmt = ("The method %(mname)s is not supported on"
2850
2839
    pass
2851
2840
 
2852
2841
 
2853
 
class NotATerminal(BzrError):
2854
 
 
2855
 
    _fmt = 'Unable to ask for a password without real terminal.'
2856
 
 
2857
 
 
2858
2842
class UnableEncodePath(BzrError):
2859
2843
 
2860
2844
    _fmt = ('Unable to encode %(kind)s path %(path)r in '
2965
2949
        BzrError.__init__(self, invalid_id=invalid_id)
2966
2950
 
2967
2951
 
 
2952
class JailBreak(BzrError):
 
2953
 
 
2954
    _fmt = "An attempt to access a url outside the server jail was made: '%(url)s'."
 
2955
 
 
2956
    def __init__(self, url):
 
2957
        BzrError.__init__(self, url=url)
 
2958
 
 
2959
 
2968
2960
class UserAbort(BzrError):
2969
2961
 
2970
2962
    _fmt = 'The user aborted the operation.'
3030
3022
 
3031
3023
    def __init__(self, repository):
3032
3024
        self.repository = repository
 
3025
 
 
3026
 
 
3027
class LossyPushToSameVCS(BzrError):
 
3028
 
 
3029
    _fmt = ("Lossy push not possible between %(source_branch)r and "
 
3030
            "%(target_branch)r that are in the same VCS.")
 
3031
 
 
3032
    internal_error = True
 
3033
 
 
3034
    def __init__(self, source_branch, target_branch):
 
3035
        self.source_branch = source_branch
 
3036
        self.target_branch = target_branch