Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include source code as asset in releases to avoid issues with GitHub compression algorithm changes #1135

Open
kjlubick opened this issue Feb 1, 2023 · 2 comments

Comments

@kjlubick
Copy link

kjlubick commented Feb 1, 2023

The buildifier docs say to create an http_archive using a GitHub source archive URL like https://github.com/bazelbuild/buildtools/archive/refs/tags/4.2.2.tar.gz.

However, as was observed in a large outage on Jan 31, 2023, the compression algorithm used by GitHub can change, breaking sha256 validation.

The recommendation seems to be to include the source zip/tar.gz files in the release itself as an asset (like protobufs does). GitHub promises not to change those bytes since they are user-provided.

Then, the docs should show a URL like:
https://github.com/bazelbuild/buildtools/releases/download/4.2.2/source-4.2.2.tar.gz
depending on what file name for the source code asset is.

@kjlubick
Copy link
Author

kjlubick commented Feb 1, 2023

See also what rules_python did: bazelbuild/rules_python#1032

@luispadron
Copy link

Huge +1 here, any plans to do this?

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

No branches or pull requests

3 participants
@kjlubick @luispadron and others