Skip to content

Conversation

fmeum
Copy link
Collaborator

@fmeum fmeum commented Jun 27, 2025

With the flag enabled, <binary>.repo_mapping contains

+deps+*,aaa,_main
+deps+*,dep,+deps+dep1
+deps+*,dep1,+deps+dep1
+deps+*,dep2,+deps+dep2
+deps+*,dep3,+deps+dep3

instead of

+deps+dep1,aaa,_main
+deps+dep1,dep,+deps+dep1
+deps+dep1,dep1,+deps+dep1
+deps+dep1,dep2,+deps+dep2
+deps+dep1,dep3,+deps+dep3
+deps+dep2,aaa,_main
+deps+dep2,dep,+deps+dep1
+deps+dep2,dep1,+deps+dep1
+deps+dep2,dep2,+deps+dep2
+deps+dep2,dep3,+deps+dep3
...

for the deps module extension.

Runfiles libraries have to be updated to find entries using the new format.

Work towards #24808

Closes #24809.

RELNOTES: Added --incompatible_compact_repo_mapping_manifest, which causes the repo mapping manifest file for runfiles to use a more compact format when necessary.

PiperOrigin-RevId: 774871526
Change-Id: I9429860975a2b1ba072777ad6cf9571bb2f4c91f
(cherry picked from commit 39b9d3c)

Closes #26240

With the flag enabled, `<binary>.repo_mapping` contains
```
+deps+*,aaa,_main
+deps+*,dep,+deps+dep1
+deps+*,dep1,+deps+dep1
+deps+*,dep2,+deps+dep2
+deps+*,dep3,+deps+dep3
```
instead of
```
+deps+dep1,aaa,_main
+deps+dep1,dep,+deps+dep1
+deps+dep1,dep1,+deps+dep1
+deps+dep1,dep2,+deps+dep2
+deps+dep1,dep3,+deps+dep3
+deps+dep2,aaa,_main
+deps+dep2,dep,+deps+dep1
+deps+dep2,dep1,+deps+dep1
+deps+dep2,dep2,+deps+dep2
+deps+dep2,dep3,+deps+dep3
...
```
for the `deps` module extension.

Runfiles libraries have to be updated to find entries using the new format.

Work towards bazelbuild#24808

Closes bazelbuild#24809.

RELNOTES: Added `--incompatible_compact_repo_mapping_manifest`, which causes the repo mapping manifest file for runfiles to use a more compat format when necessary.
PiperOrigin-RevId: 774871526
Change-Id: I9429860975a2b1ba072777ad6cf9571bb2f4c91f
(cherry picked from commit 39b9d3c)
@fmeum fmeum requested a review from a team as a code owner June 27, 2025 13:15
@fmeum fmeum requested a review from Wyverald June 27, 2025 13:15
@github-actions github-actions bot added team-Configurability platforms, toolchains, cquery, select(), config transitions team-Rules-Python Native rules for Python awaiting-review PR is awaiting review from an assigned reviewer labels Jun 27, 2025
@fmeum
Copy link
Collaborator Author

fmeum commented Jun 27, 2025

@Wyverald The BuildViewTestCase is failing because it doesn't find repository_rule in the predeclared Starlark env. Is something missing in BazelRuleClassProvider that is available on master? I couldn't figure out where BazelRepositoryModule needs to be wired up exactly.

@Wyverald
Copy link
Member

You need this line: https://cs.opensource.google/bazel/bazel/+/master:src/test/java/com/google/devtools/build/lib/testutil/TestRuleClassProvider.java;drc=3b555d592def7d905d802eb2329baf26d8c2c27f;l=77

On master this is included by default in the TestRuleClassProviders, but in 8.x you need to insert it yourself.

@fmeum
Copy link
Collaborator Author

fmeum commented Jun 29, 2025

@Wyverald Thanks for the pointer, fixed

@Wyverald Wyverald added this pull request to the merge queue Jun 30, 2025
Merged via the queue into bazelbuild:release-8.4.0 with commit bfdddec Jun 30, 2025
46 checks passed
@github-actions github-actions bot removed the awaiting-review PR is awaiting review from an assigned reviewer label Jun 30, 2025
@fmeum fmeum deleted the 26240-cherry branch July 5, 2025 13:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
team-Configurability platforms, toolchains, cquery, select(), config transitions team-Rules-Python Native rules for Python
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants