Skip to content

fix(typing): add -> None to __init__ methods missing return annotation - #144

Merged
Bre77 merged 1 commit into
mainfrom
fm/pytfa-teslabluetooth-init-annotation
Sep 4, 2026
Merged

fix(typing): add -> None to __init__ methods missing return annotation#144
Bre77 merged 1 commit into
mainfrom
fm/pytfa-teslabluetooth-init-annotation

Conversation

@Bre77

@Bre77 Bre77 commented Sep 4, 2026

Copy link
Copy Markdown
Member

Missing return annotations on __init__ methods (e.g. TeslaBluetooth.__init__) make mypy treat every call site as an untyped call in downstream consumers (the Home Assistant integration), forcing a # type: ignore[no-untyped-call] there even though the library is fully typed otherwise. Adds -> None to every __init__ in the package missing it.

Annotation-only change; no behavior change. ruff, pyright, and the test suite pass.

🤖 Generated with Claude Code

https://claude.ai/code/session_01VvadPv5MzPinGHF9WXJK6c

A missing return annotation makes every call site of an untyped __init__ (e.g. TeslaBluetooth) look like an untyped call to mypy, forcing downstream consumers to add type: ignore[no-untyped-call]. Annotate all __init__ methods across the package with -> None.

Claude-Session: https://claude.ai/code/session_01VvadPv5MzPinGHF9WXJK6c
@Bre77 Bre77 added the fm Opened by a Firstmate crewmate label Sep 4, 2026
@Bre77
Bre77 merged commit f4c773c into main Sep 4, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fm Opened by a Firstmate crewmate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant