/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/plugins/git/dir.py

  • Committer: Breezy landing bot
  • Author(s): Jelmer Vernooij
  • Date: 2018-07-25 03:06:42 UTC
  • mfrom: (7045.3.4 python3-r)
  • Revision ID: breezy.the.bot@gmail.com-20180725030642-oghhedvui3470wy6
Fix another ~500 tests on Python 3.

Merged from https://code.launchpad.net/~jelmer/brz/python3-r/+merge/350430

Show diffs side-by-side

added added

removed removed

Lines of Context:
492
492
                else:
493
493
                    params = {}
494
494
            try:
495
 
                base_url = urlutils.local_path_to_url(self.control_transport.get_bytes('commondir')).rstrip('/.git/')+'/'
 
495
                commondir = self.control_transport.get_bytes('commondir')
496
496
            except bzr_errors.NoSuchFile:
497
497
                base_url = self.user_url.rstrip('/')
 
498
            else:
 
499
                base_url = urlutils.local_path_to_url(commondir.decode(osutils._fs_enc)).rstrip('/.git/')+'/'
498
500
            if not PY3:
499
501
                params = {k: v.encode('utf-8') for (k, v) in viewitems(params)}
500
502
            return urlutils.join_segment_parameters(base_url, params)
693
695
        except bzr_errors.NoSuchFile:
694
696
            return self
695
697
        else:
696
 
            commondir = commondir.rstrip(b'/.git/')
 
698
            commondir = commondir.rstrip(b'/.git/').decode(osutils._fs_enc)
697
699
            return ControlDir.open_from_transport(get_transport_from_path(commondir))