GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Availability extension's text translation breaks directive rendering · Issue #126609 · python/cpython

Availability extension's text translation breaks directive rendering #126609

New issue
Copy link
New issue
Copy link
Closed
Closed
Availability extension's text translation breaks directive rendering#126609
Copy link
Labels
docsDocumentation in the Doc dirDocumentation in the Doc dir

Description

@rffontenelle
rffontenelle
opened on Nov 9, 2024
Issue body actions

Documentation

The availability extension shows "Availability" text in the built docs. In the translation context, "Availability" is available for translation, but translating that text causes hundreds of warnings like this:

Warning: /path/to/cpython/Doc/library/os.rst:181: WARNING: inconsistent term references in translated message. original: ['Availability'], translated: [] [i18n.inconsistent_references]

The translated page will show the translation text ("Disponibilidade", in Portuguese) without the important text: the platforms where it is available. (That's unwanted!)

Some checking around:

  • In original English, os.ctermid() shows "Availability: Unix, not WASI.". See source file Doc/library/os.rst
  • In Brazilian Portuguese, os.ctermid() shows "Disponibilidade" but without the plataforms and without the hyperlink. See the string in the translation file (library/os.po)
  • in Simplified Chinese, I see in os.ctermid() they translated keeping "Availability" in English to escape this issue 😁. See the string in the translation file (library/os.po)

Linked PRs

  • gh-126609: Revert commit cbfd3924 to fix errors #129479
  • gh-126609: Revert Availability Directive changes #129480
  • gh-126609: docs: revert changes made to the internal structure of availability directive #129482
  • gh-126609: Allow translating the availability directive #129549
  • [3.13] gh-126609: Allow translating the availability directive (GH-129549) #129584
  • [3.12] gh-126609: Allow translating the availability directive (GH-129549) #129585
  • gh-126609: localize list, allow translation of a phrase, use ge operator character in the availability directive #129597
Reacted by Maciej Olko

Activity

  1. rffontenelle
    added
    docsDocumentation in the Doc dirDocumentation in the Doc dir
    on Nov 9, 2024
  2. github-project-automation
    added this to docs issueson Nov 9, 2024
  3. github-project-automation
    moved this to Todo in docs issueson Nov 9, 2024
  4. AA-Turner commented on Nov 9, 2024

    @AA-Turner
    AA-Turner
    on Nov 9, 2024
    Member
    More actions

    There's been a few other issues about this extension -- is this related to those at all?

    A

  5. rffontenelle commented on Nov 9, 2024

    @rffontenelle
    rffontenelle
    on Nov 9, 2024
    ContributorAuthor
    More actions

    After reviewing issues and PRs open and closed, it doesn't look like they are related.

    For the record, this issues started after extracting availability into a new extension. I git-checkout'ed it and built the docs to test it.

  6. m-aciek commented on Jan 30, 2025

    @m-aciek
    m-aciek
    on Jan 30, 2025
    Contributor
    More actions

    PL translation got impacted yesterday by this issue. Confirming that translating "Availability" (exposed to translation by the directive) to "Dostępność" (Polish translation) breaks rendering of the directive (as shown on screenshots).

    • build of Polish docs with the issue
    • logs with warnings from the HTML build process

    @rffontenelle I suggest renaming the ticket to „Availability extension's text translation breaks directive rendering” or similar.

    Broken rendering:
    Image

    Non-intl rendering:
    Image

    Reacted by Rafael Fontenelle and Stan Ulbrych
  7. rffontenelle
    changed the title [-]Availability extension's text translation causes warning[/-] [+]Availability extension's text translation breaks directive rendering[/+] on Jan 30, 2025
  8. StanFromIreland commented on Jan 30, 2025

    @StanFromIreland
    StanFromIreland
    on Jan 30, 2025
    Member
    More actions

    I have opened a PR that reverts the move.

  9. m-aciek
    added a commit that references this issue on Jan 30, 2025

    pythongh-126609: docs: revert changes made to the internal structure …

    7d8ea9b
  10. m-aciek commented on Feb 1, 2025

    @m-aciek
    m-aciek
    on Feb 1, 2025
    Contributor
    More actions

    For what it's worth translation Dostępność <availability> doesn't generate a correct reference.

    Image
  11. AA-Turner commented on Feb 1, 2025

    @AA-Turner
    AA-Turner
    on Feb 1, 2025
    Member
    More actions

    It seems that I missed the sphinx_gettext call here to allow translation. I've attempted to test #129549 locally and it seems to work, but please could someone here test it with an actual translation?

    A

    Reacted by Maciej Olko
  12. AA-Turner
    added a commit that references this issue on Feb 2, 2025

    gh-126609: Allow translating the ``availability`` directive (#129549)

    0612a89
  13. miss-islington
    added 2 commits that reference this issue on Feb 2, 2025

    pythongh-126609: Allow translating the ``availability`` directive (py…

    1397904

    pythongh-126609: Allow translating the ``availability`` directive (py…

    fa00f66
  14. AA-Turner
    added a commit that references this issue on Feb 2, 2025

    [3.12] gh-126609: Allow translating the ``availability`` directive (G…

    14bd0fc
  15. AA-Turner
    closed this as completedon Feb 2, 2025
  16. AA-Turner
    added a commit that references this issue on Feb 3, 2025

    [3.13] gh-126609: Allow translating the ``availability`` directive (G…

    9862800
  17. srinivasreddy
    added a commit that references this issue on Feb 7, 2025

    pythongh-126609: Allow translating the ``availability`` directive (py…

    5fb9143
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    docsDocumentation in the Doc dirDocumentation in the Doc dir

    Projects

    • docs issues
      Status
      Todo
      Show more project fields

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402503 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.