Skip to content
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

External dependency of buildfarm fails with bzlmod #1611

Closed
werkt opened this issue Jan 10, 2024 · 0 comments · Fixed by #1726
Closed

External dependency of buildfarm fails with bzlmod #1611

werkt opened this issue Jan 10, 2024 · 0 comments · Fixed by #1726
Assignees
Milestone

Comments

@werkt
Copy link
Collaborator

werkt commented Jan 10, 2024

A simple example of a new bazel workspace which uses a bzlmod dependency on buildfarm fails to build:

MODULE.bazel:

bazel_dep(name = "build_buildfarm")
local_path_override(
    module_name = "build_buildfarm",
    path = "/path/to/buildfarm",
)

command:
bazel build @build_buildfarm//src/main/java/build/buildfarm:all

Results in a number of different errors, depending upon the action executed:

ERROR: no such package '@@[unknown repo 'maven' requested from @@build_buildfarm~override]//': The repository '@@[unknown repo 'maven' requested from @@build_buildfarm~override]' could not be resolved: No repository visible as '@maven' from repository '@@build_buildfarm~override'
ERROR: <output_base>/external/build_buildfarm~override/src/main/java/build/buildfarm/BUILD:27:12: no such package '@@[unknown repo 'maven' requested from @@build_buildfarm~override]//': The repository '@@[unknown repo 'maven' requested from @@build_buildfarm~override]' could not be resolved: No repository visible as '@maven' from repository '@@build_buildfarm~override' and referenced by '@@build_buildfarm~override//src/main/java/build/buildfarm:buildfarm-shard-worker'
Target @@build_buildfarm~override//src/main/java/build/buildfarm:configs up-to-date (nothing to build)
ERROR: Analysis of target '@@build_buildfarm~override//src/main/java/build/buildfarm:buildfarm-shard-worker' failed; build aborted: Analysis failed
ERROR: no such package '@@[unknown repo 'io_grpc_grpc_proto' requested from @@build_buildfarm~override]//': The repository '@@[unknown repo 'io_grpc_grpc_proto' requested from @@build_buildfarm~override]' could not be resolved: No repository visible as '@io_grpc_grpc_proto' from repository '@@build_buildfarm~override'
ERROR: <output_base>/external/build_buildfarm~override/src/main/java/build/buildfarm/server/BUILD:1:13: no such package '@@[unknown repo 'io_grpc_grpc_proto' requested from @@build_buildfarm~override]//': The repository '@@[unknown repo 'io_grpc_grpc_proto' requested from @@build_buildfarm~override]' could not be resolved: No repository visible as '@io_grpc_grpc_proto' from repository '@@build_buildfarm~override' and referenced by '@@build_buildfarm~override//src/main/java/build/buildfarm/server:server'
Target @@build_buildfarm~override//src/main/java/build/buildfarm:configs up-to-date (nothing to build)
ERROR: Analysis of target '@@build_buildfarm~override//src/main/java/build/buildfarm:buildfarm-server' failed; build aborted: Analysis failed
@jasonschroeder-sfdc jasonschroeder-sfdc self-assigned this Jan 10, 2024
@werkt werkt added this to the v2.10 milestone Mar 5, 2024
jasonschroeder-sfdc added a commit to jasonschroeder-sfdc/bazel-buildfarm that referenced this issue May 9, 2024
werkt pushed a commit that referenced this issue May 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants