Repository navigation
fix: type build_di_container's connection as ASGIConnection - #86
Merged
Merged
Conversation
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.
Litestar 2.25.0 (released 2026-10-18) warns when a reserved kwarg's annotation doesn't match the handler's connection class.
build_di_containerdeclaredrequest: litestar.Request, but it also serves websocket handlers. So every websocket route that injects withFromDIraised aLitestarDeprecationWarningat startup, and the warning says this "will stop working in Litestar 3.0". The test suite turns warnings into errors, so three websocket tests on main fail against 2.25.0.The parameter is now typed as
ASGIConnection, which Litestar accepts for bothRequestandWebSockethandlers. The body already dispatches throughclassify_connection, so nothing else changes.The three failing websocket tests are the regression tests. Ran on 3.11, 3.14 and 3.14t (22 passed each), and at the declared floor (litestar 2.23.0).