Skip to content

chore: fix generate-release-docs.sh for per-Spark-version doc layout#4662

Merged
mbutrovich merged 1 commit into
apache:mainfrom
mbutrovich:update-release-docs-script
Jun 16, 2026
Merged

chore: fix generate-release-docs.sh for per-Spark-version doc layout#4662
mbutrovich merged 1 commit into
apache:mainfrom
mbutrovich:update-release-docs-script

Conversation

@mbutrovich

Copy link
Copy Markdown
Contributor

Which issue does this PR close?

Closes #.

Rationale for this change

dev/generate-release-docs.sh freezes generated docs onto a release branch. It has been broken since #4139, which split compatibility/expressions/ into per-Spark-version subdirectories (spark-3.4 .. spark-4.1) plus _category_template/. That PR updated the publish-time generator (docs/build.sh) and GenerateDocs but not this script, so it still called GenerateDocs with only the user-guide root, hit the removed flat path, and failed with FileNotFoundException: .../compatibility/expressions/cast.md. No release has been cut since, so it went unnoticed.

What changes are included in this PR?

Bring the script in line with docs/build.sh: loop the Spark profiles, copy _category_template/*.md into each spark-<ver>/, and run GenerateDocs per profile with -Dexec.arguments="<latest-user-guide>,<profile>" to pass the subdirectory arg. Also run prettier --write over the output, since CI checks prettier --check "**/*.md" and this script (unlike build.sh, whose temp output is throwaway) commits its result. _category_template/ is kept as committed source. The only difference from build.sh is that this runs against the source tree so the freeze can be committed. The same fix lands on branch-0.17 bundled with the generated docs freeze; on main the generated docs are not committed, so this PR carries the script change alone.

How are these changes tested?

Ran on a 0.17.0 release branch: configs.md populated, all four spark-<ver>/ dirs contain cast.md plus category pages with filled tables, per-version differences land where expected (map.md/misc.md differ 3.4 vs 4.1, misc.md differs 3.4 vs 3.5, 4.0 == 4.1), and prettier --check passes.

@andygrove andygrove left a comment

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.

Thanks for fixing this @mbutrovich!

@mbutrovich mbutrovich merged commit e211ef0 into apache:main Jun 16, 2026
16 checks passed
marvelshan pushed a commit to marvelshan/datafusion-comet that referenced this pull request Jul 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants