Repository navigation
MINOR: Keep the Thrift build out of release commits and artifacts - #3929
Merged
Merged
Conversation
The prepare-RC workflow runs dev/ci-before_install.sh, which extracted and built Thrift inside the checkout. prepare-rc.sh then staged the version bump with `git add -A`, so 1.18.2-rc0's "Set version" commit picked up the whole thrift-0.25.0/ tree, compiled .o files included. `mvn deploy` also packaged that tree into the Nexus source-release zip. - Build Thrift in a temporary directory outside the checkout. - Stage only tracked files when committing version bumps. - Refuse to tag and deploy an RC from a working tree that has uncommitted changes or untracked files. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Nov 3, 2026
RussellSpitzer
approved these changes
Nov 3, 2026
RussellSpitzer
left a comment
Member
There was a problem hiding this comment.
I knew that thrift build was going to come back to bite me.
Fokko
pushed a commit
that referenced
this pull request
Nov 3, 2026
This reverts commit 490699b. Besides bumping the POMs to 1.18.2, that commit picked up the thrift-0.25.0/ directory the prepare-RC workflow had built in the checkout (prepare-rc.sh staged with `git add -A`). That put 3,550 Thrift files, compiled .o files included, into 1.18.2-rc0. Reverting puts the branch back to 9ea3b78 (1.18.2-SNAPSHOT), so the next prepare-RC run makes a fresh version-bump commit. The workflow side is fixed on master in #3929, which must be merged before that run. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Fokko
approved these changes
Nov 3, 2026
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.
Rationale for this change
The 1.18.2-rc0 source artifacts contain the whole Thrift 0.25.0 source and build tree:
apache-parquet-<v>.tar.gz(dist/dev)parquet-<v>-source-release.zip(Nexus)Here is how it happened:
release-prepare-rc.ymlrunsdev/ci-before_install.sh("Install Thrift", added in Prepare RC: install Thrift before the release build #3786). That script extracts and builds Thrift in the current directory, which is the checkout being released.prepare-rc.shstages the version bump withgit add -A. The release commit 490699b ("Set version to 1.18.2 for release") therefore includes the 18 pom bumps plus 3,550 files underthrift-0.25.0/, including 40 x86-64 ELF.ofiles.git archivethen put them into the source tarball.mvn deploy -Papache-releasepackages the working tree, not the git tree, into the source-release zip. That zip would contain the Thrift build even if it had never been committed.The 1.19.0 RCs were not affected only because their version-bump commit (d29073e, 2026-09-03) predates #3786, and later RCs skipped the bump because the POMs were already at 1.19.0. Every new version prepared through the workflow would hit this.
What changes are included in this PR?
dev/ci-before_install.sh: build Thrift in amktemp -ddirectory under$RUNNER_TEMP, so it never lands in the checkout. The release workflow runs frommaster, so this covers releases from every branch. The CI workflows that use the script only need the installedthriftbinary.prepare-rc.sh/publish-release.sh: stage version bumps withgit add -u.versions:setandversions:set-propertyonly edit tracked POMs.require_clean_worktreeinrelease/libs/_exec.sh.prepare-rc.shcalls it right before creating the RC tag, so a working tree with uncommitted changes or untracked files fails the run. It is a plain read, not anexec_processcall, so it also runs in dry-run mode.I did not add
thrift-*/to.gitignoreon purpose: ignored files would pass the clean-tree check but still end up in the source-release zip.This PR does not clean up
parquet-1.18.x, where 490699b is the branch head and still containsthrift-0.25.0/. That will be handled separately before 1.18.2-rc1.Are these changes tested?
require_clean_worktree: clean tree, gitignored files, untracked directory, uncommitted change, and running outside a git repository.shellcheckreports no new findings in the changed scripts.ci-before_install.shchange.Are there any user-facing changes?
No. This only changes the release tooling and the CI setup script.
🤖 Generated with Claude Code