Skip to content

typeobject.c: Missing return -1 after PyErr_Format in type_ready_post_checks #148074

Closed

Description

@Wulian233

Bug report

Bug description:

Parent issue #146102

https://gist.github.com/devdanzin/551cace22f112ef0ff4ed3fdbe54d235

At line 9314-9320, PyErr_Format sets a SystemError for invalid tp_dictoffset but falls through to return 0 (success). Type finishes initialization with invalid offset and pending exception. Requires C extension to trigger.

CPython versions tested on:

CPython main branch, 3.15, 3.14

Operating systems tested on:

No response

Linked PRs

Activity

  1. added a commit that references this issue on Apr 4, 2026
  2. added a commit that references this issue on Apr 4, 2026
  3. added a commit that references this issue on Apr 4, 2026
  4. added a commit that references this issue on Apr 4, 2026
  5. added a commit that references this issue on Apr 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    interpreter-core(Objects, Python, Grammar, and Parser dirs)topic-typingtype-bugAn unexpected behavior, bug, or error

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions