SessionMiddleware uses an explicit path=..., instead of defaulting to the ASGI 'root_path'.#1512
Merged
lovelydinosaur merged 1 commit intomasterfrom Feb 14, 2022
Merged
Conversation
… the ASGI 'root_path'.
This was referenced Feb 14, 2022
Closed
2 tasks
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.
Closes #1261
This pull request reverts #1147.
I'd obviously made the wrong call on that.
The intent was "okay, let's limit the path against which session cookies are applied. Our server might be submounted to a given path, and we shouldn't cookie to / in that case." - Which is reasonable enough idea if it only applied to where the main app was mounted, but as it happens actually just breaks all sorts of cases for us. Because we allow for submounted apps too.
Instead we support a configurable path="/" on SessionMiddleware. This doesn't magically pick up any root path that the server might be mounted to, but does allow users to configure the path if they need too.
Also refs #233, #1351.
Prompted by this discussion.