Skip to content
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

gh-124969: Fix locale.nl_langinfo(locale.ALT_DIGITS) #124974

Merged

Conversation

serhiy-storchaka
Copy link
Member

@serhiy-storchaka serhiy-storchaka commented Oct 4, 2024

Now it returns a tuple of up to 100 strings (an empty tuple on most locales).
Previously it returned the first item of that tuple or an empty string.
@serhiy-storchaka serhiy-storchaka marked this pull request as ready for review October 8, 2024 09:10
Modules/_localemodule.c Outdated Show resolved Hide resolved
@serhiy-storchaka serhiy-storchaka added the 🔨 test-with-buildbots Test PR w/ buildbots; report in status section label Oct 8, 2024
@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by @serhiy-storchaka for commit 157c23e 🤖

If you want to schedule another build, you need to add the 🔨 test-with-buildbots label again.

@bedevere-bot bedevere-bot removed the 🔨 test-with-buildbots Test PR w/ buildbots; report in status section label Oct 8, 2024
@serhiy-storchaka
Copy link
Member Author

Thank you for your review @methane. I wonder what happened with ALT_DIGITS on macOS whether it only for Japanese (which have lesser need of this info for strftime()/strptime()) or for all locales. In any case this is no our fault.

@serhiy-storchaka serhiy-storchaka merged commit 21c04e1 into python:main Oct 9, 2024
39 checks passed
@serhiy-storchaka serhiy-storchaka deleted the locale-nl_langinfo-alt_digits branch October 9, 2024 08:42
@serhiy-storchaka serhiy-storchaka added needs backport to 3.12 bug and security fixes needs backport to 3.13 bugs and security fixes labels Oct 9, 2024
@miss-islington-app
Copy link

Thanks @serhiy-storchaka for the PR 🌮🎉.. I'm working now to backport this PR to: 3.12.
🐍🍒⛏🤖

@miss-islington-app
Copy link

Thanks @serhiy-storchaka for the PR 🌮🎉.. I'm working now to backport this PR to: 3.13.
🐍🍒⛏🤖

@encukou
Copy link
Member

encukou commented Oct 9, 2024

This commit broke the iOS buildbot: https://buildbot.python.org/#/builders/1380/builds/1535/steps/10/logs/stdio

efimov-mikhail pushed a commit to efimov-mikhail/cpython that referenced this pull request Oct 9, 2024
…124974)

Now it returns a tuple of up to 100 strings (an empty tuple on most locales).
Previously it returned the first item of that tuple or an empty string.
@serhiy-storchaka
Copy link
Member Author

Thanks. Should be fixed by #125177.

@serhiy-storchaka serhiy-storchaka removed needs backport to 3.12 bug and security fixes needs backport to 3.13 bugs and security fixes labels Oct 10, 2024
@serhiy-storchaka serhiy-storchaka added needs backport to 3.12 bug and security fixes needs backport to 3.13 bugs and security fixes labels Oct 10, 2024
@miss-islington-app
Copy link

Thanks @serhiy-storchaka for the PR 🌮🎉.. I'm working now to backport this PR to: 3.12.
🐍🍒⛏🤖

@miss-islington-app
Copy link

Thanks @serhiy-storchaka for the PR 🌮🎉.. I'm working now to backport this PR to: 3.13.
🐍🍒⛏🤖

@miss-islington-app
Copy link

Sorry, @serhiy-storchaka, I could not cleanly backport this to 3.12 due to a conflict.
Please backport using cherry_picker on command line.

cherry_picker 21c04e1a972bd1b6285e0ea41fa107d635bbe43a 3.12

@miss-islington-app
Copy link

Sorry, @serhiy-storchaka, I could not cleanly backport this to 3.13 due to a conflict.
Please backport using cherry_picker on command line.

cherry_picker 21c04e1a972bd1b6285e0ea41fa107d635bbe43a 3.13

