mercurial/utils/urlutil.py
changeset 51138 5c9c41273367
parent 51136 591845f89ada
child 51285 9d3721552b6c
--- a/mercurial/utils/urlutil.py	Wed Nov 08 22:13:14 2023 +0100
+++ b/mercurial/utils/urlutil.py	Wed Nov 08 22:17:41 2023 +0100
@@ -14,7 +14,6 @@
     error,
     pycompat,
     urllibcompat,
-    util,
 )
 
 from . import (
@@ -680,8 +679,7 @@
     """
     if isinstance(attr, bytes):
         msg = b'pathsuboption take `str` as "attr" argument, not `bytes`'
-        util.nouideprecwarn(msg, b"6.6", stacklevel=2)
-        attr = attr.decode('ascii')
+        raise TypeError(msg)
 
     def register(func):
         _pathsuboptions[option] = (attr, func)