PyPI / typing-extensions / 4.16.0
typing-extensions 4.16.0
- Source
- https://github.com/python/typing_extensions
- Tag scanned
4.16.0- Compared with
4.15.0(1 signals introduced since)- Files
- 12 scanned, 5 skipped (binary, oversized, or unrecognised)
- Signals
- 0 critical · 0 warn · 12 info
- Scan time
- 9.8 s
- LLM review
- Reviewed by claude-haiku-5-5 (Anthropic): 12 of 12 warn and critical signals; 12 demoted to info.
- Disclude version
- 4.0.0
- Scanned (UTC)
- 2026-10-14 18:08
Signals
Ordered by severity, then signals introduced in this release. Hidden characters are shown as ⟨U+…⟩.
-
info
critical→ info by reviewframe-introspectionsrc/typing_extensions.py:170:16new in this releasereturn # For platforms without _getframe() passlikely benign Caller-module lookup via sys._getframe with AttributeError and ValueError fallbacks.Reasoning
This is the standard typing_extensions helper that reads the caller's module name via sys._getframe with a fallback for platforms lacking it. The anti-analysis label is a false match: the frame access is a normal, documented library technique.
-
)likely benign Test helper that execs a code string to verify subclassing error messages.Reasoning
The file is the typing_extensions test suite. The exec(code, {}) call runs a test-generated snippet to check error messages when subclassing. The decoder-import signal is a generic heuristic match with no encoded payload or dropper pipeline visible.
-
)likely benign exec of a locally constructed code object inside a typing test.Reasoning
exec is applied to a locally built code string inside a test method with an empty globals dict. This is the normal way to test syntax-dependent typing behavior, not a hidden payload.
-
likely benign Version-gated exec of dedented test source for PEP 695 syntax.
Reasoning
The exec call is guarded by a sys.version_info check and runs textwrap.dedent of a triple-quoted test source. This is standard version-gated test code for Python 3.12 syntax.
-
likely benign Feature-gated exec of test source defining generic protocol tests.
Reasoning
The exec call is guarded by hasattr(typing, 'TypeAliasType') and runs dedented test source. This is a feature-detected test for newer typing constructs.
-
= returnlikely benign Test helper that execs class source in a namespace and returns the defined class.Reasoning
The helper builds a namespace from extra_names, execs a class-definition code string, and returns the class. This is a typical test helper for generating classes from source, with no network or obfuscation involved.
-
likely benign Test runs the interpreter with -OO on a temporary file via a shell command.
Reasoning
The command is an f-string built from sys.executable, a fixed -OO flag, and a test-controlled file path, run with shell=True. The inputs are not attacker-controlled in a normal test run, so this is a test of optimized-mode behavior rather than a dropper.
-
)likely benign Test exec of a code string to check a typing rule.Reasoning
The exec(code, {}) call runs a test snippet in a fresh namespace, the same pattern as the other test-suite findings. It checks typing behavior, and nothing in the snippet suggests malicious intent.
-
=likely benign Exec of PEP 695 class source in a test namespace.Reasoning
The exec call runs dedented test source defining a PEP 695 generic class in a namespace. This is a standard test for newer syntax that older interpreters cannot parse directly.
-
= # - Catch AttributeError: not all Python implementations have sys._getframe() # - Catch ValueError: maybe we're called from an unexpected modulelikely benign Frame lookup to locate the calling module namespace for typing helpers.Reasoning
The sys._getframe(2) call is used to find the caller's namespace when defining typing constructs, and the surrounding comments describe the expected failure modes. It is a legitimate, documented library pattern.
-
= returnlikely benign Evaluates string annotations during type-hint resolution.Reasoning
eval is applied to string annotations inside a get-type-hints style function, which is the documented purpose of forward-reference resolution. The input is the library's own annotation strings, not untrusted external data.
-
= = = True =likely benign Evaluates a forward reference's compiled code to resolve its value.Reasoning
This evaluates a ForwardRef's compiled code object against the given globals and locals to resolve a forward reference. This is the normal mechanism of the typing module and matches its known implementation.
Reproduce This Scan
Run disclude locally to verify. Add --format sarif for SARIF output. Add --llm (with an API key in the environment) to include the LLM review.
&&