Skip to content

Sphinx tech stack update + Tab sections in table of contents #7972

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 59 commits into
base: master
Choose a base branch
from

Conversation

neflyte
Copy link
Contributor

@neflyte neflyte commented May 23, 2025

Summary

This PR brings the following major changes:

  1. Update the Sphinx tech stack (i.e. Sphinx, extensions, themes)
  2. Allow sections in an inline tab to be shown in the document table of contents (ToC)
  3. Update customized Sphinx extensions to use the latest Sphinx APIs
  4. Page redirect definitions moved to a separate file

Details

Sphinx tech stack update

The Sphinx stack has had the following updates:

  • Sphinx 7.2.6 -> 8.2.3
  • Furo 2023.9.10 -> 2024.8.6
  • All Sphinx extensions to their latest versions

Sections of inline tabs in the ToC

The sphinx-inline-tabs extension was directly added to the repo and modified to:

  • Parse section titles from documents included in an inline tab
  • Add section titles from inline tabs to the document ToC

If a section is selected from the ToC that would appear on an inline tab that is hidden, that tab is selected before bringing the user to the desired section.

A caveat to this implementation is the loss of ToC updates when the document is scrolled. This is limited to only those documents that use tabs. All other functionality should remain the same.

Update customized Sphinx extensions

The compass-icons, config-setting-v2, reredirects, and sitemap extensions were updated to improve data typing and log messages, and ensure the latest Sphinx APIs are used.

Page redirect definitions moved to a separate file

The page redirect definitions, usually found in conf.py, were moved to a separate file, redirects.py, to keep the main Sphinx configuration file small.

Also, warnings regarding duplicate redirects are written to a separate log file, redirect-warnings.log, to reduce noise in the main Sphinx warnings log.

…k; Update setuptools to resolve a security vulnerability; Ensure MermaidJS dependency has a defined version
…hange; Update TOCs of all tab documents; Always add inlinetab ID as first ID in section elements
… pages that have TabContainer nodes; Disable some debug messages; Ensure sphinx_tabs environment data is properly merged for parallel builds;
…HTMLTranslator type instead of Sphinx's SphinxTranslator
…erate individual links instead of generating during parallel document parsing
@cwarnermm cwarnermm added the preview-environment Allow the preview environment to be generated for Pull Requests coming from fork repositories label May 26, 2025
@cwarnermm cwarnermm self-requested a review May 26, 2025 21:02
Copy link

Newest code from neflyte has been published to preview environment for Git SHA baa6ad0

@cwarnermm cwarnermm added preview-environment Allow the preview environment to be generated for Pull Requests coming from fork repositories and removed preview-environment Allow the preview environment to be generated for Pull Requests coming from fork repositories labels May 29, 2025
Copy link

Newest code from neflyte has been published to preview environment for Git SHA 7d92383

neflyte and others added 20 commits June 8, 2025 09:17
… if a TabContainer has already been parsed; Use a single instance of LOG_PREFIX; Set logging to DEBUG for collect_sections and sectiondata_to_toc; Add node ID utility method to TabContainer; Add logging to TabHtmlTransform; Process TabContainer nodes by walking the node tree instead of using a flat list of nodes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Contributor preview-environment Allow the preview environment to be generated for Pull Requests coming from fork repositories
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants