Skip to content

Avoid using getdefaultlocale() - #51

Merged
aroberge merged 1 commit into
friendly-traceback:mainfrom
lucach:main
Apr 18, 2023
Merged

Avoid using getdefaultlocale()#51
aroberge merged 1 commit into
friendly-traceback:mainfrom
lucach:main

Conversation

@lucach

@lucach lucach commented Apr 18, 2023

Copy link
Copy Markdown
Contributor

It is deprecated since Python 3.11 and will be removed in 3.13: see https://bugs.python.org/issue46659 and
https://docs.python.org/3.11/library/locale.html#locale.getdefaultlocale

On Python 3.11, just importing friendly produces a rather annoying warning

>>> import friendly
`DeprecationWarning`: Use setlocale(), getencoding() and getlocale() instead

It is deprecated since Python 3.11 and will be removed in 3.13:
see https://bugs.python.org/issue46659 and
https://docs.python.org/3.11/library/locale.html#locale.getdefaultlocale

On Python 3.11, just importing friendly produces a rather annoying warning

>>> import friendly
`DeprecationWarning`: Use setlocale(), getencoding() and getlocale() instead
@aroberge
aroberge merged commit fe5d3a2 into friendly-traceback:main Apr 18, 2023
@aroberge

Copy link
Copy Markdown
Contributor

Thank you very much for noticing this and fixing it.

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.

2 participants