/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/xml8.py

merge 2.0 branch rev 4647

Show diffs side-by-side

added added

removed removed

Lines of Context:
28
28
    Element,
29
29
    SubElement,
30
30
    XMLSerializer,
 
31
    escape_invalid_chars,
31
32
    )
32
33
from bzrlib.inventory import ROOT_ID, Inventory, InventoryEntry
33
34
from bzrlib.revision import Revision
167
168
        :raises: AssertionError if an error has occurred.
168
169
        """
169
170
        if inv.revision_id is None:
170
 
            raise AssertionError()
 
171
            raise AssertionError("inv.revision_id is None")
171
172
        if inv.root.revision is None:
172
 
            raise AssertionError()
 
173
            raise AssertionError("inv.root.revision is None")
173
174
 
174
175
    def _check_cache_size(self, inv_size, entry_cache):
175
176
        """Check that the entry_cache is large enough.
345
346
            root.set('timezone', str(rev.timezone))
346
347
        root.text = '\n'
347
348
        msg = SubElement(root, 'message')
348
 
        msg.text = rev.message
 
349
        msg.text = escape_invalid_chars(rev.message)[0]
349
350
        msg.tail = '\n'
350
351
        if rev.parent_ids:
351
352
            pelts = SubElement(root, 'parents')