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

  • Committer: Breezy landing bot
  • Author(s): Jelmer Vernooij
  • Date: 2020-05-06 03:06:18 UTC
  • mfrom: (7500.1.2 trunk-merge-3.1)
  • Revision ID: breezy.the.bot@gmail.com-20200506030618-131sjbc876q7on66
Merge the 3.1 branch.

Merged from https://code.launchpad.net/~jelmer/brz/trunk-merge-3.1/+merge/383481

Show diffs side-by-side

added added

removed removed

Lines of Context:
19
19
See MutableTree for more details.
20
20
"""
21
21
 
22
 
from __future__ import absolute_import
23
 
 
24
22
from . import (
25
23
    errors,
26
24
    hooks,
29
27
    tree,
30
28
    )
31
29
 
32
 
from .sixish import (
33
 
    text_type,
34
 
    )
35
30
 
36
31
 
37
32
class BadReferenceTarget(errors.InternalBzrError):
101
96
 
102
97
        TODO: Perhaps callback with the ids and paths as they're added.
103
98
        """
104
 
        if isinstance(files, (str, text_type)):
 
99
        if isinstance(files, str):
105
100
            # XXX: Passing a single string is inconsistent and should be
106
101
            # deprecated.
107
102
            if not (ids is None or isinstance(ids, bytes)):
108
103
                raise AssertionError()
109
 
            if not (kinds is None or isinstance(kinds, (str, text_type))):
 
104
            if not (kinds is None or isinstance(kinds, str)):
110
105
                raise AssertionError()
111
106
            files = [files]
112
107
            if ids is not None: