Closed
Description
Bug report
Bug description:
import inspect
class MyString(str):
pass
def f():
a = 1
locals = inspect.currentframe().f_locals
print(MyString("a") in locals)
f()
In Python 3.12 and below this prints True
. In Python 3.13 this print False
. I think it comes down to the check for exact unicode:
Line 112 in f4ddaa3
The change in behaviour isn't a huge problem so if it's intended then I won't spend waste any time complaining about it, but I do think it's worth confirming that it is intended/desired.
CPython versions tested on:
3.13
Operating systems tested on:
Linux
Linked PRs
Metadata
Metadata
Assignees
Projects
Status
Done