Skip to content

Conversation

@fmeum
Copy link
Collaborator

@fmeum fmeum commented Sep 27, 2024

This allows IDEs to query for the direct dependencies of the root module as well as how they can refer to them from the point of view of the root module.

Also always emit name and version so that consumers don't have to know how to parse module keys.

Work towards #22691

@fmeum
Copy link
Collaborator Author

fmeum commented Sep 27, 2024

@bazel-io fork 7.4.0

@fmeum fmeum force-pushed the 22691-bazel-mod-apparent-name branch from e0a4ce7 to 7bb1ad2 Compare September 27, 2024 12:23
@fmeum fmeum marked this pull request as ready for review September 27, 2024 12:25
@github-actions github-actions bot added team-ExternalDeps External dependency handling, remote repositiories, WORKSPACE file. awaiting-review PR is awaiting review from an assigned reviewer labels Sep 27, 2024
@fmeum
Copy link
Collaborator Author

fmeum commented Sep 27, 2024

@meteorcloudy @Wyverald I'm planning to pair this with another PR that allows --override_repository to add new repos even with --noenable_workspace, which then use the main repos mapping.

@fmeum fmeum force-pushed the 22691-bazel-mod-apparent-name branch from 7bb1ad2 to 9f00f77 Compare September 27, 2024 12:27
@Wyverald Wyverald added awaiting-PR-merge PR has been approved by a reviewer and is ready to be merge internally and removed awaiting-review PR is awaiting review from an assigned reviewer labels Nov 5, 2024
@fmeum
Copy link
Collaborator Author

fmeum commented Nov 5, 2024

@bazel-io fork 8.0.0

@copybara-service copybara-service bot closed this in 1003d2c Nov 5, 2024
@github-actions github-actions bot removed the awaiting-PR-merge PR has been approved by a reviewer and is ready to be merge internally label Nov 5, 2024
@fmeum fmeum deleted the 22691-bazel-mod-apparent-name branch November 5, 2024 21:20
bazel-io pushed a commit to bazel-io/bazel that referenced this pull request Nov 6, 2024
This allows IDEs to query for the direct dependencies of the root module as well as how they can refer to them from the point of view of the root module.

Also always emit `name` and `version` so that consumers don't have to know how to parse module keys.

Work towards bazelbuild#22691

Closes bazelbuild#23787.

PiperOrigin-RevId: 693453084
Change-Id: Ie3fd5e89301d8e83d0eaa686188634923853f01a
github-merge-queue bot pushed a commit that referenced this pull request Nov 7, 2024
…4234)

This allows IDEs to query for the direct dependencies of the root module
as well as how they can refer to them from the point of view of the root
module.

Also always emit `name` and `version` so that consumers don't have to
know how to parse module keys.

Work towards #22691

Closes #23787.

PiperOrigin-RevId: 693453084
Change-Id: Ie3fd5e89301d8e83d0eaa686188634923853f01a

Commit
1003d2c

Co-authored-by: Fabian Meumertzheim <[email protected]>
github-merge-queue bot pushed a commit that referenced this pull request Nov 8, 2024
…4234)

This allows IDEs to query for the direct dependencies of the root module
as well as how they can refer to them from the point of view of the root
module.

Also always emit `name` and `version` so that consumers don't have to
know how to parse module keys.

Work towards #22691

Closes #23787.

PiperOrigin-RevId: 693453084
Change-Id: Ie3fd5e89301d8e83d0eaa686188634923853f01a

Commit
1003d2c

Co-authored-by: Fabian Meumertzheim <[email protected]>
@fmeum
Copy link
Collaborator Author

fmeum commented Dec 13, 2024

@bazel-io fork 7.5.0

ramil-bitrise pushed a commit to bitrise-io/bazel that referenced this pull request Dec 18, 2024
This allows IDEs to query for the direct dependencies of the root module as well as how they can refer to them from the point of view of the root module.

Also always emit `name` and `version` so that consumers don't have to know how to parse module keys.

Work towards bazelbuild#22691

Closes bazelbuild#23787.

PiperOrigin-RevId: 693453084
Change-Id: Ie3fd5e89301d8e83d0eaa686188634923853f01a
fmeum added a commit to fmeum/bazel that referenced this pull request Jan 7, 2025
This allows IDEs to query for the direct dependencies of the root module as well as how they can refer to them from the point of view of the root module.

Also always emit `name` and `version` so that consumers don't have to know how to parse module keys.

Work towards bazelbuild#22691

Closes bazelbuild#23787.

PiperOrigin-RevId: 693453084
Change-Id: Ie3fd5e89301d8e83d0eaa686188634923853f01a
(cherry picked from commit 1003d2c)

Fixes bazelbuild#24678
meteorcloudy pushed a commit that referenced this pull request Jan 9, 2025
…4847)

This allows IDEs to query for the direct dependencies of the root module
as well as how they can refer to them from the point of view of the root
module.

Also always emit `name` and `version` so that consumers don't have to
know how to parse module keys.

Work towards #22691

Closes #23787.

PiperOrigin-RevId: 693453084
Change-Id: Ie3fd5e89301d8e83d0eaa686188634923853f01a (cherry picked from
commit 1003d2c)

Fixes #24678
hb-man pushed a commit to JetBrains/hirschgarten that referenced this pull request Jan 9, 2026
... instead of using the repository mapping to get them from the
keys. The aparent name is set[1] in all versions since bazel 7.4
and hence, in particular, in all supported versions of bazel.
Also use the name set by bazel instead of reverse engineering it
from the key.

By using the apparent name set by bazel, we also get the most useful
apparent name, i.e., the one used in the repository closest to the
main one. In particular, we avoid having to invert a repository
mapping which is not a meaningful operation, given that the map
depends on the repository the resolution happens in.

[1] bazelbuild/bazel#23787

GitOrigin-RevId: c3932a800e45eb4c53e6cf32e1af2d2457ba4d7b
hb-man pushed a commit to JetBrains/hirschgarten that referenced this pull request Jan 12, 2026
... instead of using the repository mapping to get them from the
keys. The aparent name is set[1] in all versions since bazel 7.4
and hence, in particular, in all supported versions of bazel.
Also use the name set by bazel instead of reverse engineering it
from the key.

By using the apparent name set by bazel, we also get the most useful
apparent name, i.e., the one used in the repository closest to the
main one. In particular, we avoid having to invert a repository
mapping which is not a meaningful operation, given that the map
depends on the repository the resolution happens in.

[1] bazelbuild/bazel#23787

GitOrigin-RevId: 0b66b94f4a2d7d949ac7d927bdbe0b267c449cf9
hb-man pushed a commit to JetBrains/hirschgarten that referenced this pull request Jan 12, 2026
... instead of using the repository mapping to get them from the
keys. The aparent name is set[1] in all versions since bazel 7.4
and hence, in particular, in all supported versions of bazel.
Also use the name set by bazel instead of reverse engineering it
from the key.

By using the apparent name set by bazel, we also get the most useful
apparent name, i.e., the one used in the repository closest to the
main one. In particular, we avoid having to invert a repository
mapping which is not a meaningful operation, given that the map
depends on the repository the resolution happens in.

[1] bazelbuild/bazel#23787

GitOrigin-RevId: 0b66b94f4a2d7d949ac7d927bdbe0b267c449cf9
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

team-ExternalDeps External dependency handling, remote repositiories, WORKSPACE file.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants