Open rmartin16 opened 1 year ago
Fallback to an uninstall and install workflow or at least provide better information to the user about what's wrong.
I think the message is already clear enough, but falling back to a separate uninstall and install would still be useful. However, I think we should ask for confirmation first, as Android Studio does, with a warning that uninstalling the existing app will wipe out all of its data.
A similar situation could happen with the INSTALL_FAILED_VERSION_DOWNGRADE
error.
I think the message is already clear enough
Actually, as we've just found out from a user on Discord, the message is not displayed in non-verbose mode. All Briefcase displays in the console is:
Installing new app version...
Unable to install APK
[General discusssion moved to:]
[Moved to #1907]
I think the message is already clear enough
Yes, the subprocess output hints at the cause; but it also says that the problem was "ignored" - which... it clearly isn't (at least, not in a way that makes any sense to a Briefcase user).
I'd suggest that we should inspect the output for the INSTALL_FAILED_*
marker, and convert that into a more helpful error message if it is detected. If we're able to get a comprehensive list of those failure markers, that would be great; but if not, starting with the 2 we know about an expanding the list as they're reported would also be a significant improvement.
Describe the bug
The current APK install process can error if an existing version of the app cannot be replaced. For me, this happened because the existing app on the device was installed from a different computer.
Steps to reproduce
Expected behavior
Fallback to an uninstall and install workflow or at least provide better information to the user about what's wrong.
A simple remedy is
~/.cache/briefcase/tools/android_sdk/platform-tools/adb uninstall "com.example.helloworld"
Screenshots
No response
Environment
0.3.16.dev9+gb6057a0d
Logs
briefcase.2023_07_14-17_02_12.run.log
Additional context
No response