We have moved to a new Sailfish OS Forum. Please start new discussions there.
6

apps data does not clear after uninstallation

asked 2016-09-28 20:31:55 +0300

motubha gravatar image

updated 2018-09-02 15:35:51 +0300

Alex gravatar image

some apps which have login detail remains even if app is removed. after reinstalling the app, the apps state found the same as it before removing.

edit retag flag offensive close delete

Comments

1

so were is the bug?

till ( 2016-09-28 20:45:22 +0300 )edit

The same goes for most Linux distributions, maybe all.

eson ( 2016-09-29 12:19:22 +0300 )edit

4 Answers

Sort by » oldest newest most voted
5

answered 2016-09-29 01:28:13 +0300

coderus gravatar image

Unfortunately SailfishOS can not automatically uninstall any configuration/settings data written by applications when uninstalling pacckages. Application developers should add such functionality to applications themselves.

edit flag offensive delete publish link more

Comments

So a user has to open the app and clear the cache manually before removing the app? Thats not how this should work. The user expects that all relevant data is removed from the device automatically when the app gets removed. That is what Android does (and maybe iOS, too?).

ejjoman ( 2016-09-29 11:17:44 +0300 )edit
1

you can list configuration files/folders to rpm spec and it will be removed during package uninstallation

coderus ( 2016-09-29 11:28:23 +0300 )edit

Thanks, didn't know that :)

That would solve the clearing of the cache and other files on the disk. What about dconf settings? :)

ejjoman ( 2016-09-29 12:07:49 +0300 )edit

dconf can be removed in %post scriptlet, but it's not allowed in harbour.

coderus ( 2016-09-29 12:29:00 +0300 )edit

@motuba:
If an application creates files on its own, the application has to remove it on it's own. A package-manager can and should handle known files at packaging-time.

hoschi ( 2016-09-29 18:40:09 +0300 )edit
5

answered 2016-09-29 11:15:12 +0300

I think, we (the developers) need a way to clean up behind ourselves, too!

Currently, a developer is not able to clean the settings (dconf), caches or local databases. I am currently working on Hipsterfish (Instagram client) and when I implement caching, the cache size could get really huge. No normal user will understand that he needs to clear the cache manually after removing the app.

IMHO the best way to achieve this, would be to allow RPM postun-scripts in harbour apps. Maybe Jolla could provide simple commands that are allowed to be run safely:

  • sailfishos-clear-app-cache $APPNAME (for cache)
  • sailfishos-clear-app-settings $APPNAME (for dconf)
  • sailfishos-clear-app-data $APPNAME (for local app data [sqlite dbs, etc])
  • ...

As the standard paths are already defined, the commands could ensure that only the app's data can be cleared. Jolla should even be able to validate these commands in the RPM validator (white listing).

edit flag offensive delete publish link more

Comments

1

I agree that there should by a system-wide option to remove or keep the data (I would definitly leave this decision at the user's side!). Maybe in a similar way as it is currently done with android apps? However, it should also be possible after the app is uninstalled, so there need to be some sort mechanism (database, scan in specific folders like .config) for remains of an app independently of their installation status

till ( 2016-09-29 11:34:19 +0300 )edit

At first the really should stop using RPM at all, it is a complex and weird mess.

hoschi ( 2016-09-29 18:42:15 +0300 )edit
2

answered 2016-09-28 23:05:52 +0300

Rikujolla gravatar image

Apps which use sqlite database leave your personal data to the folder .local/share/harbour-appname. If you want to delete saved data, you need to remove that folder. I find this feature useful. The app is removed but personal data is still available.

edit flag offensive delete publish link more

Comments

1

yes it may be useful But what about normal user who doesn't want to leave data behind. who doesn't know what is sqlite database. who doesn't care about file-browser. remember we are going to make sailfishos for everyone on this planet not for just developer or advanced user. there should be option to remove app data during uninstallation.

motubha ( 2016-09-29 05:57:24 +0300 )edit
1

answered 2016-09-28 20:52:11 +0300

Kromonos gravatar image

I love this behavour :)
You may search the settings in /home/nemo/.config or in /hom/nemo/.gconf.
You may want to search via console with: find / -name *<appname>*

edit flag offensive delete publish link more

Comments

If not comfortable with terminal, you can use the excellent app SearchNemo. Available from Store.

eson ( 2016-09-29 12:39:40 +0300 )edit
Login/Signup to Answer

Question tools

Follow
2 followers

Stats

Asked: 2016-09-28 20:31:55 +0300

Seen: 1,328 times

Last updated: Sep 29 '16