nowinandroid icon indicating copy to clipboard operation
nowinandroid copied to clipboard

CI fails with INSTALL_FAILED_INSUFFICIENT_STORAGE error

Open dturner opened this issue 3 years ago • 5 comments

CI failed on API23 with the following error:

Failed to install APK(s): /Users/runner/work/nowinandroid/nowinandroid/feature/topic/build/outputs/apk/androidTest/prod/debug/topic-prod-debug-androidTest.apk INSTALL_FAILED_INSUFFICIENT_STORAGE

Context: https://github.com/android/nowinandroid/actions/runs/3302289727/jobs/5449234815

dturner avatar Oct 22 '22 08:10 dturner

Related upstream issue: https://issuetracker.google.com/issues/255600573

alexvanyo avatar Oct 25 '22 19:10 alexvanyo

so should we try to increase disk-size to 4GB by using https://github.com/ReactiveCircus/android-emulator-runner#configurations disk-size for the action we use in workflow?

looks like it's been recently increase though Screen Shot 2022-10-26 at 4 34 50 pm

YuraLaguta avatar Oct 26 '22 05:10 YuraLaguta

As per https://b.corp.google.com/issues/255600573, the default in Android Studio is now 6G. Let's change to this value.

dturner avatar Oct 26 '22 09:10 dturner

Still getting this issue after updating disk space to 6G: https://github.com/android/nowinandroid/actions/runs/3311589098/jobs/5522642374

dturner avatar Oct 28 '22 13:10 dturner

according to the most upvoted answer here: https://stackoverflow.com/questions/4709137/solution-to-install-failed-insufficient-storage-error-on-android
The problem with android itself, looks like we have few options:

  1. Try add 'force-avd-creation: true' for preventing using cached emulator which might have two apk files for our package
  2. Add cli step to remove apk files :

adb shell "pm uninstall <full.packge.name>" adb shell "rm -rf /data/app/<full.package.name>-*"

YuraLaguta avatar Oct 31 '22 00:10 YuraLaguta

@YuraLaguta Thanks for the suggestion, am trying force-avd-creation in https://github.com/android/nowinandroid/pull/375.

dturner avatar Nov 02 '22 18:11 dturner

@dturner Seems like we don't have this issue anymore, closing.

mmoczkowski avatar Nov 15 '22 15:11 mmoczkowski