mirror of
https://github.com/python/cpython.git
synced 2025-11-01 10:45:30 +00:00
inspect: Remove "0x..." IDs from Signature objects' __repr__
Issue 24200.
This commit is contained in:
parent
51b58325f9
commit
f229bc5c53
2 changed files with 4 additions and 8 deletions
|
|
@ -3153,8 +3153,7 @@ class TestBoundArguments(unittest.TestCase):
|
|||
def foo(a, b, *, c:1={}, **kw) -> {42:'ham'}: pass
|
||||
sig = inspect.signature(foo)
|
||||
ba = sig.bind(20, 30, z={})
|
||||
self.assertRegex(repr(ba),
|
||||
r'<BoundArguments at 0x[a-fA-F0-9]+ \(a=20,.*\}\}\)>')
|
||||
self.assertRegex(repr(ba), r'<BoundArguments \(a=20,.*\}\}\)>')
|
||||
|
||||
|
||||
class TestSignaturePrivateHelpers(unittest.TestCase):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue