~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/errors.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2008-09-02 19:46:10 UTC
  • mfrom: (3640.2.6 dirstate_segv_186014)
  • Revision ID: pqm@pqm.ubuntu.com-20080902194610-1zzkeem0cm38snju
(jam) Fix bug #186014 by giving a proper exception if the dirstate
        cannot be parsed.

Show diffs side-by-side

added added

removed removed

Lines of Context:
224
224
        self.message = message
225
225
 
226
226
 
 
227
class DirstateCorrupt(BzrError):
 
228
 
 
229
    _fmt = "The dirstate file (%(state)s) appears to be corrupt: %(msg)s"
 
230
 
 
231
    def __init__(self, state, msg):
 
232
        BzrError.__init__(self)
 
233
        self.state = state
 
234
        self.msg = msg
 
235
 
 
236
 
227
237
class DisabledMethod(InternalBzrError):
228
238
 
229
239
    _fmt = "The smart server method '%(class_name)s' is disabled."