Forcing fresh install of an app update instead of simply updating existing version

I’m just wondering if it’s possible to force an app to re-install over an existing version of the app instead of simply trying to update the app? Reason for this is if you make quite a lot of changes in your update and perhaps how some of the save data is stored then the new update will not function properly unless the user deletes the previous version and installs the new update fresh.

Any ideas?

On iOS, that’s how updates are handled. The entire app is deleted and re-made, but it leaves the sandbox intact. The only difference between deleting and re-installing vs. updating is that the sandbox is deleted or kept. (if someone knows differently, do tell)

So if you change the save data format, you could just have a flag on whether this is the first time the user has opened the newer version, and if it is, load the previous data in the previous format and save it again in the new format.

I don’t believe many people will be wanting to delete and re-install an app to update :wink:

  • C

Thanks for the reply, this is also the first time we experienced customers having issues with an update for one of our games. For this current game, if they simply update the game will hang and not work properly, but if they do a fresh install it runs perfectly. So I assume it has to do with the save game data, unless updates still leave something else on the device other then saved data files.

You have to program your app to handle breaking changes in your saved data format.   Set some version number in your saved data, if after loading it, the version number doesn’t exist (a version before you started tracking) or it’s less than your current one, you can delete the old saved data, or better yet, convert it if possible to the new format and save it back out)

On iOS, that’s how updates are handled. The entire app is deleted and re-made, but it leaves the sandbox intact. The only difference between deleting and re-installing vs. updating is that the sandbox is deleted or kept. (if someone knows differently, do tell)

So if you change the save data format, you could just have a flag on whether this is the first time the user has opened the newer version, and if it is, load the previous data in the previous format and save it again in the new format.

I don’t believe many people will be wanting to delete and re-install an app to update :wink:

  • C

Thanks for the reply, this is also the first time we experienced customers having issues with an update for one of our games. For this current game, if they simply update the game will hang and not work properly, but if they do a fresh install it runs perfectly. So I assume it has to do with the save game data, unless updates still leave something else on the device other then saved data files.

You have to program your app to handle breaking changes in your saved data format.   Set some version number in your saved data, if after loading it, the version number doesn’t exist (a version before you started tracking) or it’s less than your current one, you can delete the old saved data, or better yet, convert it if possible to the new format and save it back out)