baumgarr / nixnote2

Nixnote - A clone of Evernote for Linux
http://www.nixnote.org
Other
1.11k stars 157 forks source link

Lots of empty notebooks after syncing #290

Open federico-piai opened 7 years ago

federico-piai commented 7 years ago

I made a few changes with NixNote (in particular I deleted, created and renamed some notebooks and I moved them to other stacks, and created some new notes).

Then I synced with my Evernote account

After that I find a lot of empty notebooks without name in Nixnote (about 200 notebooks): immagine

Those notebooks are not synced with Evernote however, and apart from those notes the sync went fine. I can delete them one by one (I cannot select more than one) but it takes a long time.

I'm using Ubuntu 16.10 and NixNote 2.0-beta-11

baumgarr commented 7 years ago

If you restart NixNote, are they still there?

federico-piai commented 7 years ago

Yes, they are still there even after restarting nixnote or even restarting the computer, reopening nixnote and re-syncing

baumgarr commented 7 years ago

Ok. I'll try to recreate it, but let's try and get rid of them first. Try this:

1.) Exit NixNote. 2.) Open a terminal 3.) Backup your ~/.nixnote directory. I don't want to mess this up & cause more problems. 4.) Issue this command: nixnote2 sqlExec "delete from DataStore where lid in (select lid from DataStore where key=3001 and data='')"

Please note that the data='' line has two ' and not a double quote " Start nixnote again. Did they go away?

federico-piai commented 7 years ago

Thank you for those hits

That command did not work, but I made some tests with select and I ended up with this one:

nixnote2 sqlExec "delete from DataStore where lid in (select lid from DataStore where key=3000 and data is null)"

I launched this then started nixnote again and empty notebooks went away

Spid3 commented 7 years ago

I encounter this too when i have sync problem in issue#294

baumgarr commented 7 years ago

Is this still an issue for anyone on this thread?

federico-piai commented 7 years ago

After the fix I talked you about I do not have encountered this problem anymore