Skip to content

Invalid Assert in PyState_FindModule() #119560

Description

@ericsnowcurrently

Crash report

Bug description:

gh-118532 added an assert that is erroneously triggers if PyState_FindModule() is called before the provided module def has been initialized. The assert should be removed. (Python/import.c, line 460)

See ultrajson/ultrajson#629.

CPython versions tested on:

3.13, CPython main branch

Operating systems tested on:

No response

Linked PRs

Activity

  1. added
    interpreter-core(Objects, Python, Grammar, and Parser dirs)
    type-crashA hard crash of the interpreter, possibly with a core dump
    3.13only security fixes
    3.14bugs and security fixes
    on May 25, 2024
  2. added a commit that references this issue on May 25, 2024
  3. mgorny commented on May 26, 2024

    @mgorny
    Contributor

    Thanks. I can confirm that after applying this on top of 3.13.0b1, ujson passes all tests.

  4. added a commit that references this issue on May 27, 2024
  5. added a commit that references this issue on May 27, 2024
  6. added a commit that references this issue on Jul 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

3.13only security fixes3.14bugs and security fixesinterpreter-core(Objects, Python, Grammar, and Parser dirs)type-crashA hard crash of the interpreter, possibly with a core dump

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions