[No QA] Fix Android build artifact paths and remove flawed retry#83244
[No QA] Fix Android build artifact paths and remove flawed retry#83244
Conversation
|
@stitesExpensify Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment has been minimized.
This comment has been minimized.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as resolved.
This comment was marked as resolved.
The Android build was failing because artifact collection used hardcoded paths that don't match the HybridApp project structure under Mobile-Expensify/Android. This switches to flexible find-based paths that work regardless of the exact Gradle output directory layout. Also removes the broken retry mechanism (clear Gradle cache + re-run Rock build) which was causing more problems than it solved -- the Gradle cache clearing corrupted state rather than fixing it. Additional improvements: - Skip bundletool/APK generation steps on Rock cache hits (no AAB) - Upload proguard mapping as a separate artifact for Sentry - Fix iOS dSYM collection to zip from xcarchive instead of export dir - Add if-no-files-found: warn to prevent silent artifact upload failures Co-authored-by: Cursor <cursoragent@cursor.com>
bd75fb8 to
0f171b7
Compare
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as outdated.
This comment was marked as outdated.
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
| if: steps.collectArtifacts.outputs.HAS_AAB == 'true' | ||
| run: | | ||
| AAB_PATH=$(find Mobile-Expensify/Android/app/build/outputs/bundle -name '*.aab' | head -1) | ||
| AAB_PATH=$(find Mobile-Expensify/Android -path '*/outputs/bundle/*/*.aab' | head -1) |
There was a problem hiding this comment.
NAB - for consistency should we read it from /tmp/android-artifacts/? Doesn't change much though.
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppAndroid: mWeb ChromeiOS: HybridAppiOS: mWeb SafariMacOS: Chrome / Safari |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
…acts [No QA] Fix Android build artifact paths and remove flawed retry (cherry picked from commit f002708) (cherry-picked to staging by roryabraham)
|
🚀 Cherry-picked to staging by https://github.com/roryabraham in version: 9.3.25-1 🚀
|
|
🚀 Deployed to production by https://github.com/puneetlath in version: 9.3.25-13 🚀
|
|
🚀 Cherry-picked to staging by https://github.com/roryabraham in version: 9.3.26-0 🚀
|
|
🚀 Deployed to production by https://github.com/puneetlath in version: 9.3.26-8 🚀
|
Explanation of Change
The Android build was failing because the
Collect build artifactsstep used hardcoded paths (Mobile-Expensify/Android/app/build/outputs/bundle,Mobile-Expensify/Android/build/generated/sourcemaps/react) that don't match the actual Gradle output layout in the HybridApp project structure. This switches to flexiblefind-based discovery.Also removes the broken Android build retry mechanism (clear Gradle caches → re-run Rock build) which corrupted state rather than fixing transient failures.
Additional improvements:
archive/) instead of export dir (export/)if-no-files-found: warnto prevent silent artifact upload failuresFixed Issues
N/A — fixing broken CI workflows
Tests
Offline tests
N/A — CI-only changes, no app behavior affected.
QA Steps
No QA — CI workflow changes only.
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectioncanBeMissingparam foruseOnyxtoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Test build results
All three platforms passed forced native builds: https://github.com/Expensify/App/actions/runs/22329828863
Artifacts produced:
android-sourcemap-artifact(16 MB)android-proguard-mapping(7.5 MB)iosBuild-artifact(72 MB)ios-dsym-artifact(130 MB)ios-sourcemap-artifact(16 MB)web-sourcemaps-artifact,web-build-tar-gz-artifact,web-build-zip-artifact