Skip to content

build: reenable integration tests#125

Merged
sitaktif merged 2 commits intoapple:mainfrom
sitaktif:reenable-integration-tests
Nov 21, 2025
Merged

build: reenable integration tests#125
sitaktif merged 2 commits intoapple:mainfrom
sitaktif:reenable-integration-tests

Conversation

@sitaktif
Copy link
Copy Markdown
Collaborator

The integration tests were deadlocking on trying to use the same output base as the root bazel invocation because of a value set in the home bazelrc by the Github Actions setup-bazel extension. Clearing the output base value in the integration test invocations works around the issue.

Related-to: bazel-contrib/setup-bazel#108.

@sitaktif sitaktif force-pushed the reenable-integration-tests branch from c7b2abe to 9472c19 Compare November 20, 2025 10:00
@KushalP
Copy link
Copy Markdown
Contributor

KushalP commented Nov 20, 2025

Looks like there build errors:

ERROR: Skipping '//...': error loading package under directory '': error loading package 'install/platforms/host': Unable to find package for @@[unknown repo 'host_platform' requested from @@]//:constraints.bzl: The repository '@@[unknown repo 'host_platform' requested from @@]' could not be resolved: No repository visible as '@host_platform' from main repository. Was the repository introduced in WORKSPACE? The WORKSPACE file is disabled by default in Bazel 8 (late 2024) and will be removed in Bazel 9 (late 2025), please migrate to Bzlmod. See https://bazel.build/external/migration.
ERROR: error loading package under directory '': error loading package 'install/platforms/host': Unable to find package for @@[unknown repo 'host_platform' requested from @@]//:constraints.bzl: The repository '@@[unknown repo 'host_platform' requested from @@]' could not be resolved: No repository visible as '@host_platform' from main repository. Was the repository introduced in WORKSPACE? The WORKSPACE file is disabled by default in Bazel 8 (late 2024) and will be removed in Bazel 9 (late 2025), please migrate to Bzlmod. See https://bazel.build/external/migration.

@sitaktif
Copy link
Copy Markdown
Collaborator Author

I must have missed something, because --output_base= definitely doesn't do what I thought: it uses the current working directory for the output base, which causes all sorts of mayhem.

@sitaktif sitaktif force-pushed the reenable-integration-tests branch from 9472c19 to c299ffa Compare November 20, 2025 11:44
@sitaktif
Copy link
Copy Markdown
Collaborator Author

No space left on device

sigh

@sitaktif
Copy link
Copy Markdown
Collaborator Author

According to https://docs.github.com/en/actions/reference/runners/github-hosted-runners#standard-github-hosted-runners-for-public-repositories, the runner should have 14GB of disk, which is probably a bit tight indeed.

I suggest we use the same output base of all the integration tests (which should be fine since they are exclusive).

@sitaktif sitaktif marked this pull request as ready for review November 20, 2025 12:13
Comment thread tests/integration_tests/BUILD.bazel Outdated
@sitaktif sitaktif force-pushed the reenable-integration-tests branch 2 times, most recently from d764d78 to cb64d60 Compare November 20, 2025 18:29
Also set the integration test workspaces output base to a single output
base to avoid high disk usage on Github Actions.
The integration tests were deadlocking on trying to use the same output
base as the root bazel invocation because of a value set in the home
bazelrc by the Github Actions setup-bazel extension. Now that a
specific, distinct output base is set in a preceding step, integration
tests can be re-enabled.
@sitaktif sitaktif force-pushed the reenable-integration-tests branch from cb64d60 to cca232a Compare November 20, 2025 18:35
@sitaktif
Copy link
Copy Markdown
Collaborator Author

sitaktif commented Nov 20, 2025

The check-pkl-github-actions check is failing due to a 503 on github:

–– Pkl Error ––
Received unexpected status code `503` when making request `GET [https://github.com/apple/pkl-project-commons/releases/download/pkl.impl.ghactions@0.7.1/pkl.impl.ghactions@0.7.1`.](https://github.com/apple/pkl-project-commons/releases/download/pkl.impl.ghactions@0.7.1/pkl.impl.ghactions@0.7.1%60.)

EDIT: transient failure 👍

Copy link
Copy Markdown
Contributor

@KushalP KushalP left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you.

Can you create issues for these hacks we've had to apply to the respective bazel-contrib/setup-bazel and rules_bazel_integration_test projects please?

@sitaktif sitaktif merged commit 40d801b into apple:main Nov 21, 2025
7 of 8 checks passed
@sitaktif
Copy link
Copy Markdown
Collaborator Author

Thanks @KushalP.

Regarding the issues, I created bazel-contrib/setup-bazel#108 on the setup-bazel side of things already.

I don't think rules_bazel_integration_test is doing anything wrong fundamentally; it does read the home bazelrc, but I think it's a desirable behavior to have since it allows picking up cache options of example.

@sitaktif sitaktif deleted the reenable-integration-tests branch November 21, 2025 15:56
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.

2 participants