-
-
Notifications
You must be signed in to change notification settings - Fork 453
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
Add URLPattern options to django.url.conf since they were missing. #583
Conversation
…o version 3.0, which has since been replaced by 3.1 as new stable version.
Some follow-up work might be necessary on I took a quick look at the tests; it's not quite straightforward (I've never written any type checking test before). Is there some documentation somewhere that I could refer to on how to specify the expected output of cases? E. g. tests to make sure that |
…since those don't accept List[URLResolver] as argument.
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.
Awesome, thank you!
Can we please test that now it works?
I've tested it with my local snippet, it works :) Am now looking into writing a test for that. |
Test added. |
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!
I have made things!
It's possible to pass in
List[URLPattern]
as argument todjango.urls.include
, which then results inList[URLPattern]
as output of that function. The current type hints for all ofdjango.urls.include
,django.urls.path
anddjango.urls.re_path
don't support this use case - this PR adjust their type hints to support it.Related issues
Fixes #582