Skip to content

Java: gate AGP-7.x Android integration tests off linux-arm64 - #22327

Merged
redsun82 merged 1 commit into
mainfrom
redsun82-gate-android-tests-arm64
Aug 13, 2026
Merged

Java: gate AGP-7.x Android integration tests off linux-arm64#22327
redsun82 merged 1 commit into
mainfrom
redsun82-gate-android-tests-arm64

Conversation

@redsun82

@redsun82 redsun82 commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

These integration tests build an Android app via the Android Gradle Plugin (AGP), which downloads Google's prebuilt aapt2 from Maven. The pinned AGP 7.0.0 and 7.3.1 ship no linux-aarch64 aapt2, so on linux-arm64 the build fails at AAPT2 daemon startup and database creation aborts. macOS arm64 is unaffected, as it uses its own aapt2.

This is a third-party tool gap rather than anything specific to the extractor, and bumping AGP is out of scope here since each test's expected output is coupled to the exact AGP and Gradle versions.

Following the existing java-version-too-old precedent, this gates the affected tests with @(runs_on.x86_64 or runs_on.macos) so they deselect on linux-arm64 while continuing to run on x86_64 and macOS arm64. android-8-sample (AGP 8.0.0) is intentionally left untouched.

No .expected changes are required, since arch gating only removes the tests from collection on linux-arm64.

@redsun82
redsun82 requested a review from a team as a code owner August 12, 2026 13:58
Copilot AI balanced review requested due to automatic review settings August 12, 2026 13:58
@github-actions github-actions Bot added the Java label Aug 12, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Gates AGP 7.x Android integration tests to x86_64 because their bundled aapt2 cannot run on Linux ARM64.

Changes:

  • Adds the established runs_on.x86_64 test decorator.
  • Leaves the ARM64-compatible AGP 8.0 test unchanged.
Show a summary per file
File Description
android-sample/test.py Gates the AGP 7.3.1 test.
android-sample-old-style/test.py Gates the old-style AGP 7.0 test.
android-sample-old-style-no-wrapper/test.py Gates the wrapperless old-style test.
android-sample-old-style-kotlin-build-script/test.py Gates the Kotlin-script old-style test.
android-sample-old-style-kotlin-build-script-no-wrapper/test.py Gates its wrapperless variant.
android-sample-no-wrapper/test.py Gates the wrapperless AGP 7.3.1 test.
android-sample-kotlin-build-script/test.py Gates the Kotlin-script test.
android-sample-kotlin-build-script-no-wrapper/test.py Gates its wrapperless variant.

Review details

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

  • Files reviewed: 8/8 changed files
  • Comments generated: 0
  • Review effort level: Balanced

These integration tests build an Android app via the Android Gradle
Plugin (AGP), which downloads Google's prebuilt `aapt2` from Maven. The
pinned AGP `7.0.0` and `7.3.1` ship no linux-aarch64 `aapt2`, so on
linux-arm64 the build fails at AAPT2 daemon startup and database
creation aborts. macOS arm64 is unaffected, as it uses its own `aapt2`.

This is a third-party tool gap rather than anything specific to the
extractor, and bumping AGP is out of scope since each test's expected
output is coupled to the exact AGP and Gradle versions.

Following the `java-version-too-old` precedent, gate these tests with
`@(runs_on.x86_64 or runs_on.macos)` so they deselect on linux-arm64
while continuing to run on x86_64 and macOS arm64.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@redsun82
redsun82 force-pushed the redsun82-gate-android-tests-arm64 branch from 8685c94 to d12e9dc Compare August 12, 2026 14:32

@jketema jketema left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Makes sense. I wonder if we should update these tests to something newer at some point?

@redsun82
redsun82 merged commit 38726fd into main Aug 13, 2026
16 checks passed
@redsun82
redsun82 deleted the redsun82-gate-android-tests-arm64 branch August 13, 2026 07:03
@ptranqui

Copy link
Copy Markdown

Makes sense. I wonder if we should update these tests to something newer at some point?

the 7.0.0 tests, not really: they test extraction works on an older way of building android that was used by those older versions. Though it might make sense to just drop those tests if that version and that way of building Android has gotten way past EoL.

For the 7.3.1, yes, as far as I can tell we could update the version (and the expected files), but I was lazy 😅

pull Bot pushed a commit to TheRakeshPurohit/codeql that referenced this pull request Aug 13, 2026
Completes the arm64 gating begun in github#22327 for the last two Android-driving
java integration tests, so all 10 (the 8 already merged + these) are
deselected on linux-arm64 while mac-arm64 and x86_64 stay green.

android-8-sample: AGP 8.0.0 ships no linux-aarch64 aapt2 (Google's Maven
publishes only linux/osx/windows classifiers), so the build fails on
linux-arm64 with an x86-64 aapt2 exec'd on aarch64.

android-gradle-incompatibility: gated to avoid conflating that same
x86_64-only aapt2 build failure on linux-arm64 with the AGP/Gradle-version
incompatibility failure this test asserts (otherwise the test would pass
for the wrong reason).

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants