Skip to content

chore: update Bazel versions 7.0.0rc4 #120

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

Merged
merged 14 commits into from
Dec 1, 2023
Merged

chore: update Bazel versions 7.0.0rc4 #120

merged 14 commits into from
Dec 1, 2023

Conversation

aherrmann
Copy link
Owner

@aherrmann aherrmann commented Nov 26, 2023

  • Update Bazel versions to 7rc4 and 6.4.0

@aherrmann
Copy link
Owner Author

aherrmann commented Nov 26, 2023

The integration tests fail with errors of the form

ERROR: /tmp/bazel-working-directory/_main/bazel-out/k8-fastbuild/bin/zig/tests/integration_tests/zig_version_test_0.11.0.runfiles/_main/zig/tests/integration_tests/workspace/BUILD.bazel:13:11: Building main.zig as Zig binary bazel-out/k8-fastbuild/bin/binary failed: (Exit 1): zig failed: error executing ZigBuildExe command (from target //:binary) external/rules_zig~override~zig~zig_x86_64-linux/zig build-exe '-femit-bin=bazel-out/k8-fastbuild/bin/binary' main.zig --zig-lib-dir external/rules_zig~override~zig~zig_x86_64-linux/lib --cache-dir ... (remaining 8 arguments skipped)

Use --sandbox_debug to see verbose messages from the sandbox and retain the sandbox build root for debugging
external/rules_zig~override~zig~zig_x86_64-linux/lib/std/std.zig:106:22: error: unable to load 'main.zig': NotDir

The integration tests succeed with Bazel 7.0.0rc3 and fail with Bazel 7.0.0rc4. The first bad commit is first bad commit is bazelbuild/bazel@8b211fb according to bazelisk bisect. However, neither form of --[no]experimental_throttle_action_cache_check causes the tests to pass with 7.0.0rc4. (--nocache_test_results omitted)

The first bad commit is first bad commit is https bazelbuild/bazel@fe85936.

bazelbuild/bazel@fe85936

Otherwise, integration tests fail with
```
ERROR: /tmp/bazel-working-directory/_main/bazel-out/k8-fastbuild/bin/zig/tests/integration_tests/zig_version_test_0.11.0.runfiles/_main/zig/tests/integration_tests/workspace/BUILD.bazel:13:11: Building main.zig as Zig binary bazel-out/k8-fastbuild/bin/binary failed: (Exit 1): zig failed: error executing ZigBuildExe command (from target //:binary) external/rules_zig~override~zig~zig_x86_64-linux/zig build-exe '-femit-bin=bazel-out/k8-fastbuild/bin/binary' main.zig --zig-lib-dir external/rules_zig~override~zig~zig_x86_64-linux/lib --cache-dir ... (remaining 8 arguments skipped)

Use --sandbox_debug to see verbose messages from the sandbox and retain the sandbox build root for debugging
external/rules_zig~override~zig~zig_x86_64-linux/lib/std/std.zig:106:22: error: unable to load 'main.zig': NotDir
```
Captures the builtin bzl files in a version independent way.
The lock file format changed between Bazel 6.3.0 and 7.0.0rc4. However,
we're testing both Bazel versions on CI. So, one will fail on the
other's lock file.
The documentation can vary between Bazel versions. E.g. Bazel 7 changed
the documentation of the implicit `repo_mapping` parameter to repository
rules.

Hence, we need to disable docs generation and in particular tests when
testing against other Bazel versions than the main development version.
@aherrmann aherrmann marked this pull request as ready for review December 1, 2023 08:36
@aherrmann aherrmann enabled auto-merge December 1, 2023 08:36
@aherrmann aherrmann merged commit 92ee8fc into main Dec 1, 2023
@aherrmann aherrmann deleted the bazel-versions branch December 1, 2023 09:15
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