/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 breezy/revision.py

  • Committer: Jelmer Vernooij
  • Date: 2020-02-07 02:14:30 UTC
  • mto: This revision was merged to the branch mainline in revision 7492.
  • Revision ID: jelmer@jelmer.uk-20200207021430-m49iq3x4x8xlib6x
Drop python2 support.

Show diffs side-by-side

added added

removed removed

Lines of Context:
28
28
    errors,
29
29
    osutils,
30
30
    )
31
 
from .sixish import (
32
 
    text_type,
33
 
    )
34
31
 
35
32
NULL_REVISION = b"null:"
36
33
CURRENT_REVISION = b"current:"
90
87
        """Verify that all revision properties are OK."""
91
88
        for name, value in self.properties.items():
92
89
            # GZ 2017-06-10: What sort of string are properties exactly?
93
 
            not_text = not isinstance(name, (text_type, str))
 
90
            not_text = not isinstance(name, str)
94
91
            if not_text or osutils.contains_whitespace(name):
95
92
                raise ValueError("invalid property name %r" % name)
96
 
            if not isinstance(value, (text_type, bytes)):
 
93
            if not isinstance(value, (str, bytes)):
97
94
                raise ValueError("invalid property value %r for %r" %
98
95
                                 (value, name))
99
96