serhiy-storchaka added a commit to serhiy-storchaka/cpython that referenced this pull request Oct 10, 2024
…thonGH-124974)

Now it returns a tuple of up to 100 strings (an empty tuple on most locales).
Previously it returned the first item of that tuple or an empty string.
(cherry picked from commit 21c04e1)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
@bedevere-app
Copy link

bedevere-app bot commented Oct 10, 2024

GH-125232 is a backport of this pull request to the 3.13 branch.

@bedevere-app bedevere-app bot removed the needs backport to 3.13 bugs and security fixes label Oct 10, 2024
serhiy-storchaka added a commit to serhiy-storchaka/cpython that referenced this pull request Oct 10, 2024
…thonGH-124974)

Now it returns a tuple of up to 100 strings (an empty tuple on most locales).
Previously it returned the first item of that tuple or an empty string.
(cherry picked from commit 21c04e1)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
@serhiy-storchaka serhiy-storchaka removed the needs backport to 3.12 bug and security fixes label Oct 10, 2024
@serhiy-storchaka serhiy-storchaka removed their assignment Oct 10, 2024
freakboy3742 pushed a commit that referenced this pull request Oct 10, 2024
… (#125232)

Returns a tuple of up to 100 strings for ALT_DIGITS lookup (an empty tuple on most locales).
Previously it returned the first item of that tuple or an empty string.
(cherry picked from commit 21c04e1)
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Oct 10, 2024
…thonGH-124974) (pythonGH-125232)

(cherry picked from commit 26a9318)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Returns a tuple of up to 100 strings for ALT_DIGITS lookup (an empty tuple on most locales).
Previously it returned the first item of that tuple or an empty string.
(cherry picked from commit 21c04e1)
serhiy-storchaka added a commit that referenced this pull request Oct 11, 2024
…H-124974) (GH-125232) (GH-125284)

(cherry picked from commit 26a9318)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Returns a tuple of up to 100 strings for ALT_DIGITS lookup (an empty tuple on most locales).
Previously it returned the first item of that tuple or an empty string.
(cherry picked from commit 21c04e1)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
serhiy-storchaka added a commit to serhiy-storchaka/cpython that referenced this pull request Oct 21, 2024
… a string again

This is a follow up of pythonGH-124974. Only Glibc needed a fix.
Now the returned value is a string consisting of semicolon-separated
symbols on all Posix platforms.
serhiy-storchaka added a commit that referenced this pull request Oct 21, 2024
…ing again (GH-125774)

This is a follow up of GH-124974. Only Glibc needed a fix.
Now the returned value is a string consisting of semicolon-separated
symbols on all Posix platforms.
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Oct 21, 2024
… a string again (pythonGH-125774)

This is a follow up of pythonGH-124974. Only Glibc needed a fix.
Now the returned value is a string consisting of semicolon-separated
symbols on all Posix platforms.
(cherry picked from commit dcc4fb2)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Oct 21, 2024
… a string again (pythonGH-125774)

This is a follow up of pythonGH-124974. Only Glibc needed a fix.
Now the returned value is a string consisting of semicolon-separated
symbols on all Posix platforms.
(cherry picked from commit dcc4fb2c9068f60353f0c0978948b7681f7745e6)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
serhiy-storchaka added a commit that referenced this pull request Oct 21, 2024
…g a string again (GH-125774) (GH-125805)

This is a follow up of GH-124974. Only Glibc needed a fix.
Now the returned value is a string consisting of semicolon-separated
symbols on all Posix platforms.
(cherry picked from commit dcc4fb2)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
serhiy-storchaka added a commit that referenced this pull request Oct 21, 2024
…g a string again (GH-125774) (GH-125804)

This is a follow up of GH-124974. Only Glibc needed a fix.
Now the returned value is a string consisting of semicolon-separated
symbols on all Posix platforms.
(cherry picked from commit dcc4fb2)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants