Skip to content

Availability extension's text translation breaks directive rendering #126609

Closed

Description

@rffontenelle

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:

Linked PRs

Activity

  1. AA-Turner commented on Nov 9, 2024

    @AA-Turner
    Member

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

    A

  2. rffontenelle commented on Nov 9, 2024

    @rffontenelle
    ContributorAuthor

    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.

  3. m-aciek commented on Jan 30, 2025

    @m-aciek
    Contributor

    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).

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

    Broken rendering:
    Image

    Non-intl rendering:
    Image

  4. changed the title [-]Availability extension's text translation causes warning[/-] [+]Availability extension's text translation breaks directive rendering[/+] on Jan 30, 2025
  5. StanFromIreland commented on Jan 30, 2025

    @StanFromIreland
    Member

    I have opened a PR that reverts the move.

  6. added a commit that references this issue on Jan 30, 2025
  7. m-aciek commented on Feb 1, 2025

    @m-aciek
    Contributor

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

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

    @AA-Turner
    Member

    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

  9. added a commit that references this issue on Feb 2, 2025
  10. added 2 commits that reference this issue on Feb 2, 2025
  11. added a commit that references this issue on Feb 2, 2025
  12. added a commit that references this issue on Feb 3, 2025
  13. added a commit that references this issue on Feb 7, 2025
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 dir

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions