-
-
Notifications
You must be signed in to change notification settings - Fork 34.5k
Interpreter.call() Fails For Various Builtins #135443
Copy link
Copy link
Closed
Labels
3.14bugs and security fixesbugs and security fixes3.15new features, bugs and security fixesnew features, bugs and security fixesinterpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)topic-subinterpreterstype-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error
Metadata
Metadata
Assignees
Labels
3.14bugs and security fixesbugs and security fixes3.15new features, bugs and security fixesnew features, bugs and security fixesinterpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)topic-subinterpreterstype-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error
Projects
Status
Done
Bug report
Bug description:
This includes any function that calls
_PyEval_GetGlobals()or_PyEval_GetFrameLocals(). Here's a list of the ones I noticed:globals()locals()dir()vars()exec()eval()For example:
Ideally it would fall back to
__main__.__dict__for the globals and locals.FWIW, this is most obvious with subinterpreters, but a similar problem applies to any user of the C-API that doesn't have a frame set.
CPython versions tested on:
CPython main branch
Operating systems tested on:
No response
Linked PRs