-
-
Notifications
You must be signed in to change notification settings - Fork 631
feat(pypi): enable pipstar by default #3225
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
Merged
aignas
merged 30 commits into
bazel-contrib:main
from
aignas:aignas.exp.bzlmod.enable.pipstar
Oct 5, 2025
Merged
Changes from all commits
Commits
Show all changes
30 commits
Select commit
Hold shift + click to select a range
1c768ca
feat(pypi): enable pipstar by default on bzlmod
aignas 10692ce
chore: cleanup bzlmod codebase after pipstar enabling
aignas 6177306
Revert "chore: cleanup bzlmod codebase after pipstar enabling"
aignas b8bb5fa
enable pipstar in tests
aignas 1194739
Merge branch 'main' into aignas.exp.bzlmod.enable.pipstar
aignas 2ab8e3c
chore: also enable pipstar on WORKSPACE
aignas 320b65f
pass a dummy list instead of passing dep_template
aignas 8fc665e
a better included packages passing
aignas 8ceeee6
actually turn the switch on for WORKSPACE
aignas 881e6bf
fix the dep wiring in WORKSPACE
aignas a9e4e83
add a note
aignas e096244
fixup
aignas 47b80c4
add extra docs to the changelog and adjust a bit
aignas 162c2f4
also test what we suggest in CHANGELOG
aignas c8bd484
Apply suggestion from @gemini-code-assist[bot]
aignas e6e60ac
Update CHANGELOG.md
aignas a91a147
wip
aignas 52d65dd
remove the CHANGELOG note
aignas e5916e7
use hub aliases repo if available: wip finish multi_pip_parse if needed
aignas af68cce
consolidate the config and group libraries
aignas a61e676
fixup
aignas e6f09b5
further cleanup to prepare for final review
aignas 323cb13
extra tidyup and fixes
aignas 5157614
deprecated is not an attr kwarg
aignas 4b18416
fixup
aignas 513c8bb
Merge branch 'main' into aignas.exp.bzlmod.enable.pipstar
aignas 42fef58
clarify wording
aignas ff28b1b
comments
aignas a0e4b47
fixup! comments
aignas f308d07
add notes about vendoring
aignas File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
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
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
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
This file was deleted.
Oops, something went wrong.
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
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
"""whl_config_library implementation for WORKSPACE setups.""" | ||
|
||
load("//python/private:text_util.bzl", "render") | ||
load(":generate_group_library_build_bazel.bzl", "generate_group_library_build_bazel") | ||
|
||
def _whl_config_repo_impl(rctx): | ||
build_file_contents = generate_group_library_build_bazel( | ||
repo_prefix = rctx.attr.repo_prefix, | ||
groups = rctx.attr.groups, | ||
) | ||
rctx.file("_groups/BUILD.bazel", build_file_contents) | ||
rctx.file("BUILD.bazel", "") | ||
rctx.template( | ||
"config.bzl", | ||
rctx.attr._config_template, | ||
substitutions = { | ||
"%%PACKAGES%%": render.dict(rctx.attr.whl_map or {}, value_repr = lambda x: "None"), | ||
}, | ||
) | ||
|
||
whl_config_repo = repository_rule( | ||
attrs = { | ||
"groups": attr.string_list_dict( | ||
doc = "A mapping of group names to requirements within that group.", | ||
), | ||
"repo_prefix": attr.string( | ||
doc = "Prefix used for the whl_library created components of each group", | ||
), | ||
"whl_map": attr.string_dict( | ||
doc = """\ | ||
The wheel map where values are json.encoded strings of the whl_map constructed | ||
in the pip.parse tag class. | ||
""", | ||
), | ||
"_config_template": attr.label( | ||
default = ":config.bzl.tmpl", | ||
), | ||
}, | ||
doc = """ | ||
Create a package containing only wrapper py_library and whl_library rules for implementing dependency groups. | ||
This is an implementation detail of dependency groups and should not be used alone. | ||
|
||
PRIVATE USE ONLY, only used in WORKSPACE. | ||
""", | ||
implementation = _whl_config_repo_impl, | ||
) |
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.