ID klienta: d852f89bdc964fbc8f250eb14bff47e2
Wersja synchronizacji: 3
Wersja profilu: 44
Wspierany menadżer kluczy: Nie
Rewizja: 7d2c1c08e
Sync target
Dropbox
Editor
Rich Text Editor
What issue do you have?
I had used Dropbox sync for years and I thought it was working correctly. When I installed Joplin on the new system and re-estabilished the sync, I expected it to download all notices from cloud. It didn't, moreover it deleted the data from the cloud. Luckily, I had backup or a third OS where I could retrieve everything.
Here is what is happening:
I have 3 systems:
A system - with Joplin notices
N system - new system
B system - backup system
I have a New system and installed Joplin, I establish Dropbox connection, all seemed fine. Sync downloaded over 400 notices (downloaded objects). Looked OK and I waited till the process is finished. When it had, I saw only default welcome notices, 1 notebook from the cloud and random 16 notices in All notebooks section (so without belonging to Notebooks, although originally they are in proper Notebooks). See the screenshot. After a few seconds, Joplin does another sync, deleting all notebooks and notices, keeping only what I got on system N (new).
When I log in to System A back, it automatically syncs and deletes my notices so it looks like on system N. Luckily, I have system B that I can get backups and restore lost data.
So again:
System A -> Dropbox
Dropbox -> System N where I get just fraction of data
System N -> deletes data on Dropbox
Dropbox -> deletes data on system A...
I have no idea where the issue happens. There are several possibilities:
Sync is not sending data correctly or it's not stored on cloud correctly
Sync is sending correctly to cloud but sync down (to a new Joplin instance) is not working correctly
This is a disaster. Any clue how to fix it and what or why is it happening?
Joplin was installed via snap, but the snap became corrupted. I noticed it after opening dev environment in terminal. There were a lot of errors and missing files.
I reinstalled Joplin snap. It should have kept the files, but instead I was greeted with an empty, default greeting window. I established the sync and this time the syn showed over 800 downloaded objects and all my notebooks and notices showed up correctly.
It looks like the snap was not accepting the correct data from sync and hence the issue. It was replicated, because new OS instances were copied from the old, one OS.
So this wasn't the bug in the app, but the bug in install files on my system.
Might be good to document what exactly led to data loss, so we could advise against that behaviour. Could you list few steps how to get into data losing state?
I thought I already described that. I'm not sure what you need more.
Somehow, snap package got corrupted. It basically worked fine, but I noticed from some time weird behavior, basically, whenever I watched some notice, it disappeared from the notebook and showed up on "Conflicts" temporary notebook. I couldn't figure it out why and I couldn't bring them back, so my Conflicts list grew... Obviously, the another issue was not being able to restore notices from sync.
Sync worked correctly as far I noticed. The logic was:
Sync happened successfully, and all notices were downloaded. The bug prevented them to be implemented. Sync discovers the difference between data in the cloud and locally, so it syncs again, deleting data on the cloud, because it assumes I deleted the notices and notebooks, although it was the problem of them not showing up after the sync in the first place.
Things that can or should be improved with the sync:
Validate that downloading data from the cloud is really implemented before the next sync, if not, error out and stop the sync. User needs to investigate and have clear message that sync worked, but data couldn't be implemented. If user thinks it is fixed, it can re-try the sync and check if it worked, if not, error will happen again, but the next sync will still be stopped and no data will be loss. It will look like a sync issue, but that's way better than losing hundreds of notices from many, many years.
The newly installed app creates Welcome notebook. After the sync, welcome is doubled, then tripled and so on. If the notebook and the same notices exists locally, sync shouldn't create duplicates. This also happens when I restore data from backup. After the sync, I get all notebooks doubled, so weirdly, when data was restored, downloading from the cloud worked correctly. This suggests that something was blocked or incomplete before, and restoring files from backup restored the missing files that caused the sync issue.
As to the snap corruption, can't say anything more. Every couple of years I notice that snaps are somehow bugged and not working correctly and need to be reinstalled. The problem is, there is no reinstall mechanism in snaps. One have to uninstall and install the package again. In theory, the data should be preserved but IN CASE OF JOPLIN, such reinstall wipes all the data.
So there are points that could result in loss of data:
reinstall of snaps
no validation if downloaded sync was implemented before the next sync
I would gladly use non-snap version but Joplin's AUR version is badly maintained, always out of date. Flatpack may be a good solution, but it's runtime is HUGE, compared to snaps and because I don't use flatpacks, taking 2GB of runtime just for Joplin, makes no sense. Snaps are more condensed with the space.