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

  • Committer: Martin
  • Date: 2017-11-12 13:53:51 UTC
  • mto: This revision was merged to the branch mainline in revision 6810.
  • Revision ID: gzlist@googlemail.com-20171112135351-uyr1ncw7visg62c2
Apply 2to3 ws_comma fixer

Show diffs side-by-side

added added

removed removed

Lines of Context:
686
686
_hex_display_map = dict(([('%02x' % o, chr(o)) for o in range(256)]
687
687
                    + [('%02X' % o, chr(o)) for o in range(256)]))
688
688
#These entries get mapped to themselves
689
 
_hex_display_map.update((hex,'%'+hex) for hex in _no_decode_hex)
 
689
_hex_display_map.update((hex, '%'+hex) for hex in _no_decode_hex)
690
690
 
691
691
# These characters shouldn't be percent-encoded, and it's always safe to
692
692
# unencode them if they are.
885
885
 
886
886
        if ':' in host and not (host[0] == '[' and host[-1] == ']'):
887
887
            # there *is* port
888
 
            host, port = host.rsplit(':',1)
 
888
            host, port = host.rsplit(':', 1)
889
889
            try:
890
890
                port = int(port)
891
891
            except ValueError: