# HG changeset patch # User Pierre-Yves David # Date 2023-08-30 12:07:02 # Node ID 6ca86508047975f18d5b1ded9f648ef1ebce643f # Parent b2b8c25f94629f65db835b429fb04f1544d58ec4 remotefilelog: use sysstr to access for attributes We do not need bytes here. diff --git a/mercurial/utils/urlutil.py b/mercurial/utils/urlutil.py --- a/mercurial/utils/urlutil.py +++ b/mercurial/utils/urlutil.py @@ -257,18 +257,20 @@ class url: def __repr__(self): attrs = [] for a in ( - b'scheme', - b'user', - b'passwd', - b'host', - b'port', - b'path', - b'query', - b'fragment', + 'scheme', + 'user', + 'passwd', + 'host', + 'port', + 'path', + 'query', + 'fragment', ): v = getattr(self, a) if v is not None: - attrs.append(b'%s: %r' % (a, pycompat.bytestr(v))) + line = b'%s: %r' + line %= (pycompat.bytestr(a), pycompat.bytestr(v)) + attrs.append(line) return b'' % b', '.join(attrs) def __bytes__(self):