Skip to content

refactor: remove dead code identified in issue #4 (~467 lines) - #9

Merged
Vattsa-11 merged 1 commit into
mainfrom
cleanup/dead-code-issue-4
Sep 2, 2026
Merged

refactor: remove dead code identified in issue #4 (~467 lines)#9
Vattsa-11 merged 1 commit into
mainfrom
cleanup/dead-code-issue-4

Conversation

@Vattsa-11

Copy link
Copy Markdown
Member

Remove confirmed-dead subsystems that are never instantiated or called:

  • AutoDocRouter class + create_auto_router() from auto_docs.py
  • decorators_style.py in full (get/post/put/delete/patch/Path/Body decorators that only attach metadata, never register routes)
  • Router.dynamic_patterns (never populated; generator.py loops method_trees and route_cache instead)
  • DependencyCache class + cleanup_caches() + inject() from depends.py (resolve_dependencies uses a plain dict on request.state)
  • HandlerProtocol from router.py (defined, never used as a type)
  • create_model() from validation/models.py (zero callers)

Also cleaned up now-unused imports: Protocol in router.py, TypeVar in depends.py, Callable in auto_docs.py, and AutoDocRouter/decorators_style re-exports from init files.

All 252 tests pass. Ruff clean.

🤖 Generated with Codebuff

Remove confirmed-dead subsystems that are never instantiated or called:

- AutoDocRouter class + create_auto_router() from auto_docs.py
- decorators_style.py in full (get/post/put/delete/patch/Path/Body
  decorators that only attach metadata, never register routes)
- Router.dynamic_patterns (never populated; generator.py loops
  method_trees and route_cache instead)
- DependencyCache class + cleanup_caches() + inject() from depends.py
  (resolve_dependencies uses a plain dict on request.state)
- HandlerProtocol from router.py (defined, never used as a type)
- create_model() from validation/models.py (zero callers)

Also cleaned up now-unused imports: Protocol in router.py,
TypeVar in depends.py, Callable in auto_docs.py, and
AutoDocRouter/decorators_style re-exports from __init__ files.

All 252 tests pass. Ruff clean.

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <noreply@codebuff.com>
@Vattsa-11
Vattsa-11 requested a review from magi8101 September 2, 2026 05:10
@Vattsa-11
Vattsa-11 merged commit ceccb88 into main Sep 2, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant