Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork32k
gh-97850: Deprecatefind_loader
andget_loader
inpkgutil
#98520
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
gh-97850: Deprecatefind_loader
andget_loader
inpkgutil
#98520
Uh oh!
There was an error while loading.Please reload this page.
Conversation
Uh oh!
There was an error while loading.Please reload this page.
CAM-Gerlach left a comment• edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
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.
Some comments and suggestions on the implementation of this deprecation, based on how we've handled others recently.
Pro tip (since not everyone seems to know this): if you go to theFiles changed
tab of this PR, you can apply some or all of the suggestions in one click by clickingAdd to batch
on each suggestion you want, and then clickCommit
either at the top or on any added suggestion with a descriptive message.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Misc/NEWS.d/next/Library/2022-10-21-16-23-31.gh-issue-97850.N46coo.rst OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
…6coo.rstCo-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
Thank you for the reviews:@merwok and@CAM-Gerlach I've also checked that >>>importpkgutil>>>pkgutil.get_loader('os')<stdin>:1:DeprecationWarning:'pkgutil.get_loader'isdeprecatedandslatedforremovalinPython3.14;useimportlib.util.find_specinstead<_frozen_importlib_external.SourceFileLoaderobjectat0x1012d55f0>>>>
I've also merged one of the@CAM-Gerlach's suggestion, so you get a credit for your awesome proposals! 🤝 |
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.
Overall LGTM, but I think there might be some unnecessary checks in the tests for various module "kinds".
Uh oh!
There was an error while loading.Please reload this page.
bedevere-bot commentedNov 25, 2022
A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated. Once you have made the requested changes, please leave a comment on this pull request containing the phrase |
Just FYI, you can apply some or all of them at once by going to the |
…m/sobolevn/cpython into deprecate-pkgutil-get-find-loader
@brettcannon I forgot to send the magic phrase! I have made the requested changes; please review again |
bedevere-bot commentedJan 7, 2023
Thanks for making the requested changes! @brettcannon: please review the changes made to this pull request. |
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.
Unfortunately I just realized that the documentation for pkgutil needs updating to mention the deprecations.
Uh oh!
There was an error while loading.Please reload this page.
Misc/NEWS.d/next/Library/2022-10-21-16-23-31.gh-issue-97850.N46coo.rst OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
bedevere-bot commentedJan 21, 2023
A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated. Once you have made the requested changes, please leave a comment on this pull request containing the phrase |
Co-authored-by: Brett Cannon <brett@python.org>
find_module
andget_module
inpkgutil
find_loader
andget_loader
inpkgutil
…6coo.rstCo-authored-by: Brett Cannon <brett@python.org>
I have made the requested changes; please review again 🙂 |
bedevere-bot commentedApr 11, 2023
Thanks for making the requested changes! @brettcannon: please review the changes made to this pull request. |
Oups, just found out that my push with Redid it now, it worked! |
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
@sobolevn the changes look good, but now there are unfortunately merge conflicts. |
Done :) |
Thanks! |
Thank you for this additional cleanup! |
Uh oh!
There was an error while loading.Please reload this page.
Refs#64138