-
Notifications
You must be signed in to change notification settings - Fork 543
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(pypi): pass requirements without env markers to the whl_library (#…
…2488) With this change the environment markers from the requirements.txt files no longer end up in the whl_library definitions. I am reusing a function that already is parsing each requirement line for `sha256` values and added logic to extract the `marker` at that point. This means that the change is also trivial to backport to the `WORKSPACE` and the logic in the extension becomes simpler and we don't rely only on integration tests. Expected changes to the users: * If they have vendored pip requirements in `WORKSPACE`, those will be reformatted and the env markers will be removed. * The `MODULE.bazel.lock` file will be likewise reformatted if users are not using `--experimental_index_url`. Also, the env markers will not be passed in the `requirement`. * `bazel query 'deps("@pypi//foo")'` should start working in more cases. Fixes #2450. --------- Co-authored-by: Richard Levasseur <[email protected]>
- Loading branch information
Showing
9 changed files
with
160 additions
and
83 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.