Skip to content

Warn that gc.get_objects() can expose objects under construction #159730

Closed

Description

@ngoldbaum

Documentation

The gc.get_objects() documentation does not mention that references created via the function may be partially initialized or allow access to uniquely referenced objects that are not observable by remote threads in any other way.

I'd like like to add a warning like the existing warning in the gc.get_referrers() docs.

For context, this has come up several times:

Linked PRs

Activity

  1. added 3 commits that reference this issue on Oct 19, 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

    docsDocumentation in the Doc dir

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions