chore(core): drop duplicate `TypeVar` definition
What changed, and why it matters
This commit removes a single duplicate TypeVar definition in a Python file used only during type checking. It has no effect on the actual running firmware and no security relevance.
No action needed; this is a benign code-cleanup commit.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The change deletes T = TypeVar("T") from a TYPE_CHECKING block in core/src/trezor/wire/context.py. This variable was already defined elsewhere and was unused/duplicated. Because it sits inside an if TYPE_CHECKING: guard, it is not executed at runtime and cannot affect firmware behavior, memory safety, or security boundaries.
Changed components
core/src/trezor/wire/context.pyInspect captured patch +0 / −1
diff --git a/core/src/trezor/wire/context.py b/core/src/trezor/wire/context.py
index cab7b4eb..294567ca 100644
--- a/core/src/trezor/wire/context.py
+++ b/core/src/trezor/wire/context.py
@@ -160,7 +160,6 @@ def try_get_ctx_ids() -> tuple[AnyBytes, AnyBytes] | None:
# ACCESS TO CACHE
if TYPE_CHECKING:
- T = TypeVar("T")
@overload
def cache_get(key: int) -> bytes | None: # noqa: F811
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.