~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/bundle/read_bundle.py

  • Committer: Aaron Bentley
  • Date: 2006-06-06 17:56:39 UTC
  • mto: This revision was merged to the branch mainline in revision 1748.
  • Revision ID: aaron.bentley@utoronto.ca-20060606175639-92a20ee0a7f8b3b7
Raise NotABundle when a non-bundle is supplied

Show diffs side-by-side

added added

removed removed

Lines of Context:
9
9
import pprint
10
10
 
11
11
from bzrlib.errors import (TestamentMismatch, BzrError, 
12
 
                           MalformedHeader, MalformedPatches)
 
12
                           MalformedHeader, MalformedPatches, NotABundle)
13
13
from bzrlib.bundle.common import get_header, header_str
14
14
from bzrlib.inventory import (Inventory, InventoryEntry,
15
15
                              InventoryDirectory, InventoryFile,
360
360
                                ' a header, but did not match')
361
361
                    header.pop(0)
362
362
        else:
363
 
            raise MalformedHeader('Did not find an opening header')
 
363
            raise NotABundle('Did not find an opening header')
364
364
 
365
365
    def _read_revision_header(self):
366
366
        self.info.revisions.append(RevisionInfo(None))