-
-
Notifications
You must be signed in to change notification settings - Fork 937
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor (testing): preserve raw path in scope creation #2331
base: master
Are you sure you want to change the base?
Conversation
I have an issue with mypy, dunno if it's only me. It complains about line 680 in |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #2331 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 64 64
Lines 7624 7625 +1
Branches 1246 1246
=========================================
+ Hits 7624 7625 +1 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this initiative @aarcex3!
However, it seems there is a misunderstanding regarding the actual implementation.
In ASGI, raw path is presented as the raw_path
key inside scope
. The value is a bytestring path, excluding any query string.
Furthermore, I think this improvement warrants a newsfragment, let's add one.
Summary of Changes
Added a 'raw_path' key to the asgi scope in
create_scope
to preserve the path and keep consistency as per #2159Related Issues
#2262
Pull Request Checklist