docs: group user and contributor guide nav into captioned sections#4424
Open
andygrove wants to merge 1 commit into
Open
docs: group user and contributor guide nav into captioned sections#4424andygrove wants to merge 1 commit into
andygrove wants to merge 1 commit into
Conversation
Reorganize the latest user-guide and the contributor-guide toctrees into captioned section groupings to replace the flat 14-item and 23-item lists. User guide (docs/source/user-guide/latest/index.rst): - Getting Started: Installing Comet, Configuration Settings - What Comet Supports: data sources, types, operators, expressions, ScalaUDF/Java UDF support - Compatibility: Compatibility Guide (and its sub-pages) - Operating Comet: Understanding Comet Plans, Tuning Guide, Metrics - Integrations: Iceberg, Kubernetes - Advanced: Building From Source Contributor guide (docs/source/contributor-guide/index.md): - Getting Started: Getting Started, Development Guide - Project Architecture: plugin overview, Arrow FFI, JVM/Native Shuffle, ANSI Error Propagation - Adding Functionality: operator, expression, Spark version - Testing: Comet SQL, Spark SQL, Iceberg Spark Tests - Debugging and Performance: Debugging, Benchmarking, Profiling, Tracing - Reference: Supported Spark Expressions and Configurations - Project Mechanics: Bug Triage, Release Process, Roadmap, GitHub The pydata-sphinx-theme used here flattens nested toctree captions when the sidebar is built from the global TOC, so the per-section captions only render if the sidebar starts from the section root. Update docs-sidebar.html to call generate_toctree_html with a section-relative startdepth (2 for user-guide/latest pages, 1 for contributor-guide pages, 0 otherwise) so the new captions appear in the left nav. Page bodies, file paths, and toctree entries are otherwise unchanged. Prev/next ordering follows the new section order. Part of apache#4421.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Which issue does this PR close?
Part of #4421. Lands step 1 of the migration plan (captions/grouping; no page moves or content changes).
Rationale for this change
The user guide and contributor guide toctrees had grown into flat 14- and 23-item lists with no narrative grouping. The issue proposes a section-based layout that makes it obvious where Getting Started lives, what is reference vs. operational vs. architectural, and where integrations and project mechanics fit. Step 1 is the toctree restructure, kept small so reviewers see the new shape without page renames or content rewrites.
The pydata-sphinx-theme used here builds the sidebar from the global TOC, so nested toctree captions get flattened away. Without a sidebar fix the new captions wouldn't render anywhere visible, so this PR also adjusts
docs-sidebar.htmlto render the per-section captions in the left nav.What changes are included in this PR?
docs/source/user-guide/latest/index.rst— split the single 14-item toctree into 5 captioned toctrees:docs/source/contributor-guide/index.md— split the single 23-item toctree into 7 captioned toctrees:No page renames, no file moves, no content rewrites in the page bodies. The link labels in the toctree directives are unchanged from the originals.
docs/source/_templates/docs-sidebar.html— switch from the bare Sphinxtoctree()macro to pydata-sphinx-theme'sgenerate_toctree_html()with a section-relativestartdepthso captions render in the sidebar:user-guide/latest/*starts at depth 2 (underuser-guide/index→latest/index)contributor-guide/*starts at depth 1 (undercontributor-guide/index)search,genindexand other orphan pages fall back tostartdepth=0(global TOC, same as before)The fallback uses pydata's
suppress_sidebar_toctree(startdepth=..., includehidden=True)so pages without a captioned ancestor still render their sidebar instead of erroring.Out of scope for this PR (deferred from the issue):
How are these changes tested?
Built the docs with
sphinx-build -b html source buildand verified:user-guide/0.{13,14,15,16}/indexare pre-existing and come from versions generated bygenerate-versions.pyat build time).installation → configs → datasources → … → kubernetes → source → Contributor Guideandcontributing → development → plugin_overview → … → release_process → roadmap.user-guide/indexversion selector still render correctly with their existing captions.