-
-
Notifications
You must be signed in to change notification settings - Fork 31.3k
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
Fixed #22712 -- Avoided name shadowing of "all" in findstatic command. #18259
Conversation
d3338d7
to
5d3e09b
Compare
4a27321
to
eabedf1
Compare
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.
Thank you @avallbona for this work! It looks good 🌟
I have added some comments and I also think that we should include release notes in the 5.2.txt
file, under the section Features deprecated in 5.2
. Something like:
* The ``all`` argument for the ``django.contrib.staticfiles.find()`` function
is deprecated in favor of the ``find_all`` argument.
Addressed the comments in 704fdb92b513ee0d6218068990bd70afa90dfdfd Thanks for the feedback 🙇🏿♂️ |
Thank you @avallbona for the param rename! Looks great. Did you see my comment about |
I've answered in the comment about |
Thank you, overall that looks good. I think that some comments such as: # RemovedInDjango60Warning: When the deprecation ends, replace with:
# def find(self, path, find_all=False): As a reference/example, we are just discussing/fixing a similar-ish issue for the |
@nessita handled in 3563132ea47cb8a0a52b2558e541bbc579535c30 Thanks for the feedback 🙇🏿♂️ |
c1a1998
to
f7a73ce
Compare
…ticfiles.finders. Co-authored-by: Natalia <124304+nessita@users.noreply.github.com>
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.
Thank you so much @avallbona for this work 🌟
I pushed a slight rework of the solution because, once I branched this PR to complete the review, I realized that the duplication for the deprecation check could be unified in a helper method.
I also took the opportunity to try the kwargs
approach which I think worked well enough. Let me know what you think!
Deprecation timeline was corrected in #18321. |
Right, this was my mistake: I should have noticed the deprecation number mismatch and I should have let you know so you could correct it. I'm sorry! (In my head, I was still on |
Fixed TICKET-22712 - Consider not using built-in functions as parameters.
Trac ticket number
ticket-22712
Branch description
Replaced the name that shadows the builtin funcion all and replaced by fetch_all. I'm not sure if we need the changes to be backwards compatible.
Checklist
main
branch.