refactor(adapters): remove Any from the CLI, web, MCP and tracing adapters - #794
Merged
Conversation
janbjorge
force-pushed
the
typing/06-adapters-no-any
branch
from
September 6, 2026 16:37
68427f3 to
1ba395f
Compare
janbjorge
force-pushed
the
typing/06-adapters-no-any
branch
from
September 6, 2026 17:48
1ba395f to
20a542d
Compare
janbjorge
force-pushed
the
typing/06-adapters-no-any
branch
2 times, most recently
from
September 6, 2026 18:24
071c251 to
4ea393f
Compare
janbjorge
force-pushed
the
typing/06-adapters-no-any
branch
from
September 6, 2026 18:31
4ea393f to
3916418
Compare
janbjorge
force-pushed
the
typing/06-adapters-no-any
branch
from
September 6, 2026 18:33
3916418 to
a8bc86b
Compare
…pters The CLI factory loader returns a Factory protocol (a callable taking `*args: object`) and raises TypeError when a `module:attr` path does not resolve to a callable; validate_factory_result() yields `object` and the supervisor and `pgq` commands narrow with isinstance, so a factory yielding the wrong type fails with a clear TypeError instead of an AttributeError later. The web broadcaster dependency, the basic auth dependency, the MCP server's FastMCP generic and the OpenTelemetry tracer field get their real types, and the executor callable probes take `object` and guard with callable().
janbjorge
force-pushed
the
typing/06-adapters-no-any
branch
from
September 6, 2026 18:38
a8bc86b to
22a27e4
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part 6/9 of the strict-mypy series. Stacked on #793; merge in order, I rebase the rest after each merge.
The CLI factory loader returns a Factory protocol (a callable taking
*args: object) and raises TypeError when amodule:attrpath doesnot resolve to a callable; validate_factory_result() yields
objectand the supervisor and
pgqcommands narrow with isinstance, so afactory yielding the wrong type fails with a clear TypeError instead
of an AttributeError later. The web broadcaster dependency, the basic
auth dependency, the MCP server's FastMCP generic and the
OpenTelemetry tracer field get their real types, and the executor
callable probes take
objectand guard with callable().