Skip to content

[9.1.0] Force rctx.{download_and,}extract to create user-readable files (https://github.com/bazelbuild/bazel/pull/28531)#28547

Merged
iancha1992 merged 1 commit intobazelbuild:release-9.1.0from
bazel-io:cp28531-9.1.0
Feb 6, 2026

Conversation

@bazel-io
Copy link
Member

@bazel-io bazel-io commented Feb 5, 2026

Archives in the wild do sometimes contain non-readable files, but other tools work around this and thus mask their brokenness.

Context: https://bazelbuild.slack.com/archives/CDCMRLS23/p1770213515354229

Closes #28531.

PiperOrigin-RevId: 865960367
Change-Id: I7273eb983d63d6960d184764cec5040bba77b2c2

Commit 0bb7836

…zelbuild#28531)

Archives in the wild do sometimes contain non-readable files, but other tools work around this and thus mask their brokenness.

Context: https://bazelbuild.slack.com/archives/CDCMRLS23/p1770213515354229

Closes bazelbuild#28531.

PiperOrigin-RevId: 865960367
Change-Id: I7273eb983d63d6960d184764cec5040bba77b2c2
@bazel-io bazel-io requested a review from a team as a code owner February 5, 2026 16:30
@bazel-io bazel-io added team-ExternalDeps External dependency handling, remote repositiories, WORKSPACE file. awaiting-review PR is awaiting review from an assigned reviewer labels Feb 5, 2026
@bazel-io bazel-io requested a review from meteorcloudy February 5, 2026 16:30
Copy link

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request ensures that files extracted from archives are always user-readable by adding the 0400 permission bit. This change is applied consistently across decompressors for ar, tar, and zip formats. The new shell tests are comprehensive, verifying the corrected behavior for all three archive types by creating archives with non-readable files and confirming they are readable after extraction. The changes appear correct and are well-tested.

@iancha1992 iancha1992 enabled auto-merge February 5, 2026 20:13
@iancha1992 iancha1992 added this pull request to the merge queue Feb 6, 2026
Merged via the queue into bazelbuild:release-9.1.0 with commit c8a1973 Feb 6, 2026
46 checks passed
@github-actions github-actions bot removed the awaiting-review PR is awaiting review from an assigned reviewer label Feb 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

team-ExternalDeps External dependency handling, remote repositiories, WORKSPACE file.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants