Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Apps restored via oandbackup are removed upon updating LOS #263

Open
acenomad opened this issue Sep 24, 2019 · 14 comments
Open

Apps restored via oandbackup are removed upon updating LOS #263

acenomad opened this issue Sep 24, 2019 · 14 comments

Comments

@acenomad
Copy link

Upon updating LineageOS, any apps that were installed via the restore function in oandbackup are removed from the home screen and settings app list. When trying to reinstall the apps in question, it is prompted as an apk update rather than a fresh install of the apps.

Device info: OnePlus 5, latest microG for LOS ROM, latest firmware, latest TWRP, Magisk 18.1

This issue has persisted every OS update.

@frh
Copy link

frh commented Oct 13, 2019

Any workaround for this? It's a little annoying having to restore the same apps again every time after updating LineageOS.

@acenomad
Copy link
Author

acenomad commented Oct 13, 2019

Any workaround for this? It's a little annoying having to restore the same apps again every time after updating LineageOS.

No workarounds I can find (yet). Unfortunately I've just been restoring them after every update.

I plan to test the difference between restoring apk+data via oandbackup vs. reinstalling the apk manually and then restoring only the data via oandbackup on my next weekly LOS update, I'll edit my post with whatever happens.

The issue seems very selective (only a few people seem to have this issue and only with a few apps).

EDIT: it doesn't matter how the app was installed. In both cases of installing the app via the apk file and via oandbackup's restore method the app ends up getting removed upon the next LOS update. Unsure of where to go from here.

@frh
Copy link

frh commented Oct 13, 2019

Unfortunately I've just been restoring them after every update.

Me too.

I'll edit my post with whatever happens.

Great, please do so.

only with a few apps

Yes, it's the same five or so apps every time.

@acenomad
Copy link
Author

Update: it doesn't matter how the app was installed. In both cases of installing the app via the apk file and via oandbackup's restore method the app ends up getting removed upon the next LOS update. Unsure of where to go from here.

@frh
Copy link

frh commented Oct 22, 2019

Is it even a problem with oandbackup then? If the apps are installed directly the results are the same. I don't know what the cause could be.
I'm wondering if it's happening to the same apps for us both. For me it's Plumble, Minesweeper, LibreOffice Viewer, IceCatMobile, Orbot, and Tor Browser.

@acenomad
Copy link
Author

acenomad commented Nov 28, 2019

Is it even a problem with oandbackup then?

I think so. And I think it might have to do with apps that were backed up and restored via another method (for me it would have been with TitaniumBackup) and then backed up and restored via oandbackup.

I'm wondering if it's happening to the same apps for us both.

For sure not. I have Plumble, LibreOffice viewer, Orbot and TOR browser installed and they stay persistent between updates for me. I ended up giving up on most of the apps I was backing up anyways but I still have this issue with Snapchat.

@ghost
Copy link

ghost commented Dec 25, 2019

I'm also noticing this issue, specifically only concerning the Pebble app. I have to do a full apk+data restore after every self-build of LOS.

@frh
Copy link

frh commented Dec 27, 2019

And I think it might have to do with apps that were backed up and restored via another method (for me it would have been with TitaniumBackup) and then backed up and restored via oandbackup.

I've never backed up and restored my apps with any other method, so I don't think it's that.

@hagaygo
Copy link

hagaygo commented Mar 1, 2020

Had this problem , took me a while but i found a permanent solution. (for my case at least)

After flashing new version of the rom the app seems not to be available ?
Instead of restoring it again from oandbackup files , just install from google play , the app data will be there and it would not get removed on next rom update.

@acenomad
Copy link
Author

acenomad commented Mar 5, 2020

Had this problem , took me a while but i found a permanent solution. (for my case at least)

After flashing new version of the rom the app seems not to be available ?
Instead of restoring it again from oandbackup files , just install from google play , the app data will be there and it would not get removed on next rom update.

As I have a (mostly) degoogled device, I install Play apps via Aurora store. While the end result is the same, I have a feeling that it's probably a technically different process.

In any case, installing from Aurora Store or directly from the .apk after a ROM update did not work in my case. Although I am glad to hear that other people who've had this issue are finding fixes. The search continues!

@danielmmmm
Copy link
Contributor

Great to see that I am not the only one who experienced apps getting deleted ...

Does anyone have a clue whether the LOS update process deleted the apps, or whether it was the evil doing of the Play store?
I had LOS 16 running on my Pro1 and applied several OTA updates without any problem. Just the last update a few days ago deleted half of my (oandbackup restored) apps. And again, only the apk folders in \data\app were removed, while the data in \data\data remained.

@mnalis
Copy link

mnalis commented Nov 22, 2020

@danielmmmm I don't know about root cause, but it happens to me too, and I never installed Google Play store nor other google services (F-Droid store only), so they're probably off the hook on this one... Workaround for me was to uninstall app, install older version via f-droid, and then use oandbackup to restore both apk and data, and then upgrade it via f-droid to same version that was in backup, then restore just data via oandbackup... Don't know if it was all needed, but then it worked again for me...

@acenomad
Copy link
Author

@mnalis @danielmmmm @frh @msoose

FYI for all of you: this app seems to be no longer maintained by @jensstein, last update was in Dec 2018.

There is a fork of this app that can be found in f-droid that has been regularly maintained this year: https://github.com/machiav3lli/oandbackupx

Since transitioning to the fork, I have not experienced this issue. YMMV of course but it's worth switching over anyways IMO

@danielmmmm
Copy link
Contributor

danielmmmm commented Jan 31, 2021

@acenomad Thanks. I am actually aware of OAndBackupX :-)

I may have found the source of the issue, but not why or how it got triggered. It may even be independent of OAndBackup.
Since this information could be of interest to people in this GitHub thread, and since it may get indexed by search engines, I post my findings here anyways:

All the APKs that disappeared from my phone were listed in /data/system/uiderrors.txt as Deleting invalid package at /data/app/...

Apparently something went awry during the LOS update, and Rescue Party https://source.android.com/devices/tech/debug/rescue-party was triggered.
The APK deletions were done by scanDirLI() in PackageManagerService.java https://android.googlesource.com/platform/frameworks/base/+/master/services/core/java/com/android/server/pm/PackageManagerService.java.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants