~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/knit.py

Merge more bzr.dev, addressing some bugs. [still broken]

Show diffs side-by-side

added added

removed removed

Lines of Context:
1318
1318
 
1319
1319
    def get_method(self, version_id):
1320
1320
        """Return compression method of specified version."""
1321
 
        options = self._cache[version_id][1]
 
1321
        try:
 
1322
            options = self._cache[version_id][1]
 
1323
        except KeyError:
 
1324
            raise RevisionNotPresent(version_id, self._filename)
1322
1325
        if 'fulltext' in options:
1323
1326
            return 'fulltext'
1324
1327
        else:
1557
1560
            return 'fulltext'
1558
1561
 
1559
1562
    def _get_node(self, version_id):
1560
 
        return list(self._get_entries(self._version_ids_to_keys([version_id])))[0]
 
1563
        try:
 
1564
            return list(self._get_entries(self._version_ids_to_keys([version_id])))[0]
 
1565
        except IndexError:
 
1566
            raise RevisionNotPresent(version_id, self)
1561
1567
 
1562
1568
    def get_options(self, version_id):
1563
1569
        """Return a string represention options.