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

//src/test/shell/bazel/android/... is incompatible with RBE #8235

Closed
jin opened this issue May 3, 2019 · 6 comments
Closed

//src/test/shell/bazel/android/... is incompatible with RBE #8235

jin opened this issue May 3, 2019 · 6 comments
Labels
P2 We'll consider working on this in future. (Assignee optional) team-Android Issues for Android team type: bug

Comments

@jin
Copy link
Member

jin commented May 3, 2019

Sample error:

Exception in thread "main" com.android.ide.common.internal.LoggedErrorException: Failed to run command:
	bazel-out/host/bin/external/androidsdk/aapt_binary package -f --no-crunch --no-version-vectors -I external/androidsdk/platforms/android-28/android.jar -M /tmp/resource_validator_tmp12788981107769083666/manifest-aapt-dummy/AndroidManifest.xml -m -J /tmp/resource_validator_tmp12788981107769083666/generated_resources --output-text-symbols /tmp/resource_validator_tmp12788981107769083666/generated_resources -F bazel-out/android-armeabi-v7a-fastbuild/bin/java/bazel/aar_files/library.ap_ --debug-mode --non-constant-id -0 apk
Error Code:
	127
Output:
	error parsing linebazel-out/host/bin/external/androidsdk/aapt_binary.runfiles/androidsdk/build-tools/28.0.3/aapt: error while loading shared libraries: libc++.so: cannot open shared object file: No such file or directory
	at com.google.devtools.build.android.AndroidResourceProcessor.runAapt(AndroidResourceProcessor.java:422)
	at com.google.devtools.build.android.AndroidResourceValidatorAction.main(AndroidResourceValidatorAction.java:148)
	at com.google.devtools.build.android.ResourceProcessorBusyBox$Tool$2.call(ResourceProcessorBusyBox.java:72)
	at com.google.devtools.build.android.ResourceProcessorBusyBox.processRequest(ResourceProcessorBusyBox.java:240)
	at com.google.devtools.build.android.ResourceProcessorBusyBox.main(ResourceProcessorBusyBox.java:203)

Key problem: error parsing linebazel-out/host/bin/external/androidsdk/aapt_binary.runfiles/androidsdk/build-tools/28.0.3/aapt: error while loading shared libraries: libc++.so: cannot open shared object file: No such file or directory

It looks the dynamically linked libc++.so dependency of aapt/aapt2 at sdk/build-tools/<version>/lib64/libc++.so cannot be found when executing Android actions remotely through a Bazel-in-Bazel sh_test. This suggests some kind of issue with the hermeticity of @androidsdk//:aapt_binary and @androidsdk//:aapt2_binary.

Regular Android builds do work with RBE, however.

cc @buchgr

trunk issue: #8033

@jin jin added team-Android Issues for Android team untriaged labels May 3, 2019
@buchgr
Copy link
Contributor

buchgr commented May 6, 2019

Related #4663

bazel-io pushed a commit that referenced this issue May 6, 2019
don't run them on remote execution until #8235 is fixed.
They will continue to run locally.

RELNOTES: None
PiperOrigin-RevId: 246863889
@buchgr
Copy link
Contributor

buchgr commented May 7, 2019

We have tagged the android shell tests as "no-remote" for now.

@ahumesky ahumesky added P2 We'll consider working on this in future. (Assignee optional) and removed untriaged labels May 14, 2019
tjgq added a commit to tjgq/bazel that referenced this issue Mar 15, 2023
tjgq added a commit to tjgq/bazel that referenced this issue Mar 15, 2023
tjgq added a commit to tjgq/bazel that referenced this issue Mar 15, 2023
The dynamic linking issue that required local execution has been fixed.

This should speed up Bazel CI runs, as we previously couldn't benefit from
previously cached test results.

One of the tests must remain non-remote because it currently exceeds the RBE
input limit (70k files). This is tracked in bazelbuild#17784.

Fixes bazelbuild#8235.
copybara-service bot pushed a commit that referenced this issue Mar 16, 2023
…les used by the Android integration tests.

This is necessary to reenable remote caching/execution for these tests (and make CI runs faster!). In the absence of this change, the tests will fail because the aapt/appt2/aidl/zipalign tools can't be dynamically linked in the remote environment. See issue #8235.

We need to wait until this change makes it into a Bazel release before reenabling the tests, as they inherit the SDK files from the Bazel that runs them.

Related to #8235.

PiperOrigin-RevId: 517180365
Change-Id: I2baa66af15af85349187e75e3acd4e3cb5d84a49
tjgq added a commit to tjgq/bazel that referenced this issue Mar 20, 2023
…f SDK files used by the Android integration tests.

This is necessary to reenable remote caching/execution for these tests (and make CI runs faster!). In the absence of this change, the tests will fail because the aapt/appt2/aidl/zipalign tools can't be dynamically linked in the remote environment. See issue bazelbuild#8235.

We need to wait until this change makes it into a Bazel release before reenabling the tests, as they inherit the SDK files from the Bazel that runs them.

Related to bazelbuild#8235.

PiperOrigin-RevId: 517180365
Change-Id: I2baa66af15af85349187e75e3acd4e3cb5d84a49
ShreeM01 pushed a commit that referenced this issue Mar 20, 2023
…f SDK files used by the Android integration tests. (#17826)

This is necessary to reenable remote caching/execution for these tests (and make CI runs faster!). In the absence of this change, the tests will fail because the aapt/appt2/aidl/zipalign tools can't be dynamically linked in the remote environment. See issue #8235.

We need to wait until this change makes it into a Bazel release before reenabling the tests, as they inherit the SDK files from the Bazel that runs them.

Related to #8235.

PiperOrigin-RevId: 517180365
Change-Id: I2baa66af15af85349187e75e3acd4e3cb5d84a49
@github-actions
Copy link

Thank you for contributing to the Bazel repository! This issue has been marked as stale since it has not had any activity in the last 2+ years. It will be closed in the next 14 days unless any other activity occurs or one of the following labels is added: "not stale", "awaiting-bazeler". Please reach out to the triage team (@bazelbuild/triage) if you think this issue is still relevant or you are interested in getting the issue resolved.

@github-actions github-actions bot added the stale Issues or PRs that are stale (no activity for 30 days) label Apr 13, 2023
@tjgq
Copy link
Contributor

tjgq commented Apr 13, 2023

This issue was fixed by #17826 but we need to wait until it makes it into a Bazel release before we can reenable the tests (except android_ndk_integration_test, which requires additional work to address #17784).

@github-actions github-actions bot removed the stale Issues or PRs that are stale (no activity for 30 days) label Apr 14, 2023
tjgq added a commit to tjgq/bazel that referenced this issue May 12, 2023
tjgq added a commit to tjgq/bazel that referenced this issue May 15, 2023
tjgq added a commit to tjgq/bazel that referenced this issue May 17, 2023
tjgq added a commit to tjgq/bazel that referenced this issue May 17, 2023
fweikert pushed a commit to fweikert/bazel that referenced this issue May 25, 2023
…les used by the Android integration tests.

This is necessary to reenable remote caching/execution for these tests (and make CI runs faster!). In the absence of this change, the tests will fail because the aapt/appt2/aidl/zipalign tools can't be dynamically linked in the remote environment. See issue bazelbuild#8235.

We need to wait until this change makes it into a Bazel release before reenabling the tests, as they inherit the SDK files from the Bazel that runs them.

Related to bazelbuild#8235.

PiperOrigin-RevId: 517180365
Change-Id: I2baa66af15af85349187e75e3acd4e3cb5d84a49
fweikert pushed a commit to fweikert/bazel that referenced this issue May 25, 2023
… tests.

Some still fail remotely and remain disabled; see bazelbuild#17784 and bazelbuild#18431.

Fixes bazelbuild#8235.

Closes bazelbuild#18387.

PiperOrigin-RevId: 533332908
Change-Id: I638420de72ca1efdb1b79fa1c1fec68d3a740eb5
@meteorcloudy
Copy link
Member

@tjgq Can we remove no-remote for those tests now? a9fb6d3

@tjgq
Copy link
Contributor

tjgq commented Feb 21, 2024

I don't know, but we could give it a try and see if we're still hitting the same error.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P2 We'll consider working on this in future. (Assignee optional) team-Android Issues for Android team type: bug
Projects
None yet
5 participants