Skip to content

refactor(pypi): add whl_deps_library repo rule - #3960

Merged
rickeylev merged 15 commits into
bazel-contrib:mainfrom
aignas:aignas.refactor.whl_library_srcs_deps_switch
Aug 1, 2026
Merged

refactor(pypi): add whl_deps_library repo rule#3960
rickeylev merged 15 commits into
bazel-contrib:mainfrom
aignas:aignas.refactor.whl_library_srcs_deps_switch

Conversation

@aignas

@aignasaignas commented Jul 27, 2026

Copy link
Copy Markdown
Collaborator

Summary:

  • Add a new repo rule to just read metadata.json
  • Add integration tests for the repository rules in whl_library.bzl
    file.
  • Make some of the arguments optional in the BUILD.bazel code
    generation.

No changelog, because the rule is not yet exposed to the user in any way.

Split out of #3856
Work towards #2948
Fixes#3071

Summary:
- Add a new repo rule to just read metadata.json
- Add integration tests for the repository rules in `whl_library.bzl`
file.
- Make some of the arguments optional in the BUILD.bazel code
generation.
Split out of bazel-contrib#3856
Work towards bazel-contrib#2948
@gemini-code-assist

Copy link
Copy Markdown
Contributor

Caution

The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased.

@aignas

Copy link
Copy Markdown
CollaboratorAuthor

Ran out of time working on this, feel free to hose this with AI tokens if desired.

@aignas
aignas marked this pull request as ready for review July 27, 2026 13:50
@aignas
aignas requested a review from rickeylev as a code ownerJuly 27, 2026 13:50
@gemini-code-assist

Copy link
Copy Markdown
Contributor

Caution

The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased.

rickeylevand others added 6 commits July 28, 2026 19:11
… tests
To prevent test failures across Bazel 7, 8, and 9 where Bzlmod canonical
repository prefixes vary, dynamically parse canonical repository strings by
splitting on '~' and '+'. Also filter out version-dependent toolchain type
targets from dependency comparisons.
@aignas

Copy link
Copy Markdown
CollaboratorAuthor

OK, please take a look.

@rickeylevrickeylev changed the title feat(pypi): add whl_deps_library repo rulerefactor(pypi): add whl_deps_library repo ruleAug 1, 2026

@rickeylevrickeylev left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

LGTM. I renamed this to refactor(pypi). I'm pretty sure this is just an internal refactoring. I don't see any public APIs added or changed.

@rickeylev
rickeylev added this pull request to the merge queueAug 1, 2026
Merged via the queue into bazel-contrib:main with commit fd25d1fAug 1, 2026
8 checks passed
rickeylev pushed a commit to rickeylev/rules_python that referenced this pull request Aug 1, 2026
…ntrib#3979)
This adds a test to verify that bazel files are excluded from the
files matched from an extracted wheel.
Followup to bazel-contrib#3960
Work towards bazel-contrib#2948
Sign up for freeto 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.

Create a test that tests whl_library with an sdist

2 participants

@aignas@rickeylev