Skip to content

Doc/c-api/init.rst is way too big #141811

Description

@ZeroIntensity

Documentation

While working on #141810, I noticed that init.rst covers three very complicated topics:

  1. Interpreter initialization and finalization
  2. Threads and concurrency
  3. Subinterpreters

This makes it pretty huge and difficult to find things. I think we should split this up into two pages. Let's have a page for interpreter-related topics (initialization, finalization, subinterpreters), and a separate page for anything related to threads (PyMutex, critical sections, thread states, etc.).

Linked PRs

Activity

  1. StanFromIreland commented on Nov 21, 2025

    @StanFromIreland
    Member

    These moves are quite unfortunate for translations, but I’ll try to keep track of this and inform translation teams. Are you going to be backporting to 3.14?

  2. ZeroIntensity commented on Nov 21, 2025

    @ZeroIntensity
    MemberAuthor

    That would be ideal. Otherwise, any changes to the docs of those APIs will have conflicts when backporting. Is there anything that can be done to improve this for translations?

  3. vstinner commented on Nov 21, 2025

    @vstinner
    Member

    I think we should split this up into two pages.

    It could be 3 pages:

    • Interpreter initialization and finalization
    • Threads and concurrency
    • Subinterpreters
  4. StanFromIreland commented on Nov 21, 2025

    @StanFromIreland
    Member

    Is there anything that can be done to improve this for translations?

    Automatically, for non-Transifex translations (TX memory should merge them back in), no. It will require each translation team to manually merge the messages back in from an older commit. Due to this, I want to notify them ASAP after merge to recover the message and not re-translate things. I'll look into adding a guide for it to the devguide.

  5. ZeroIntensity commented on Nov 21, 2025

    @ZeroIntensity
    MemberAuthor

    It could be 3 pages

    Sounds good. I'll work on this once #141810 is done.

  6. picnixz commented on Nov 22, 2025

    @picnixz
    Member

    FTR, breaking the file might also break SEO and (possibly) intersphinx if we change the label names. See also #126053. One reason we still didn't break down some very large pages:

    Try not to break all the external links going into the pages. We don't want to invalidate all the references from blogs, tweets, stackoverflow answers, etc.

  7. ZeroIntensity commented on Nov 22, 2025

    @ZeroIntensity
    MemberAuthor

    I think that isn't as important here; C API docs are going to be significantly less linked than something like datamodel.rst. But, according to that issue, we can redirect things anyway.

  8. picnixz commented on Nov 22, 2025

    @picnixz
    Member

    Yeah but I would rather have the EB make a decision here instead of use core devs: see https://discuss.python.org/t/restructuring-the-stdlib-docs/102506.

  9. ZeroIntensity commented on Nov 22, 2025

    @ZeroIntensity
    MemberAuthor

    How do I ask the EB?

  10. StanFromIreland commented on Nov 22, 2025

    @StanFromIreland
    Member

    Open an issue in their repo, python/editoral-board.

  11. hugovk commented on Feb 3, 2026

    @hugovk
    Member

    We discussed this in the Docs WG meeting and are generally in favour: python/editorial-board#37 (comment).

  12. added 3 commits that reference this issue on Feb 20, 2026
  13. added a commit that references this issue on Feb 28, 2026
  14. added a commit that references this issue on Apr 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions