Skip to content

docs: add version picker and manual release snapshots - #24792

Draft
yiaany wants to merge 13 commits into
apache:mainfrom
yiaany:docs/versioned-docs-17071
Draft

yiaany wants to merge 13 commits into
apache:mainfrom
yiaany:docs/versioned-docs-17071

Conversation

@yiaany

@yiaany yiaany commented Aug 30, 2026 •

Copy link
Copy Markdown
Contributor

Which issue does this PR close?

Rationale for this change

The documentation site currently follows main, so users cannot easily read the documentation that was published with a released DataFusion version. This change adds a version picker while keeping the site root on the current development documentation.

What changes are included in this PR?

  • Adds version switcher.

Are these changes tested?

Tested manually

Are there any user-facing changes?

Yes. The site will expose a version switcher and release URLs under /versions/<version>/, while the root URL continues to serve the latest main documentation.
Screenshot 2026-10-08 at 4 44 35 PM
Screenshot 2026-10-08 at 4 44 53 PM

@github-actions github-actions Bot added documentation Improvements or additions to documentation development-process Related to development process of DataFusion labels Aug 30, 2026
@yiaany

yiaany commented Sep 12, 2026

Copy link
Copy Markdown
Contributor Author

Hi @alamb and maintainers, just following up on this draft PR. It has been open since August 30, 2026, and the implementation and local validation are complete. The remaining question is the bootstrap sequence for publishing versions/55.0.0/ to asf-site. Could someone advise whether option 1 or option 2 in the PR description is preferred? I am happy to make any changes needed. Thanks!

@alamb

alamb commented Sep 13, 2026

Copy link
Copy Markdown
Contributor

Thank you @yiaany -- I had not seen this -- I will review it tomorrow

@yiaany

yiaany commented Sep 28, 2026

Copy link
Copy Markdown
Contributor Author

Hi @alamb, just checking in on this when you have a chance. It has been about two weeks since your last message. The checks are still green and I have not changed the PR since then. Please let me know if you would like any changes or if there is anything I should prepare for the review. Thanks!

@alamb

alamb commented Sep 28, 2026

Copy link
Copy Markdown
Contributor

I am so sorry -- yes this is one of those important but not urgent PRs that I have let slip down. 😢

I will test it out day

@alamb alamb left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thank you @yiaany

I apologize for the delay in reviewing. I was struggling to find enough time to write a proper response.

At a high level, I think this PR is too complicated for what it is doing-- which is probably my fault for not defining it more specifically. I apologize for not being clear

I was hoping:

  1. a static version list (you have it in versions.json I think)
  2. documentation of how old versions are published as part of the release process

I don't think we need to change the current CI for publishing / building documentation

Then I was imagining we test it locally like:

  1. manually build docs for a few versions (55.1.0 and 55.0.0 for example) and make a PR to the asf-site branch with the proposed layouts
  2. Build the docs from this PR
  3. Check out asf-site branch manually
  4. move the manually built docs from the PR and put the versioned docs in the right plce

If that looks good we could merge this main PR and I think the main docs site would be updated.

I am not sure how much value all the various python test scripts add. If you think they are important, we should document clearly their intent and what types of regressions / breakages they protect again

Could a maintainer confirm which bootstrap procedure should be used?

I suggest Build older site versions one statically / part of the release process (not via a CI action)

Finally, this might be easier to test if you setup your fork so it published your forks asf-site branch as a github pages, and then test out the code / picker there. That would also make it easy for other reviewers to test it out / see what it looks like

Comment thread .github/workflows/docs.yaml Outdated
branches:
- main
paths:
- .gitattributes

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

i think these changes are unrelated to this PR (to trigger on changes to pyproject/uv) -- can you please make a separate PR to add them to main (it will be easier to review / merge) along with the rationale?

Comment thread docs/scripts/assemble_site.py Outdated
# specific language governing permissions and limitations
# under the License.

"""Replace the current site while retaining immutable full-site snapshots."""

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Why do we need to replace the current site? This is pretty confusing to me

Comment thread docs/scripts/snapshot_site.py Outdated
# specific language governing permissions and limitations
# under the License.

"""Build one complete documentation snapshot from an exact release tag."""

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

don't we already have a build.sh script to do this? It seems like a lot of python code to call a few scripts 🤔

Comment thread docs/scripts/validate_site.py Outdated
# specific language governing permissions and limitations
# under the License.

"""Validate current and immutable full-site documentation output."""

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

What needs to be validated? I don't undertstand why we need a 400 line python script here

@@ -0,0 +1,14 @@
[

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Yes, this looks good

Comment thread docs/README.md Outdated
## Dependencies

Install build dependencies and build the documentation using
From the repository root, install the documentation dependencies using

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

if this needs changing, perhaps you can make another standalone PR to update the build docs

Comment thread docs/README.md Outdated
`docs/scripts/generate_dependency_graph.sh`, so ensure `cargo`, `cargo-depgraph`
(`cargo install cargo-depgraph --version ^1.6 --locked`), and Graphviz `dot`
(`brew install graphviz` or `sudo apt-get install -y graphviz`) are available.
`.gitattributes` keeps documentation shell scripts LF-terminated so the same

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

this seems like a somewhat irrelevant detail 🤔

Comment thread docs/README.md Outdated

Then open http://localhost:8000/.

The public and assembled layouts are:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

is this list necessary? It seems like it will just get out of date over time

Comment thread docs/README.md Outdated
and the release catalog. It contains `Development` at the site root and records
each release's semantic version, exact tag, and exact 40-character commit.

The first snapshot is the lightweight tag `55.0.0`, which peels to

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

"peels to"?

Comment thread .gitattributes Outdated
@@ -1,4 +1,6 @@
.github/ export-ignore
docs/*.sh text eol=lf

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

why is this needed?

@yiaany

yiaany commented Sep 29, 2026

Copy link
Copy Markdown
Contributor Author

Thank you @yiaany

I apologize for the delay in reviewing. I was struggling to find enough time to write a proper response.

At a high level, I think this PR is too complicated for what it is doing-- which is probably my fault for not defining it more specifically. I apologize for not being clear

I was hoping:

  1. a static version list (you have it in versions.json I think)
  2. documentation of how old versions are published as part of the release process

I don't think we need to change the current CI for publishing / building documentation

Then I was imagining we test it locally like:

  1. manually build docs for a few versions (55.1.0 and 55.0.0 for example) and make a PR to the asf-site branch with the proposed layouts
  2. Build the docs from this PR
  3. Check out asf-site branch manually
  4. move the manually built docs from the PR and put the versioned docs in the right plce

If that looks good we could merge this main PR and I think the main docs site would be updated.

I am not sure how much value all the various python test scripts add. If you think they are important, we should document clearly their intent and what types of regressions / breakages they protect again

Could a maintainer confirm which bootstrap procedure should be used?

I suggest Build older site versions one statically / part of the release process (not via a CI action)

Finally, this might be easier to test if you setup your fork so it published your forks asf-site branch as a github pages, and then test out the code / picker there. That would also make it easy for other reviewers to test it out / see what it looks like

Hi @alamb, thank you for the detailed review. You were right: I made the first version too complicated.

I’ve simplified #24792 to a static version list, the PyData version picker, and instructions for building and publishing release docs manually. I removed the custom build, deployment, validation, and test scripts. The existing docs CI and publishing workflow are unchanged in this PR.

I built the docs from the 55.0.0 and 55.1.0 tags and tested the version picker and missing-page fallback locally in a browser. The proposed generated layout is in #25881.

I also found that the current deployment’s rsync --delete would remove manually published release docs. I put the one-line fix in a separate PR, #25880. That change needs to land before the snapshots are published.

I haven’t set up a public GitHub Pages preview yet. Could you take another look at the smaller approach and let me know whether this matches what you had in mind?

@alamb

alamb commented Oct 8, 2026

Copy link
Copy Markdown
Contributor

Thank you @yiaany

I started going through this and made some changes / added documentation about how to test this locally.

I need to take one more pass through the instructions and then I think it will be good

Comment thread dev/release/README.md Outdated
Comment thread dev/release/README.md

**3. Add the release to the version picker.** Open a PR against `main` that
adds the release to `docs/source/_static/versions.json`. Put the new release
first and move `"preferred": true` to it, so that it is the default shown.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

CaptainEureka pushed a commit to CaptainEureka/datafusion that referenced this pull request Oct 9, 2026
- related to apache#17071

The documentation deploy uses rsync --delete, which would erase manually
published versions/ directories. Exclude /versions/ so normal
development-site deployments preserve release documentation. This
one-line deployment change is intentionally separate from apache#24792.

---------

Co-authored-by: Andrew Lamb <andrew@nerdnetworks.org>
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
alamb added a commit that referenced this pull request Oct 9, 2026
…25881)

- related to #17071

Publish complete generated documentation for the 55.0.0 and 55.1.0
release tags under versions/ on the asf-site branch. Built using the
tagged docs/build.sh and the small Sphinx configuration overlay in
#24792. The generated pages include a version picker, release-specific
canonical URLs, search indexes and static assets. Verified locally with
browser navigation across all three versions and the missing-page
fallback. This branch contains only one publication commit on top of
Apache asf-site;

- merging should follow the archive-retention change in #25880.

---------

Co-authored-by: Andrew Lamb <andrew@nerdnetworks.org>
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
Co-authored-by: Martin Grigorov <martin-g@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

development-process Related to development process of DataFusion documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Versioned documentation

3 participants