Skip to content

typing.get_type_hints documentation claims it no longer includes base class type hints. #100673

Closed
@FrozenBob

Description

@FrozenBob

Documentation

The typing.get_type_hints documentation currently says

Changed in version 3.10: Calling get_type_hints() on a class no longer returns the annotations of its base classes.

This is incorrect. No such change was made in 3.10, and no such change should be made. The documentation was changed erroneously when someone mixed up the typing.get_type_hints behavior with an unrelated __annotations__ change.

This note should be removed from the typing.get_type_hints documentation.

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions