oppia / oppia-android

A free, online & offline learning platform to make quality education accessible for all.
https://www.oppia.org
Apache License 2.0
318 stars 520 forks source link

Even after deleting cache and data, uninstalling and reinstalling the app has the deleted data #4518

Open KolliAnitha opened 2 years ago

KolliAnitha commented 2 years ago

Describe the bug Even after deleting cache and data, uninstalling and reinstalling the app has the deleted data

To Reproduce Steps to reproduce the behavior:

  1. Open Oppia with profiles
  2. Now go to settings- App management- Oppia- Click on Storage usage- Clear cache and Clear data
  3. Open Oppia and click on Next and Get started
  4. Create admin pin- Create a profile- and open a few topics
  5. Select Admin- Enter Pin dialog box opens- Click on I forgot my pin
  6. Go to Play store link will be present click on it and uninstall then reinstall the app
  7. Open Oppia

Expected behavior Oppia should open up and introduction should be displayed. Old profiles with deleted cache and data should not be seen

Demonstration https://user-images.githubusercontent.com/101634267/185777346-493aba7d-3e8f-404a-af4d-4227cce19dba.mp4 https://user-images.githubusercontent.com/101634267/185777355-2f3acefe-6ad3-4098-b832-6f834a1c85df.mp4

Environment Device name: One plus Nord2 5G Android version : Android 11 App version : 0.8-alpha-091b45a188

adhiamboperes commented 1 year ago

Hey @BenHenning From my investigation, this seems to have been caused by automatic backups. We allow this feature in our manifest. From the look of things, automatic data restore is a problem when an admin is trying to reset a forgotten admin password.

Is it important for the app to be able to backup to the cloud at the moment?

We can disable backups by setting android:allowBackup to false in the manifest.

Would you rather go with a different solution for this issue?

adhiamboperes commented 1 year ago

References: https://developer.android.com/guide/topics/data/autobackup

https://developer.android.com/guide/topics/data/testingbackup