170
class DirstateCorrupt(BzrError):
172
_fmt = "The dirstate file (%(state)s) appears to be corrupt: %(msg)s"
174
def __init__(self, state, msg):
175
BzrError.__init__(self)
180
class DisabledMethod(InternalBzrError):
182
_fmt = "The smart server method '%(class_name)s' is disabled."
184
def __init__(self, class_name):
185
BzrError.__init__(self)
186
self.class_name = class_name
154
189
class IncompatibleVersion(BzrError):
156
191
_fmt = 'API %(api)s is not compatible; one of versions %(wanted)r '\
272
class NoSuchIdInRepository(NoSuchId):
274
_fmt = ('The file id "%(file_id)s" is not present in the repository'
277
def __init__(self, repository, file_id):
278
BzrError.__init__(self, repository=repository, file_id=file_id)
228
281
class NotStacked(BranchError):
230
283
_fmt = "The branch '%(branch)s' is not stacked."
286
class InventoryModified(InternalBzrError):
288
_fmt = ("The current inventory for the tree %(tree)r has been modified,"
289
" so a clean inventory cannot be read without data loss.")
291
def __init__(self, tree):
233
295
class NoWorkingTree(BzrError):
235
297
_fmt = 'No WorkingTree exists for "%(base)s".'
258
class NoWhoami(BzrError):
260
_fmt = ('Unable to determine your name.\n'
261
"Please, set your name with the 'whoami' command.\n"
262
'E.g. brz whoami "Your Name <name@example.com>"')
265
class CommandError(BzrError):
325
class BzrCommandError(BzrError):
266
326
"""Error from user command"""
268
328
# Error from malformed user command; please avoid raising this as a
271
331
# I think it's a waste of effort to differentiate between errors that
272
332
# are not intended to be caught anyway. UI code need not subclass
273
# CommandError, and non-UI code should not throw a subclass of
274
# CommandError. ADHB 20051211
277
# Provide the old name as backup, for the moment.
278
BzrCommandError = CommandError
333
# BzrCommandError, and non-UI code should not throw a subclass of
334
# BzrCommandError. ADHB 20051211
281
337
class NotWriteLocked(BzrError):
286
342
self.not_locked = not_locked
345
class BadIndexFormatSignature(BzrError):
347
_fmt = "%(value)s is not an index of type %(_type)s."
349
def __init__(self, value, _type):
350
BzrError.__init__(self)
355
class BadIndexData(BzrError):
357
_fmt = "Error in data for index %(value)s."
359
def __init__(self, value):
360
BzrError.__init__(self)
364
class BadIndexDuplicateKey(BzrError):
366
_fmt = "The key '%(key)s' is already in index '%(index)s'."
368
def __init__(self, key, index):
369
BzrError.__init__(self)
374
class BadIndexKey(BzrError):
376
_fmt = "The key '%(key)s' is not a valid key."
378
def __init__(self, key):
379
BzrError.__init__(self)
383
class BadIndexOptions(BzrError):
385
_fmt = "Could not parse options for index %(value)s."
387
def __init__(self, value):
388
BzrError.__init__(self)
392
class BadIndexValue(BzrError):
394
_fmt = "The value '%(value)s' is not a valid value."
396
def __init__(self, value):
397
BzrError.__init__(self)
289
401
class StrictCommitFailed(BzrError):
291
403
_fmt = "Commit refused because there are unknown files in the tree"
377
489
_fmt = 'Permission denied: "%(path)s"%(extra)s'
492
class UnavailableRepresentation(InternalBzrError):
494
_fmt = ("The encoding '%(wanted)s' is not available for key %(key)s which "
495
"is encoded as '%(native)s'.")
497
def __init__(self, key, wanted, native):
498
InternalBzrError.__init__(self)
504
class UnknownHook(BzrError):
506
_fmt = "The %(type)s hook '%(hook)s' is unknown in this version of breezy."
508
def __init__(self, hook_type, hook_name):
509
BzrError.__init__(self)
510
self.type = hook_type
511
self.hook = hook_name
380
514
class UnsupportedProtocol(PathError):
382
516
_fmt = 'Unsupported protocol for url "%(path)s"%(extra)s'
385
519
PathError.__init__(self, url, extra=extra)
522
class UnstackableBranchFormat(BzrError):
524
_fmt = ("The branch '%(url)s'(%(format)s) is not a stackable format. "
525
"You will need to upgrade the branch to permit branch stacking.")
527
def __init__(self, format, url):
528
BzrError.__init__(self)
388
533
class UnstackableLocationError(BzrError):
390
535
_fmt = "The branch '%(branch_url)s' cannot be stacked on '%(target_url)s'."
454
599
_fmt = 'Not a branch: "%(path)s"%(detail)s.'
456
601
def __init__(self, path, detail=None, controldir=None):
457
from . import urlutils
458
path = urlutils.unescape_for_display(path, 'ascii')
459
if detail is not None:
460
detail = ': ' + detail
462
self.controldir = controldir
463
PathError.__init__(self, path=path)
602
from . import urlutils
603
path = urlutils.unescape_for_display(path, 'ascii')
604
if detail is not None:
605
detail = ': ' + detail
607
self.controldir = controldir
608
PathError.__init__(self, path=path)
465
610
def __repr__(self):
466
611
return '<%s %r>' % (self.__class__.__name__, self.__dict__)
530
675
(use brz checkout if you wish to build a working tree): "%(path)s"'
678
class AtomicFileAlreadyClosed(PathError):
680
_fmt = ('"%(function)s" called on an AtomicFile after it was closed:'
683
def __init__(self, path, function):
684
PathError.__init__(self, path=path, extra=None)
685
self.function = function
533
688
class InaccessibleParent(PathError):
535
690
_fmt = ('Parent not accessible given base "%(base)s" and'
883
1037
self.lock_token = lock_token
1040
class PointlessCommit(BzrError):
1042
_fmt = "No changes to commit"
1045
class CannotCommitSelectedFileMerge(BzrError):
1047
_fmt = 'Selected-file commit of merges is not supported yet:'\
1048
' files %(files_str)s'
1050
def __init__(self, files):
1051
files_str = ', '.join(files)
1052
BzrError.__init__(self, files=files, files_str=files_str)
1055
class ExcludesUnsupported(BzrError):
1057
_fmt = ('Excluding paths during commit is not supported by '
1058
'repository at %(repository)r.')
1060
def __init__(self, repository):
1061
BzrError.__init__(self, repository=repository)
1064
class BadCommitMessageEncoding(BzrError):
1066
_fmt = 'The specified commit message contains characters unsupported by '\
1067
'the current encoding.'
886
1070
class UpgradeReadonly(BzrError):
888
1072
_fmt = "Upgrade URL cannot work with readonly URLs."
930
1119
self.revision_id = revision_id
1122
class InvalidRevisionSpec(BzrError):
1124
_fmt = ("Requested revision: '%(spec)s' does not exist in branch:"
1125
" %(branch_url)s%(extra)s")
1127
def __init__(self, spec, branch, extra=None):
1128
BzrError.__init__(self, branch=branch, spec=spec)
1129
self.branch_url = getattr(branch, 'user_url', str(branch))
1131
self.extra = '\n' + str(extra)
933
1136
class AppendRevisionsOnlyViolation(BzrError):
935
1138
_fmt = ('Operation denied because it would change the main history,'
936
' which is not permitted by the append_revisions_only setting on'
937
' branch "%(location)s".')
1139
' which is not permitted by the append_revisions_only setting on'
1140
' branch "%(location)s".')
939
1142
def __init__(self, location):
940
import breezy.urlutils as urlutils
941
location = urlutils.unescape_for_display(location, 'ascii')
942
BzrError.__init__(self, location=location)
1143
import breezy.urlutils as urlutils
1144
location = urlutils.unescape_for_display(location, 'ascii')
1145
BzrError.__init__(self, location=location)
945
1148
class DivergedBranches(BzrError):
1092
1296
_fmt = "Text did not match its checksum: %(msg)s"
1299
class KnitError(InternalBzrError):
1304
class KnitCorrupt(KnitError):
1306
_fmt = "Knit %(filename)s corrupt: %(how)s"
1308
def __init__(self, filename, how):
1309
KnitError.__init__(self)
1310
self.filename = filename
1314
class SHA1KnitCorrupt(KnitCorrupt):
1316
_fmt = ("Knit %(filename)s corrupt: sha-1 of reconstructed text does not "
1317
"match expected sha-1. key %(key)s expected sha %(expected)s actual "
1320
def __init__(self, filename, actual, expected, key, content):
1321
KnitError.__init__(self)
1322
self.filename = filename
1323
self.actual = actual
1324
self.expected = expected
1326
self.content = content
1329
class KnitDataStreamIncompatible(KnitError):
1330
# Not raised anymore, as we can convert data streams. In future we may
1331
# need it again for more exotic cases, so we're keeping it around for now.
1333
_fmt = "Cannot insert knit data stream of format \"%(stream_format)s\" into knit of format \"%(target_format)s\"."
1335
def __init__(self, stream_format, target_format):
1336
self.stream_format = stream_format
1337
self.target_format = target_format
1340
class KnitDataStreamUnknown(KnitError):
1341
# Indicates a data stream we don't know how to handle.
1343
_fmt = "Cannot parse knit data stream of format \"%(stream_format)s\"."
1345
def __init__(self, stream_format):
1346
self.stream_format = stream_format
1349
class KnitHeaderError(KnitError):
1351
_fmt = 'Knit header error: %(badline)r unexpected for file "%(filename)s".'
1353
def __init__(self, badline, filename):
1354
KnitError.__init__(self)
1355
self.badline = badline
1356
self.filename = filename
1358
class KnitIndexUnknownMethod(KnitError):
1359
"""Raised when we don't understand the storage method.
1361
Currently only 'fulltext' and 'line-delta' are supported.
1364
_fmt = ("Knit index %(filename)s does not have a known method"
1365
" in options: %(options)r")
1367
def __init__(self, filename, options):
1368
KnitError.__init__(self)
1369
self.filename = filename
1370
self.options = options
1095
1373
class RetryWithNewPacks(BzrError):
1096
1374
"""Raised when we realize that the packs on disk have changed.
1280
1558
TransportError.__init__(self, msg, orig_error=orig_error)
1283
class UnexpectedHttpStatus(InvalidHttpResponse):
1285
_fmt = "Unexpected HTTP status %(code)d for %(path)s: %(extra)s"
1287
def __init__(self, path, code, extra=None):
1290
self.extra = extra or ''
1291
full_msg = 'status code %d unexpected' % code
1292
if extra is not None:
1293
full_msg += ': ' + extra
1294
InvalidHttpResponse.__init__(
1295
self, path, full_msg)
1298
class BadHttpRequest(UnexpectedHttpStatus):
1300
_fmt = "Bad http request for %(path)s: %(reason)s"
1302
def __init__(self, path, reason):
1304
self.reason = reason
1305
TransportError.__init__(self, reason)
1308
1561
class InvalidHttpRange(InvalidHttpResponse):
1310
1563
_fmt = "Invalid http range %(range)r for %(path)s: %(msg)s"
1473
1742
self.prefix = prefix
1745
class MalformedTransform(InternalBzrError):
1747
_fmt = "Tree transform is malformed %(conflicts)r"
1750
class NoFinalPath(BzrError):
1752
_fmt = ("No final name for trans_id %(trans_id)r\n"
1753
"file-id: %(file_id)r\n"
1754
"root trans-id: %(root_trans_id)r\n")
1756
def __init__(self, trans_id, transform):
1757
self.trans_id = trans_id
1758
self.file_id = transform.final_file_id(trans_id)
1759
self.root_trans_id = transform.root
1476
1762
class BzrBadParameter(InternalBzrError):
1478
1764
_fmt = "Bad parameter: %(param)r"
1490
1776
_fmt = "Parameter %(param)s is neither unicode nor utf8."
1779
class ReusingTransform(BzrError):
1781
_fmt = "Attempt to reuse a transform that has already been applied."
1784
class CantMoveRoot(BzrError):
1786
_fmt = "Moving the root directory is not supported at this time"
1789
class TransformRenameFailed(BzrError):
1791
_fmt = "Failed to rename %(from_path)s to %(to_path)s: %(why)s"
1793
def __init__(self, from_path, to_path, why, errno):
1794
self.from_path = from_path
1795
self.to_path = to_path
1493
1800
class BzrMoveFailedError(BzrError):
1495
1802
_fmt = ("Could not move %(from_path)s%(operator)s %(to_path)s"
1496
"%(_has_extra)s%(extra)s")
1803
"%(_has_extra)s%(extra)s")
1498
1805
def __init__(self, from_path='', to_path='', extra=None):
1499
1806
from breezy.osutils import splitpath
1529
1836
class BzrRenameFailedError(BzrMoveFailedError):
1531
1838
_fmt = ("Could not rename %(from_path)s%(operator)s %(to_path)s"
1532
"%(_has_extra)s%(extra)s")
1839
"%(_has_extra)s%(extra)s")
1534
1841
def __init__(self, from_path, to_path, extra=None):
1535
1842
BzrMoveFailedError.__init__(self, from_path, to_path, extra)
1637
1950
wish to keep, and delete it when you are done."""
1639
1952
def __init__(self, pending_deletion):
1640
BzrError.__init__(self, pending_deletion=pending_deletion)
1953
BzrError.__init__(self, pending_deletion=pending_deletion)
1956
class ImmortalLimbo(BzrError):
1958
_fmt = """Unable to delete transform temporary directory %(limbo_dir)s.
1959
Please examine %(limbo_dir)s to see if it contains any files you wish to
1960
keep, and delete it when you are done."""
1962
def __init__(self, limbo_dir):
1963
BzrError.__init__(self)
1964
self.limbo_dir = limbo_dir
1643
1967
class ImmortalPendingDeletion(BzrError):
1645
1969
_fmt = ("Unable to delete transform temporary directory "
1646
"%(pending_deletion)s. Please examine %(pending_deletion)s to see if it "
1647
"contains any files you wish to keep, and delete it when you are done.")
1970
"%(pending_deletion)s. Please examine %(pending_deletion)s to see if it "
1971
"contains any files you wish to keep, and delete it when you are done.")
1649
1973
def __init__(self, pending_deletion):
1650
BzrError.__init__(self, pending_deletion=pending_deletion)
1974
BzrError.__init__(self, pending_deletion=pending_deletion)
1653
1977
class OutOfDateTree(BzrError):
1687
2011
_fmt = "Format error in conflict listings"
2014
class CorruptDirstate(BzrError):
2016
_fmt = ("Inconsistency in dirstate file %(dirstate_path)s.\n"
2017
"Error: %(description)s")
2019
def __init__(self, dirstate_path, description):
2020
BzrError.__init__(self)
2021
self.dirstate_path = dirstate_path
2022
self.description = description
1690
2025
class CorruptRepository(BzrError):
1692
2027
_fmt = ("An error has been detected in the repository %(repo_path)s.\n"
1758
2093
self.tname = type(method_self).__name__
1761
class FetchLimitUnsupported(UnsupportedOperation):
1763
fmt = ("InterBranch %(interbranch)r does not support fetching limits.")
1765
def __init__(self, interbranch):
1766
BzrError.__init__(self, interbranch=interbranch)
2096
class CannotSetRevisionId(UnsupportedOperation):
2097
"""Raised when a commit is attempting to set a revision id but cant."""
1769
2100
class NonAsciiRevisionId(UnsupportedOperation):
1914
2251
self.revision_id = revision_id
2254
class IllegalUseOfScopeReplacer(InternalBzrError):
2256
_fmt = ("ScopeReplacer object %(name)r was used incorrectly:"
2257
" %(msg)s%(extra)s")
2259
def __init__(self, name, msg, extra=None):
2260
BzrError.__init__(self)
2264
self.extra = ': ' + str(extra)
2269
class InvalidImportLine(InternalBzrError):
2271
_fmt = "Not a valid import statement: %(msg)\n%(text)s"
2273
def __init__(self, text, msg):
2274
BzrError.__init__(self)
2279
class ImportNameCollision(InternalBzrError):
2281
_fmt = ("Tried to import an object to the same name as"
2282
" an existing object. %(name)s")
2284
def __init__(self, name):
2285
BzrError.__init__(self)
1917
2289
class NotAMergeDirective(BzrError):
1918
2290
"""File starting with %(firstline)r is not a merge directive"""
1920
2291
def __init__(self, firstline):
1921
2292
BzrError.__init__(self, firstline=firstline)
2112
2516
self.reason = reason
2519
class SMTPError(BzrError):
2521
_fmt = "SMTP error: %(error)s"
2523
def __init__(self, error):
2527
class NoMessageSupplied(BzrError):
2529
_fmt = "No message supplied."
2532
class NoMailAddressSpecified(BzrError):
2534
_fmt = "No mail-to address (--mail-to) or output (-o) specified."
2537
class MailClientNotFound(BzrError):
2539
_fmt = "Unable to find mail client with the following names:"\
2540
" %(mail_command_list_string)s"
2542
def __init__(self, mail_command_list):
2543
mail_command_list_string = ', '.join(mail_command_list)
2544
BzrError.__init__(self, mail_command_list=mail_command_list,
2545
mail_command_list_string=mail_command_list_string)
2547
class SMTPConnectionRefused(SMTPError):
2549
_fmt = "SMTP connection to %(host)s refused"
2551
def __init__(self, error, host):
2556
class DefaultSMTPConnectionRefused(SMTPConnectionRefused):
2558
_fmt = "Please specify smtp_server. No server at default %(host)s."
2561
class BzrDirError(BzrError):
2563
def __init__(self, controldir):
2564
from . import urlutils
2565
display_url = urlutils.unescape_for_display(controldir.user_url,
2567
BzrError.__init__(self, controldir=controldir, display_url=display_url)
2570
class UnsyncedBranches(BzrDirError):
2572
_fmt = ("'%(display_url)s' is not in sync with %(target_url)s. See"
2573
" brz help sync-for-reconfigure.")
2575
def __init__(self, controldir, target_branch):
2576
BzrError.__init__(self, controldir)
2577
from . import urlutils
2578
self.target_url = urlutils.unescape_for_display(target_branch.base,
2582
class AlreadyBranch(BzrDirError):
2584
_fmt = "'%(display_url)s' is already a branch."
2587
class AlreadyTree(BzrDirError):
2589
_fmt = "'%(display_url)s' is already a tree."
2592
class AlreadyCheckout(BzrDirError):
2594
_fmt = "'%(display_url)s' is already a checkout."
2597
class AlreadyLightweightCheckout(BzrDirError):
2599
_fmt = "'%(display_url)s' is already a lightweight checkout."
2602
class AlreadyUsingShared(BzrDirError):
2604
_fmt = "'%(display_url)s' is already using a shared repository."
2607
class AlreadyStandalone(BzrDirError):
2609
_fmt = "'%(display_url)s' is already standalone."
2612
class AlreadyWithTrees(BzrDirError):
2614
_fmt = ("Shared repository '%(display_url)s' already creates "
2618
class AlreadyWithNoTrees(BzrDirError):
2620
_fmt = ("Shared repository '%(display_url)s' already doesn't create "
2624
class ReconfigurationNotSupported(BzrDirError):
2626
_fmt = "Requested reconfiguration of '%(display_url)s' is not supported."
2629
class NoBindLocation(BzrDirError):
2631
_fmt = "No location could be found to bind to at %(display_url)s."
2115
2634
class UncommittedChanges(BzrError):
2117
2636
_fmt = ('Working tree "%(display_url)s" has uncommitted changes'
2152
2671
' (See brz shelve --list).%(more)s')
2674
class MissingTemplateVariable(BzrError):
2676
_fmt = 'Variable {%(name)s} is not available.'
2678
def __init__(self, name):
2682
class NoTemplate(BzrError):
2684
_fmt = 'No template specified.'
2687
class UnableCreateSymlink(BzrError):
2689
_fmt = 'Unable to create symlink %(path_str)son this platform'
2691
def __init__(self, path=None):
2695
path_str = repr(str(path))
2696
except UnicodeEncodeError:
2697
path_str = repr(path)
2699
self.path_str = path_str
2702
class UnsupportedTimezoneFormat(BzrError):
2704
_fmt = ('Unsupported timezone format "%(timezone)s", '
2705
'options are "utc", "original", "local".')
2707
def __init__(self, timezone):
2708
self.timezone = timezone
2711
class CommandAvailableInPlugin(Exception):
2713
internal_error = False
2715
def __init__(self, cmd_name, plugin_metadata, provider):
2717
self.plugin_metadata = plugin_metadata
2718
self.cmd_name = cmd_name
2719
self.provider = provider
2723
_fmt = ('"%s" is not a standard brz command. \n'
2724
'However, the following official plugin provides this command: %s\n'
2725
'You can install it by going to: %s'
2726
% (self.cmd_name, self.plugin_metadata['name'],
2727
self.plugin_metadata['url']))
2732
class NoPluginAvailable(BzrError):
2155
2736
class UnableEncodePath(BzrError):
2157
2738
_fmt = ('Unable to encode %(kind)s path %(path)r in '
2172
2753
BzrError.__init__(self, alias_name=alias_name)
2756
class DirectoryLookupFailure(BzrError):
2757
"""Base type for lookup errors."""
2762
class InvalidLocationAlias(DirectoryLookupFailure):
2764
_fmt = '"%(alias_name)s" is not a valid location alias.'
2766
def __init__(self, alias_name):
2767
DirectoryLookupFailure.__init__(self, alias_name=alias_name)
2770
class UnsetLocationAlias(DirectoryLookupFailure):
2772
_fmt = 'No %(alias_name)s location assigned.'
2774
def __init__(self, alias_name):
2775
DirectoryLookupFailure.__init__(self, alias_name=alias_name[1:])
2175
2778
class CannotBindAddress(BzrError):
2177
2780
_fmt = 'Cannot bind address "%(host)s:%(port)i": %(orig_error)s.'
2179
2782
def __init__(self, host, port, orig_error):
2180
2783
# nb: in python2.4 socket.error doesn't have a useful repr
2181
2784
BzrError.__init__(self, host=host, port=port,
2182
orig_error=repr(orig_error.args))
2785
orig_error=repr(orig_error.args))
2788
class UnknownRules(BzrError):
2790
_fmt = ('Unknown rules detected: %(unknowns_str)s.')
2792
def __init__(self, unknowns):
2793
BzrError.__init__(self, unknowns_str=", ".join(unknowns))
2185
2796
class TipChangeRejected(BzrError):
2807
class ShelfCorrupt(BzrError):
2809
_fmt = "Shelf corrupt."
2812
class DecompressCorruption(BzrError):
2814
_fmt = "Corruption while decompressing repository file%(orig_error)s"
2816
def __init__(self, orig_error=None):
2817
if orig_error is not None:
2818
self.orig_error = ", %s" % (orig_error,)
2820
self.orig_error = ""
2821
BzrError.__init__(self)
2824
class NoSuchShelfId(BzrError):
2826
_fmt = 'No changes are shelved with id "%(shelf_id)d".'
2828
def __init__(self, shelf_id):
2829
BzrError.__init__(self, shelf_id=shelf_id)
2832
class InvalidShelfId(BzrError):
2834
_fmt = '"%(invalid_id)s" is not a valid shelf id, try a number instead.'
2836
def __init__(self, invalid_id):
2837
BzrError.__init__(self, invalid_id=invalid_id)
2196
2840
class JailBreak(BzrError):
2198
2842
_fmt = "An attempt to access a url outside the server jail was made: '%(url)s'."
2206
2850
_fmt = 'The user aborted the operation.'
2853
class MustHaveWorkingTree(BzrError):
2855
_fmt = ("Branching '%(url)s'(%(format)s) must create a working tree.")
2857
def __init__(self, format, url):
2858
BzrError.__init__(self, format=format, url=url)
2861
class NoSuchView(BzrError):
2862
"""A view does not exist.
2865
_fmt = u"No such view: %(view_name)s."
2867
def __init__(self, view_name):
2868
self.view_name = view_name
2871
class ViewsNotSupported(BzrError):
2872
"""Views are not supported by a tree format.
2875
_fmt = ("Views are not supported by %(tree)s;"
2876
" use 'brz upgrade' to change your tree to a later format.")
2878
def __init__(self, tree):
2882
class FileOutsideView(BzrError):
2884
_fmt = ('Specified file "%(file_name)s" is outside the current view: '
2887
def __init__(self, file_name, view_files):
2888
self.file_name = file_name
2889
self.view_str = ", ".join(view_files)
2209
2892
class UnresumableWriteGroup(BzrError):
2211
2894
_fmt = ("Repository %(repository)s cannot resume write group "
2264
2947
class RecursiveBind(BzrError):
2266
2949
_fmt = ('Branch "%(branch_url)s" appears to be bound to itself. '
2267
'Please use `brz unbind` to fix.')
2950
'Please use `brz unbind` to fix.')
2269
2952
def __init__(self, branch_url):
2270
2953
self.branch_url = branch_url
2956
class HpssVfsRequestNotAllowed(BzrError):
2958
_fmt = ("VFS requests over the smart server are not allowed. Encountered: "
2959
"%(method)s, %(arguments)s.")
2961
def __init__(self, method, arguments):
2962
self.method = method
2963
self.arguments = arguments
2273
2966
class UnsupportedKindChange(BzrError):
2275
2968
_fmt = ("Kind change from %(from_kind)s to %(to_kind)s for "
2282
2975
self.format = format
2285
class ChangesAlreadyStored(CommandError):
2978
class FeatureAlreadyRegistered(BzrError):
2980
_fmt = 'The feature %(feature)s has already been registered.'
2982
def __init__(self, feature):
2983
self.feature = feature
2986
class ChangesAlreadyStored(BzrCommandError):
2287
2988
_fmt = ('Cannot store uncommitted changes because this branch already'
2288
2989
' stores uncommitted changes.')
2291
class RevnoOutOfBounds(InternalBzrError):
2293
_fmt = ("The requested revision number %(revno)d is outside of the "
2294
"expected boundaries (%(minimum)d <= %(maximum)d).")
2296
def __init__(self, revno, bounds):
2297
InternalBzrError.__init__(
2298
self, revno=revno, minimum=bounds[0], maximum=bounds[1])