/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 bzrlib/errors.py

  • Committer: John Arbash Meinel
  • Date: 2009-07-08 14:37:25 UTC
  • mfrom: (4516 +trunk)
  • mto: This revision was merged to the branch mainline in revision 4517.
  • Revision ID: john@arbash-meinel.com-20090708143725-sc9sjy3mz4cxwxzz
Merge bzr.dev 4516

Show diffs side-by-side

added added

removed removed

Lines of Context:
636
636
        self.url = url
637
637
 
638
638
 
 
639
class UnstackableLocationError(BzrError):
 
640
 
 
641
    _fmt = "The branch '%(branch_url)s' cannot be stacked on '%(target_url)s'."
 
642
 
 
643
    def __init__(self, branch_url, target_url):
 
644
        BzrError.__init__(self)
 
645
        self.branch_url = branch_url
 
646
        self.target_url = target_url
 
647
 
 
648
 
639
649
class UnstackableRepositoryFormat(BzrError):
640
650
 
641
651
    _fmt = ("The repository '%(url)s'(%(format)s) is not a stackable format. "
2083
2093
 
2084
2094
class OutOfDateTree(BzrError):
2085
2095
 
2086
 
    _fmt = "Working tree is out of date, please run 'bzr update'."
 
2096
    _fmt = "Working tree is out of date, please run 'bzr update'.%(more)s"
2087
2097
 
2088
 
    def __init__(self, tree):
 
2098
    def __init__(self, tree, more=None):
 
2099
        if more is None:
 
2100
            more = ''
 
2101
        else:
 
2102
            more = ' ' + more
2089
2103
        BzrError.__init__(self)
2090
2104
        self.tree = tree
 
2105
        self.more = more
2091
2106
 
2092
2107
 
2093
2108
class PublicBranchOutOfDate(BzrError):
2161
2176
    _fmt = "To use this feature you must upgrade your repository at %(path)s."
2162
2177
 
2163
2178
 
 
2179
class RichRootUpgradeRequired(UpgradeRequired):
 
2180
 
 
2181
    _fmt = ("To use this feature you must upgrade your branch at %(path)s to"
 
2182
           " a format which supports rich roots.")
 
2183
 
 
2184
 
2164
2185
class LocalRequiresBoundBranch(BzrError):
2165
2186
 
2166
2187
    _fmt = "Cannot perform local-only commits on unbound branches."
2167
2188
 
2168
2189
 
2169
 
class InvalidProgressBarType(BzrError):
2170
 
 
2171
 
    _fmt = ("Environment variable BZR_PROGRESS_BAR='%(bar_type)s"
2172
 
            " is not a supported type Select one of: %(valid_types)s")
2173
 
 
2174
 
    def __init__(self, bar_type, valid_types):
2175
 
        BzrError.__init__(self, bar_type=bar_type, valid_types=valid_types)
2176
 
 
2177
 
 
2178
2190
class UnsupportedOperation(BzrError):
2179
2191
 
2180
2192
    _fmt = ("The method %(mname)s is not supported on"
2771
2783
 
2772
2784
class UncommittedChanges(BzrError):
2773
2785
 
2774
 
    _fmt = 'Working tree "%(display_url)s" has uncommitted changes.'
 
2786
    _fmt = ('Working tree "%(display_url)s" has uncommitted changes'
 
2787
            ' (See bzr status).%(more)s')
2775
2788
 
2776
 
    def __init__(self, tree):
 
2789
    def __init__(self, tree, more=None):
 
2790
        if more is None:
 
2791
            more = ''
 
2792
        else:
 
2793
            more = ' ' + more
2777
2794
        import bzrlib.urlutils as urlutils
2778
2795
        display_url = urlutils.unescape_for_display(
2779
2796
            tree.bzrdir.root_transport.base, 'ascii')
2780
 
        BzrError.__init__(self, tree=tree, display_url=display_url)
 
2797
        BzrError.__init__(self, tree=tree, display_url=display_url, more=more)
2781
2798
 
2782
2799
 
2783
2800
class MissingTemplateVariable(BzrError):