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

feat: Add setting generate_hashes for requirements #1290

Merged
merged 2 commits into from
Jul 10, 2023
Merged

feat: Add setting generate_hashes for requirements #1290

merged 2 commits into from
Jul 10, 2023

Conversation

vonschultz
Copy link
Contributor

Add the new parameter generate_hashes (default True) to compile_pip_requirements(), letting the user control whether to put --hash entries in the requirements lock file generated. In particular if the generated file is supposed to be used as a constraints file the hashes don't make much sense.

Fixes #894.

Add the new parameter `generate_hashes` (default True) to
`compile_pip_requirements()`, letting the user control whether to put
`--hash` entries in the requirements lock file generated. In
particular if the generated file is supposed to be used as a
constraints file the hashes don't make much sense.

Fixes #894.
@google-cla
Copy link

google-cla bot commented Jul 2, 2023

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

Buildifier thinks there's an empty line too much. Fix the complaint.
@aignas
Copy link
Collaborator

aignas commented Jul 3, 2023

+1 to this change as right now I have a genrule that is stripping the hashes away in one of our projects.

Copy link
Collaborator

@chrislovecnm chrislovecnm left a comment

Choose a reason for hiding this comment

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

LGTM

@chrislovecnm chrislovecnm added this pull request to the merge queue Jul 10, 2023
Merged via the queue into bazelbuild:main with commit 3ffdf01 Jul 10, 2023
@vonschultz vonschultz deleted the generate_hashes branch July 10, 2023 18:27
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.

compile_pip_requirements: a way to disable hashes (for e.g. constraints files)
3 participants