Uh oh!
There was an error while loading. Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork 34k
bpo-40275: Remove duplicate import of locale module#19761
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
Uh oh!
There was an error while loading. Please reload this page.
Conversation
shihai1991 commented Apr 28, 2020 • edited by bedevere-bot
Loading Uh oh!
There was an error while loading. Please reload this page.
edited by bedevere-bot
Uh oh!
There was an error while loading. Please reload this page.
vstinner left a comment
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.
This PR goes somehow against https://bugs.python.org/issue40275 goal. I would prefer to move the top-level "import locale" into skip_if_buggy_ucrt_strfptime().
bedevere-bot commented Apr 29, 2020
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 |
shihai1991 commented Apr 29, 2020
make sense, I updated this PR. |
shihai1991 commented Apr 29, 2020
Oh, the gate of macos failed randomly (no generated log file) |
serhiy-storchaka commented Apr 29, 2020 • edited by bedevere-bot
Loading Uh oh!
There was an error while loading. Please reload this page.
edited by bedevere-bot
Uh oh!
There was an error while loading. Please reload this page.
It does not help. For the purpose of bpo-40275 the changes should reduce the list of imported modules. |
vstinner commented Apr 29, 2020
Maybe we could attempt to make locale import lazy in gettext, or make gettext import lazy in argparse. Or just give up because locale is less heavy than asyncio for example :-) |
shihai1991 commented May 1, 2020
I try to make local import lazy in gettext. I don't make gettext import lazy in argparse, because much function will call gettext in argpase(it's looks untidy). |
| importlocale | ||
| importos |
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.
Please write a separated PR for gettext, and keep this PR for test.support.
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.
OK, I created #19905 to do this job.
This reverts commit 58d39a3.
bedevere-bot commented May 4, 2020
|
https://bugs.python.org/issue40275