0

I have an app that allows users to download an updated apk. Once downloaded, the new apk is installed. What I expected was:

  1. the installation dialog opens asking the user if they want to install, etc.
  2. the installation completes and asks the user if they want to open the app.

Instead, after the first step the dialog disappears/closes. If I relaunch the app manually I can see that the version has updated successfully and the app works as expected. The downloaded update is being directed to cordova.file.externalDataDirectory so there shouldn't be a problem with permissions. The only other thing I can think of is that the app has the application attribute android:launchMode="singleTask" which was included to prevent a user from launching another instance of the app (a necessary functionality).

Might the problem be the 'launchMode' attribute? If so, is there a work around?

[ADDITIONAL INFO] My symptoms are identical to this question. I haven't yet had success with the proposed solution.

[SOLVED] This answer is 'launchMode' is not a factor, the download directory is. The explanation is here.

Community
  • 1
  • 1
MikeB
  • 788
  • 1
  • 9
  • 27

0 Answers0