Skip to content

per-OS analysis fixes for whole-repo gate (part of #14802) - #14804

Merged
TrapsterDK merged 2 commits into
mainfrom
per-os-analysis-gate
Nov 24, 2026
Merged

TrapsterDK merged 2 commits into
mainfrom
per-os-analysis-gate

Conversation

@TrapsterDK

@TrapsterDK TrapsterDK commented Nov 24, 2026 •

Copy link
Copy Markdown
Collaborator

Part of #14802: targets that failed analysis on one OS now analyse or are skipped as incompatible.

  • //bcr_test_module:android_device_cc (linux_arm64): the rule takes the C++ toolchain as optional and depends on @rules_dx//android:llvm_readelf in the exec config. On a host with no NDK that alias is no_ndk_host (incompatible, android_unsupported), so the target is skipped instead of failing toolchain resolution. The BCR presubmit task passes --skip_incompatible_explicit_targets because it lists the target on ubuntu2204_arm64.

  • //deploy/private/image_demo:image_java (macos_arm64): distroless indexes publish arm64 as linux/arm64/v8, and rules_oci matches exactly, so the five distroless pulls now ask for linux/arm64/v8 (dotnet stays linux/arm64, checked against its index). oci_image_from_binary now uses the single-platform base for each image platform. Before, it used the hub alias, which follows the build host, so an amd64 image built on an arm64 host got the arm64 base.

  • //ocaml/private/tools:opam_binary (windows_x86_64): the select now covers the cells in ocaml/lang.json, and the alias carries OCAML_COMPATIBLE_WITH from the same source.

  • //d/tests/fixtures/d_app/diagnostics:ldc (windows_arm64): the select covers every pinned LDC cell (D_CELLS, which includes windows_arm64) and carries D_COMPATIBLE_WITH.

  • //deploy/private:conan_demo_config (windows_arm64): there is no pinned conan for that host, so //deploy/private/pins:conan resolved to the empty conan_none and the config rule failed. conan_none is now incompatible, so conan_deploy targets are skipped there. conan_files no longer defaults to the pinned files when you set your own conan.

  • Errors the earlier aborts were hiding on Windows: dx_dune_build and dx_dune_bootstrap now append OCAML_COMPATIBLE_WITH, as ocaml_dune_library already did (this fixes //ocaml/private/coverage:bisect_driver_exe). Hub exec aliases from pins_hub (for example @dx_ocaml_toolchains//:stdlib_cmi) and Terraform provider aliases (//terraform/tests:hub_null on windows_arm64) had selects with no default. Each now gets a target_compatible_with select over the same cells.

Local checks: I ran analysis with --host_platform set to linux_arm64, windows_arm64 and windows_x86_64. Each target was skipped as incompatible or analysed. Before this change, linux_arm64 reproduced the CI toolchain error. Image configs: image_multi arm64 = linux/arm64/v8, amd64 = linux/amd64, image_java = linux/amd64.

🤖 Generated with Claude Code

https://claude.ai/code/session_01Xut2hyBydsMejdwk6QdKus

- bcr_test_module: android_device_cc depends on the NDK's exec-host tool, so
  hosts without an NDK (linux_arm64) skip it as incompatible instead of failing
  toolchain resolution.
- oci: distroless indexes publish arm64 as linux/arm64/v8; pull that, and give
  each image the base for its own platform instead of the build host's.
- d: the diagnostics ldc alias covers every pinned LDC cell and carries
  D_COMPATIBLE_WITH.
- ocaml: opam_binary selects over the lang.json cells and carries
  OCAML_COMPATIBLE_WITH.
- deploy: conan_none is incompatible, so conan_deploy is skipped on hosts with
  no pinned conan.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Xut2hyBydsMejdwk6QdKus
@TrapsterDK

Copy link
Copy Markdown
Collaborator Author

/evidence platforms=["windows_x86_64","windows_arm64","macos_arm64","linux_arm64"] task=test scope=//d/tests/fixtures/d_app/diagnostics:all //bcr_test_module:all //ocaml/private/tools:all //deploy/private/pins:all //deploy/private/image_demo:all

…rt of #14802)

With opam_binary and ldc fixed, the coverage gate reached the next
analysis errors on Windows: dx_dune_build had no OCaml guard, the pins
hub exec aliases and the Terraform provider aliases had selects with no
default. Each now carries a target_compatible_with built from the same
cells as its select, so Bazel skips dependents on uncovered hosts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Xut2hyBydsMejdwk6QdKus
@github-actions

Copy link
Copy Markdown
Contributor

Evidence started on per-os-analysis-gate: https://github.com/devhusdk/rules_dx/actions/runs/45340965306

@TrapsterDK
TrapsterDK merged commit 4011a98 into main Nov 24, 2026
34 of 46 checks passed
@TrapsterDK
TrapsterDK deleted the per-os-analysis-gate branch November 24, 2026 07:49
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 this pull request may close these issues.

1 participant