KEMBAR78
Module-level `__annotations__` variable is flagged as undefined · Issue #10330 · python/mypy · GitHub
Skip to content

Module-level __annotations__ variable is flagged as undefined #10330

@erictraut

Description

@erictraut

To repro, run mypy on the following:

print(__annotations__)
test.py:1: error: Name '__annotations__' is not defined
Found 1 error in 1 file (checked 1 source file)

A pyright user recently noted the same issue in pyright, which I have fixed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions