Skip to content

build: publish to Google Play as an app bundle; separate apk and aab lanes - #1706

Open
HashEngineering wants to merge 7 commits into
feat/kotlin-sdk-phase-1from
chore/play-app-bundle
Open

HashEngineering wants to merge 7 commits into
feat/kotlin-sdk-phase-1from
chore/play-app-bundle

Conversation

@HashEngineering

@HashEngineering HashEngineering commented Nov 13, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Google Play rejected the 12.0.2 prod APK (347,174,595 bytes): it carries the native libraries for both ABIs, stored uncompressed (x86_64 138 MB, arm64 122 MB). This PR switches Play publishing to an app bundle, so each device downloads only its own ABI.

Lane Now
publish build_aab, then upload
build ("Build apk") APK only, unchanged on the local and CI paths
build_aab ("Build aab", new) Bundle only: bundleProdRelease locally, bundle<Flavor><Type> on CI, with the same injected signing as build
upload Sends wallet/build/outputs/bundle/prodRelease/wallet-prod-release.aab with mapping.txt via supply(aab:, skip_upload_apk: true). skip_upload_apk stops supply picking up an APK built in the same run ("Cannot provide both apk(s) and aab").

CI Firebase distribution (build_distribute, qa) still builds and sends APKs. wallet/README.md documents build_aab and the .aab upload.

The same lanes are already on the 12.0.2 release branch (qa/integration-12.0.2). That branch additionally drops the SNAPSHOT check, which this PR keeps.

Requirement

Uploading a bundle requires Play App Signing on the app. Enroll by uploading the existing app signing key, so installed apps keep the same signer and update in place.

Test plan

  • ruby -c fastlane/Fastfile
  • pre-review clean
  • fastlane build_aab produces a signed wallet-prod-release.aab with stripped native libraries
  • fastlane upload sends it to the internal track
  • fastlane build still produces only the APK

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Documentation
    • Added instructions for building a Google Play app bundle and locating the resulting file.
    • Updated upload guidance to use an existing app bundle instead of an APK.

HashEngineering and others added 5 commits November 13, 2026 13:35
Play rejected the 12.0.2 prod apk (347,174,595 bytes) as too large: it
carries the native libraries for both ABIs, stored uncompressed. The
publish lane now also builds bundleProdRelease, signed with the same
injected key, and 'upload' sends wallet-prod-release.aab with the
mapping. From a bundle, each device downloads only its own ABI.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
(cherry picked from commit 73a98d7)
publish now asks build for the bundle, so the CI branch of build adds
bundle<Flavor><Type> when called from publish, and upload finds the .aab
there as it does locally. CI Firebase distribution (build_distribute)
still builds only the apk.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The build lane also produces the apk, and the gradle action leaves its
path in the lane context, so supply received both the apk and the aab
and refused ('Cannot provide both apk(s) and aab'). skip_upload_apk
keeps the upload to the bundle.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
build ('Build apk') builds the apk only again. The new build_aab lane
('Build aab') builds the app bundle only, on the local and CI paths.
publish now runs build_aab then upload, so it no longer builds an apk
it does not send.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

Important

Review skipped

Review was skipped due to path filters

⛔ Files ignored due to path filters: 1

  • fastlane/Fastfile is excluded by !fastlane/**

CodeRabbit blocks several paths by default. You can override this behavior by explicitly including those paths in the path filters. For example, including **/dist/** will override the default block on the dist directory, by removing the pattern from both the lists.

Run configuration

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review

No actionable comments were generated in the recent review.

Walkthrough

The README now documents how to build a Google Play app bundle, where the build output is located, and how to upload an existing AAB to the internal test track.

Changes: Google Play App Bundle Instructions

Layer / File(s) Summary
Build and upload instructions
wallet/README.md
Adds the fastlane build_aab command and output path. Updates the internal-test-track upload instructions to use an existing AAB and clarifies that the publish step builds an app bundle before uploading.

Estimated code review effort: 1 (Trivial) | ~3 minutes

Change: Other

Merge Risk: Minimal · up to 4a7d7

Merge Risk: ⚪ Minimal · up to 4a7d7

This PR only updates the README to describe building and uploading an Android App Bundle. The documented lanes exist in the committed Fastfile and match the instructions, so merge risk is minimal.

Pre-merge checks: Passed 4

Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title states the main change: publishing to Google Play now uses an Android App Bundle, and the APK and AAB lanes are separated. The raw summary covers only wallet/README.md, which documents the n…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title states the main change: publishing to Google Play now uses an Android App Bundle, and the APK and AAB lanes are separated. The raw summary covers only wallet/README.md, which documents the new build_aab lane and the AAB upload. The Fastfile change that implements the lanes is excluded from review, so the summary cannot confirm the lane separation itself. The title still matches the stated objectives, so the check passes.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 78f0ae2 and 49004ae.

Files ignored due to path filters: 1

  • fastlane/Fastfile is excluded by !fastlane/**
Files selected for processing: 1

  • wallet/README.md

Included review availability: This review used your included allowance. Your plan provides up to 2 included reviews per hour; 1 remain after this review.

@thepastaclaw

thepastaclaw commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

✅ Final review complete — no blockers (commit 4a7d760) · triage: low

@thepastaclaw thepastaclaw 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.

Final validation — Phase 1 + Phase 2

The AAB publishing change is not ready: the upload lane checks for an artifact name that does not match the wallet module's configured archive name, and the CI task construction lowercases the _testNet3 suffix so that supported variant cannot be built. The APK build and check jobs pass, but they do not exercise the new AAB path; the PastaClaw review check remains in progress.

🔴 2 blocking | 🟡 1 suggestion(s)

1 finding(s) not shown inline (the lines are not part of this PR's diff)

🔴 Blocking: Preserve the _testNet3 flavor capitalization in CI
fastlane/Fastfile:359-360

The CI branch calls String#capitalize on the requested flavor. For _testNet3, Ruby returns _testnet3, so build_aab flavor:_testNet3 type:release invokes bundle_testnet3Release instead of the declared bundle_testNet3Release task and fails before producing a bundle. The existing gradle_flavor and gradle_type helpers already preserve the Gradle variant spelling and should be used here.

		flavor = gradle_flavor(options[:flavor].to_s)
		type = gradle_type(options[:type].to_s)

source: muse-spark-1.3-contributor (phase1-reviewer: general); gpt-6.1-sol (phase2-reviewer: general)

Review provenance

Source: reviewer 1: muse-spark-1.3-contributor (agent: phase1-reviewer, role: general); reviewer 2: gpt-6.1-sol (agent: phase2-reviewer, role: general); reviewer 3: gpt-6.1-sol (agent: phase2-reviewer, role: general); final verifier: gpt-6.1-sol (agent: sol-verifier, role: final-verifier)

  • Triage: normal by gpt-6.1-sol (effort low) — This changes Fastlane build and Google Play upload behavior across multiple lanes, making it a nontrivial release-tooling change that warrants ordinary review despite not touching a critical code surface.
  • Phase 1 reviewers: muse-spark-1.3-contributor — general (completed, effort xhigh); agent phase1-reviewer
  • Phase 1 model: muse-spark-1.3-contributor — not quota-gated; passed over gemini-3.8-flash-high (antigravity quota lookup failed), glm-5.3-flash (not used above high effort; tier asks max)
  • Second Phase-2 pass: on this first full review every Phase-2 reviewer also ran a second, independent time, and the verifier weighed both sets
  • Fresh verifier: gpt-6.1-sol — final-verifier; agent sol-verifier
  • Phase 2 reviewers: gpt-6.1-sol — general (completed, effort high); agent phase2-reviewer, gpt-6.1-sol — general (completed, effort high); agent phase2-reviewer
🤖 Prompt for all review comments with AI agents
These findings are from an automated code review (PastaClaw). How to work through them:
- Verify each finding against the code; fix only what is real, as narrowly as the finding.
- If a finding is wrong, decline it on its thread in one or two sentences; the bot answers once and stops.
- To defer one, link a tracking issue on its thread (or reply asking the bot to file one).
- Suggestions don't block the merge, but most are worth fixing in this PR; judge each on its merits.
- Keep the PR's scope; don't grow it to satisfy hardening suggestions.
- Carried items were raised in an earlier round: read the thread first, and don't re-fix what you already fixed, declined or deferred there. Disputed and deferred items are already handled and are not listed.

In `fastlane/Fastfile`:
- [BLOCKING] fastlane/Fastfile:121: Use the configured dash-wallet bundle filename
  `wallet/build.gradle` sets `archivesBaseName = 'dash-wallet'`, so `bundleProdRelease` produces `dash-wallet-prod-release.aab`, not `wallet-prod-release.aab`. As written, `publish` can complete the bundle build but `upload` will always fail with `Missing aab`; the README documents the same incorrect path. Update the upload path and documentation to use the generated archive name.
- [BLOCKING] fastlane/Fastfile:359-360: Preserve the `_testNet3` flavor capitalization in CI
  The CI branch calls `String#capitalize` on the requested flavor. For `_testNet3`, Ruby returns `_testnet3`, so `build_aab flavor:_testNet3 type:release` invokes `bundle_testnet3Release` instead of the declared `bundle_testNet3Release` task and fails before producing a bundle. The existing `gradle_flavor` and `gradle_type` helpers already preserve the Gradle variant spelling and should be used here.
- [SUGGESTION] fastlane/Fastfile:395-398: Exercise the new AAB lane in CI
  The repository workflows invoke `build` and `build_distribute`, but none invokes `build_aab`, `publish`, or the bundle upload path. Consequently, the successful build and check jobs do not validate the new Gradle bundle task, artifact path, signing configuration, or `supply(aab:)` integration. Add a CI-safe validation for the bundle lane, or another automated check that verifies the generated AAB and mapping paths without publishing to Google Play.

Comment thread fastlane/Fastfile Resolved
Comment thread fastlane/Fastfile Resolved
capitalize lowercased the rest of the flavor, so _testNet3 became
_testnet3 in the task name. Use the existing gradle_flavor and
gradle_type helpers, which only raise the first letter.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@HashEngineering

Copy link
Copy Markdown
Collaborator Author

Fixed in e5fc083: the CI branch of build now uses the existing gradle_flavor / gradle_type helpers instead of String#capitalize, so _testNet3 keeps its spelling (bundle_testNet3Release, assemble_testNet3Release). This addresses "Preserve the _testNet3 flavor capitalization in CI" (fastlane/Fastfile:359-360).

@thepastaclaw thepastaclaw 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.

Re-review — Final validation — Phase 1 + Phase 2

The AAB publish path is wired to build and upload the bundle, and the supplied build/check jobs succeeded while the review check remains in progress. One blocking issue remains: the publish lane aborts before building because its SNAPSHOT scan treats a pre-existing wallet/build.gradle comment as a dependency hit.

🔴 1 blocking | 🟡 1 suggestion(s)

Still open from earlier rounds (1)

  • 🟡 Suggestion: Exercise the new AAB lane in CI — fastlane/Fastfile:395-398 (thread)
Review provenance

Source: reviewer 1: glm-5.3-flash (agent: phase1-reviewer, role: general); reviewer 2: gpt-6.1-sol (agent: phase2-reviewer, role: general); final verifier: gpt-6.1-sol (agent: sol-verifier, role: final-verifier)

  • Triage: low by gpt-6.1-sol (effort low) — This is a small, self-contained Fastlane build and upload configuration change with straightforward behavior and no critical application logic or key-handling implementation changes.
  • Phase 1 reviewers: glm-5.3-flash — general (completed, effort high); agent phase1-reviewer
  • Phase 1 model: glm-5.3-flash — zai quota: 5h 99% left, weekly 52% left; passed over gemini-3.8-flash-high (antigravity quota lookup failed)
  • Fresh verifier: gpt-6.1-sol — final-verifier; agent sol-verifier
  • Phase 2 reviewers: gpt-6.1-sol — general (completed, effort medium); agent phase2-reviewer
🤖 Prompt for all review comments with AI agents
These findings are from an automated code review (PastaClaw). How to work through them:
- Verify each finding against the code; fix only what is real, as narrowly as the finding.
- If a finding is wrong, decline it on its thread in one or two sentences; the bot answers once and stops.
- To defer one, link a tracking issue on its thread (or reply asking the bot to file one).
- Suggestions don't block the merge, but most are worth fixing in this PR; judge each on its merits.
- Keep the PR's scope; don't grow it to satisfy hardening suggestions.
- Carried items were raised in an earlier round: read the thread first, and don't re-fix what you already fixed, declined or deferred there. Disputed and deferred items are already handled and are not listed.

In `fastlane/Fastfile`:
- [BLOCKING] fastlane/Fastfile:102-109: SNAPSHOT gate fires on a code comment, so the new publish → build_aab flow cannot run on this branch
  The publish lane scans every matching Gradle, Gradle Kotlin, and TOML line for the literal `SNAPSHOT` without filtering comments. `wallet/build.gradle:87` contains `// claude/b1-txdetail-jni; NEVER repoint at 0.1.0-SNAPSHOT without also`, so `snapshot_hits` is non-empty and `UI.user_error!` runs before `build_aab` or `upload`. Although the comment predates this PR, the new publish flow depends on this gate and therefore cannot perform the release operation introduced here. Filter comment-only lines or reword the comment so the gate detects actual dependency declarations.
- [SUGGESTION] fastlane/Fastfile:395-398: Exercise the new AAB lane in CI
  (carried; thread: https://github.com/dashpay/dash-wallet/pull/1706#discussion_r4569675401)
Out-of-scope follow-up suggestions (1)

These are valid observations, but they are outside this PR's scope and should be handled in separate issues or author/maintainer-requested PRs rather than blocking this review.

  • Fix the same capitalize bug in the test lane — The test lane still uses String#capitalize, so fastlane test flavor:_testNet3 constructs test_testnet3... instead of preserving the _testNet3 flavor spelling. This is a pre-existing adjacent bug and is not used by the current CI calls, so it should be handled separately.
    • Follow-up: Open a follow-up PR replacing the test lane's capitalize calls with the existing gradle_flavor and gradle_type helpers.

Comment thread fastlane/Fastfile Resolved
A comment in wallet/build.gradle names a SNAPSHOT version, so the check
stopped publish before it built the bundle. Only a declaration is a hit.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@thepastaclaw thepastaclaw 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.

Re-review — Final validation — Phase 1 + Phase 2

The publish flow now filters comment-only SNAPSHOT references, builds an AAB, and uploads only that bundle, while the existing APK and Firebase distribution paths remain unchanged. The current build and check CI jobs succeed, but no automated workflow exercises the new bundle task or validates its AAB and mapping artifact paths.

🟡 1 suggestion(s)

Approved: nothing here blocks the merge. The non-blocking findings are optional: fix them forward, in this PR or a follow-up, without waiting for another review round.

Still open from earlier rounds (1)

  • 🟡 Suggestion: Exercise the new AAB lane in CI — fastlane/Fastfile:398-400 (thread)
Review provenance

Source: reviewer 1: glm-5.3-flash (agent: phase1-reviewer, role: general); reviewer 2: gpt-6.1-sol (agent: phase2-reviewer, role: general); reviewer 3: gpt-6.1-sol (agent: phase2-reviewer, role: general); final verifier: gpt-6.1-sol (agent: sol-verifier, role: final-verifier)

  • Triage: low by gpt-6.1-sol (effort low) — This is a small, well-contained Fastlane and documentation change that alters build and Google Play upload behavior without changing application runtime logic or a critical security surface.
  • Phase 1 reviewers: glm-5.3-flash — general (completed, effort high); agent phase1-reviewer
  • Phase 1 model: glm-5.3-flash — zai quota: 5h 100% left, weekly 52% left; passed over gemini-3.8-flash-high (antigravity quota lookup failed)
  • Fresh final gate: an independent Phase-2 review ran after iterative findings were reconciled
  • Fresh verifier: gpt-6.1-sol — final-verifier; agent sol-verifier
  • Phase 2 reviewers: gpt-6.1-sol — general (completed, effort medium); agent phase2-reviewer, gpt-6.1-sol — general (completed, effort medium); agent phase2-reviewer
🤖 Prompt for all review comments with AI agents
These findings are from an automated code review (PastaClaw). How to work through them:
- Verify each finding against the code; fix only what is real, as narrowly as the finding.
- If a finding is wrong, decline it on its thread in one or two sentences; the bot answers once and stops.
- To defer one, link a tracking issue on its thread (or reply asking the bot to file one).
- Suggestions don't block the merge, but most are worth fixing in this PR; judge each on its merits.
- Keep the PR's scope; don't grow it to satisfy hardening suggestions.
- Carried items were raised in an earlier round: read the thread first, and don't re-fix what you already fixed, declined or deferred there. Disputed and deferred items are already handled and are not listed.

In `fastlane/Fastfile`:
- [SUGGESTION] fastlane/Fastfile:398-400: Exercise the new AAB lane in CI
  (carried; thread: https://github.com/dashpay/dash-wallet/pull/1706#discussion_r4569675401)
Out-of-scope follow-up suggestions (1)

These are valid observations, but they are outside this PR's scope and should be handled in separate issues or author/maintainer-requested PRs rather than blocking this review.

  • Preserve _testNet3 capitalization in the test lane — The pre-existing test lane still uses Ruby String#capitalize, so an explicit fastlane test flavor:_testNet3 would construct the wrong Gradle task. This is adjacent to the corrected CI build path but is not introduced by this PR and current CI invokes the test lane with an empty flavor.
    • Follow-up: Open a follow-up PR replacing the test lane's flavor and type capitalization with the existing gradle_flavor and gradle_type helpers.

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