Skip to content

gettext.bind_textdomain_codeset was removed #632

@fabaff

Description

@fabaff

Describe the bug

gettext.bind_textdomain_codeset was removed in Python 3.10.

Traceback (most recent call last):
  File "/usr/bin/rednotebook", line 12, in <module>
    import rednotebook.journal
  File "/usr/lib/python3.11/site-packages/rednotebook/journal.py", line 100, in <module>
    elibintl.install(GETTEXT_DOMAIN, LOCALE_PATH, libintl=None)
  File "/usr/lib/python3.11/site-packages/rednotebook/external/elibintl.py", line 472, in install
    _install(domain, localedir, True, libintl=libintl)
  File "/usr/lib/python3.11/site-packages/rednotebook/external/elibintl.py", line 431, in _install
    gettext.bind_textdomain_codeset(domain, 'UTF-8')
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: module 'gettext' has no attribute 'bind_textdomain_codeset'

To Reproduce

Lauch rednotebook with Python >= 3.10

Expected behavior
Be able to run rednotebook

Versions:

  • RedNotebook version : present in 2.25
  • Operating system and version: All which are shipping Python >= 3.10 by default

Log output when reproducing bug
See above

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions