[Bazel CI] ERROR: While resolving toolchains for target invalid registered toolchain '@local_jdk//:runtime_toolchain_definition': error loading package repo 'local_config_platform'

Open
#642 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
25/100
Issue type
Bug
Clarity
Needs clarification
Activity status
Stale

Research direction

Start with the linked Buildkite run and the target in configurations/cc_binary_selectable_copts/BUILD, especially app_with_feature1_native_binary. Compare the Windows and Ubuntu failures and trace the invalid local_jdk toolchain and local_config_platform repository error. Done means the affected CI builds complete without the toolchain-resolution failure.

Written by the indexing model from the issue text.

Description

CI: https://buildkite.com/bazel/bazel-bazel-examples/builds/4897#019ab860-fcd1-4a24-9b97-56f4f228991f

Platform: Windows, Ubuntu

Logs:

(00:20:12) ERROR: /workdir/configurations/cc_binary_selectable_copts/BUILD:9:10: While resolving toolchains for target //cc_binary_selectable_copts:app_with_feature1_native_binary (9d6e610): invalid registered toolchain '@local_jdk//:runtime_toolchain_definition': error loading package '@@rules_java++toolchains+local_jdk//': Unable to find package for @@[unknown repo 'local_config_platform' requested from @@rules_java++toolchains+local_jdk]//:constraints.bzl: The repository '@@[unknown repo 'local_config_platform' requested from @@rules_java++toolchains+local_jdk]' could not be resolved: No repository visible as '@local_config_platform' from repository '@@rules_java++toolchains+local_jdk'.
(00:20:12) ERROR: Analysis of target '//cc_binary_selectable_copts:app_with_feature1' failed; build aborted: Analysis failed
(00:20:12) INFO: Elapsed time: 1.387s, Critical Path: 0.05s
(00:20:12) INFO: 1 process: 1 internal.
(00:20:12) ERROR: Build did NOT complete successfully

CC Greenteam @Wyverald

Dominant language
Starlark
Stars
957
Forks
578
Avg merge
2d 10h
Merged PRs (30d)
2

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from bazelbuild/examples

All issues in bazelbuild/examples

Similar issues

More Build System issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.