Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

SystemError when builtins is not a dict + eval #112716

Closed
Assignees
serhiy-storchaka
Labels
3.11only security fixes3.12only security fixes3.13bugs and security fixestype-bugAn unexpected behavior, bug, or error
@JelleZijlstra

Description

@JelleZijlstra

Bug report

Bug description:

If__builtins__ is not a dict, you can get a SystemError:

>>>import types>>>exec("import builtins; builtins.print(3)", {"__builtins__": types.MappingProxyType({})})Traceback (most recent call last):  File "<stdin>", line 1, in <module>    exec("import builtins; builtins.print(3)", {"__builtins__": types.MappingProxyType({})})  File "<string>", line 1, in <module>SystemError: Objects/dictobject.c:1761: bad argument to internal function

Originally found this while playing withhttps://oskaerik.github.io/theevalgame/

CPython versions tested on:

3.11, CPython main branch

Operating systems tested on:

macOS

Linked PRs

Metadata

Metadata

Labels

3.11only security fixes3.12only security fixes3.13bugs and security fixestype-bugAn unexpected behavior, bug, or error

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions


    [8]ページ先頭

    ©2009-2025 Movatter.jp