Skip to content

docs: Remove redundant table of contents#27235

Merged
steveburnett merged 1 commit intoprestodb:masterfrom
dnskr:docs-remove-redundant-contents
Mar 11, 2026
Merged

docs: Remove redundant table of contents#27235
steveburnett merged 1 commit intoprestodb:masterfrom
dnskr:docs-remove-redundant-contents

Conversation

@dnskr
Copy link
Copy Markdown
Contributor

@dnskr dnskr commented Feb 28, 2026

Description

Remove redundant table of contents from some documentation pages.

Motivation and Context

The Presto documentation layout features a table of contents on the right side of all pages.
On pages where this sidebar remains visible within the screen view, the identical (or nearly identical) table of contents at the top can be removed as redundant.

  1. Pages where the table of contents at the top has depth 2 (changed to 1 in the PR):
  • (0.297-SNAPSHOT) ./presto/presto-docs/target/html/presto_cpp/metrics.html
  1. Pages with identical table of contents:
  1. Pages where the right sidebar fits the screen:
  1. Pages where the right sidebar almost fits the screen:
  1. Pages that require some scrolling in the right sidebar:
  1. Pages that require scrolling in the right sidebar should remain unchanged:

Impact

No

Build the documentation and check that the pages are correct:

presto-docs/build
open target/html/overview/concepts.html

Contributor checklist

  • Please make sure your submission complies with our contributing guide, in particular code style and commit standards.
  • PR description addresses the issue accurately and concisely. If the change is non-trivial, a GitHub Issue is referenced.
  • Documented new properties (with its default value), SQL syntax, functions, or other functionality.
  • If release notes are required, they follow the release notes guidelines.
  • Adequate tests were added if applicable.
  • CI passed.
  • If adding new dependencies, verified they have an OpenSSF Scorecard score of 5.0 or higher (or obtained explicit TSC approval for lower scores).

Release Notes

== NO RELEASE NOTE ==

Summary by Sourcery

Documentation:

  • Clean up multiple documentation pages by deleting duplicated top-of-page tables of contents while keeping the layout sidebar TOC as the single source of navigation.

@dnskr dnskr requested review from a team, elharo and steveburnett as code owners February 28, 2026 20:38
@sourcery-ai
Copy link
Copy Markdown
Contributor

sourcery-ai bot commented Feb 28, 2026

Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

Removes redundant top-of-page table-of-contents sections from multiple Sphinx .rst documentation pages so the layout relies on the built-in sidebar/inline TOC instead of duplicated content.

File-Level Changes

Change Details Files
Remove manually maintained table-of-contents sections from affected documentation pages.
  • Deleted the explicit table-of-contents section blocks from various admin, cache, client, connector, ecosystem, installation, overview, Presto C++, router, and troubleshooting .rst documents.
  • Kept the rest of each document’s structure, headings, and content unchanged so that only the redundant TOC content is removed.
  • Aligned the generated HTML with the site-wide layout that already provides a TOC in the page chrome.
presto-docs/src/main/sphinx/admin/spill.rst
presto-docs/src/main/sphinx/cache/local.rst
presto-docs/src/main/sphinx/cache/service.rst
presto-docs/src/main/sphinx/clients/presto-cli.rst
presto-docs/src/main/sphinx/clients/presto-console.rst
presto-docs/src/main/sphinx/connector/accumulo.rst
presto-docs/src/main/sphinx/connector/hive.rst
presto-docs/src/main/sphinx/connector/kafka-tutorial.rst
presto-docs/src/main/sphinx/connector/kudu.rst
presto-docs/src/main/sphinx/ecosystem/list.rst
presto-docs/src/main/sphinx/installation/deployment.rst
presto-docs/src/main/sphinx/overview/concepts.rst
presto-docs/src/main/sphinx/presto_cpp/metrics.rst
presto-docs/src/main/sphinx/presto_cpp/sidecar.rst
presto-docs/src/main/sphinx/router/deployment.rst
presto-docs/src/main/sphinx/router/scheduler.rst
presto-docs/src/main/sphinx/troubleshoot/deploy.rst
presto-docs/src/main/sphinx/troubleshoot/query.rst

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

Copy link
Copy Markdown
Contributor

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey - I've reviewed your changes and they look great!


Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

Copy link
Copy Markdown
Contributor

@steveburnett steveburnett left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for all the time you took examining this issue! I don't agree that the majority of the affected pages in this PR would benefit from the table of contents being removed from the top of the page. This is partly because I don't find a clear distinction between the examples of pages to remove the table of contents from, and pages that are recommended should stay unchanged.

For example, this PR recommends removing the table of contents from
https://prestodb.github.io/docs/0.296/connector/kudu.html
but not from
https://prestodb.github.io/docs/0.296/connector/elasticsearch.html

I do agree with the removal recommendation for the following pages in this PR:
https://prestodb.github.io/docs/0.296/cache/local.html
https://prestodb.github.io/docs/0.296/cache/service.html
https://prestodb.github.io/docs/0.296/ecosystem/list.html
https://prestodb.github.io/docs/0.296/router/scheduler.html

Revise this PR to these four pages and I'll approve it. Thanks again!

@github-project-automation github-project-automation bot moved this from 🆕 Unprioritized to 🏗 In progress in Presto Documentation Mar 3, 2026
@dnskr
Copy link
Copy Markdown
Contributor Author

dnskr commented Mar 3, 2026

@steveburnett Thank you for the review!

The criterion I used to distinguish the pages is: "Does the table of contents on the right fit the screen?"
I have updated the PR description and organized the pages into five main groups. I think we can remove the table of contents for groups 1, 2, and maybe 3.

Please let me know your thoughts after another look, and I’ll update the PR accordingly.

@steveburnett
Copy link
Copy Markdown
Contributor

Thanks for the explanation! I've considered your reasoning and grouping. I don't consider a redundant table of contents as a bad thing as different readers will use different paths to find the information they want. That said, your grouping helps me understand your goals, and now I am okay with removing the table of contents from these pages:

https://prestodb.github.io/docs/0.296/cache/local.html
https://prestodb.github.io/docs/0.296/cache/service.html
https://prestodb.github.io/docs/0.296/ecosystem/list.html
https://prestodb.github.io/docs/0.296/router/scheduler.html
https://prestodb.github.io/docs/0.296/admin/spill.html
https://prestodb.github.io/docs/0.296/router/deployment.html

At this time, I'm also okay with changing the level on
(0.297-SNAPSHOT) ./presto/presto-docs/target/html/presto_cpp/metrics.html

Hope this helps!

@dnskr dnskr force-pushed the docs-remove-redundant-contents branch from e2040f4 to b0eea2b Compare March 4, 2026 19:14
@dnskr dnskr requested a review from steveburnett March 4, 2026 20:09
Copy link
Copy Markdown
Contributor

@steveburnett steveburnett left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! (docs)

Pull updated branch, new local doc build, looks good. Thanks!

@github-project-automation github-project-automation bot moved this from 🏗 In progress to ✅ Done in Presto Documentation Mar 5, 2026
@yhwang
Copy link
Copy Markdown
Member

yhwang commented Mar 10, 2026

Hi @dnskr, could you rebase your branch? I fixed the arrow flight GH action issue on the upstream. After rebase, your doc-only PR should be able to skip the arrowflight CI job.

@dnskr dnskr force-pushed the docs-remove-redundant-contents branch from b0eea2b to 6966b1f Compare March 10, 2026 18:05
@steveburnett steveburnett merged commit 31f7d85 into prestodb:master Mar 11, 2026
82 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

Status: ✅ Done

Development

Successfully merging this pull request may close these issues.

3 participants