nuttyartist / notes

Fast and beautiful note-taking app written in C++. Write down your thoughts.
https://notes-foss.com
Mozilla Public License 2.0
3.77k stars 333 forks source link

User reported unable to delete/rename folders/subfolders #504

Open nuttyartist opened 1 year ago

nuttyartist commented 1 year ago

The same issue happened to me while migrating to 2.0.0. The developer back than told me to do the steps below and it fixed the problem. It also fixed the problem for the user.

Hello

I’m using your notes app right now and it’s performed very well. However, I recently encountered an error that occurs when I try to delete/rename folders/subfolders. I would usually be able to right click to delete or add new folders, but now when I select either option, the folders will not delete or prompt to rename themselves.

image (I can make new subfolders though, and I have a bunch of times.) image I’ve updated to the latest version, but I haven’t tried deleting and redownload the app in case my notes don’t save.

These are the steps I sent him that solved his problem

  1. Please back up your notes. You can do this on Windows (I assume you’re using Windows since it says your mail is sent from there), by copying the content of the folder here: C:\Users\user\AppData\Roaming\Awesomeness to a safe place. So please do that first.
  2. In Notes, click the 3 dots icon, and choose Import/Export notes -> Export. Save the exported file somewhere.
  3. Quit Notes. Make sure to quit it and not just close it to the system tray.
  4. Remove the content of the folder you backed up before in C:\Users\user\AppData\Roaming\Awesomeness. Again, be sure you backed it up! If something goes wrong, you can always restore everything by pasting those files back.
  5. After you removed the files there, open Notes. It should be completely empty, like brand new. Now, choose Import/Export notes -> Import from the menu and select the notes.nbk files you saved before. Now it should show all your notes again.
  6. Please check if you can now create delete and rename folders as before.
  7. If something happens and you can’t see your notes from some reason (it should not happen), don’t worry. Quit notes, and just copy paste the backup into the original location.

Maybe we can just close this issue and keep it as a reference for future users?

guihkx commented 1 year ago

Maybe we can just close this issue and keep it as a reference for future users?

Hmm, I don't know. To me, this seems like a bug we should at least try to investigate once we get good steps to reproduce it. Perhaps the person who reported the bug could share his notes database (in broken state)?

nuttyartist commented 1 year ago

You're right. I sent him a message.

nuttyartist commented 1 year ago

He replied with:

I'm not sure how to access the C:\Users\user\AppData\Roaming\Awesomeness folder since I didn't even need to back up my files to fix the issue. I just had to close the program instead of minimizing to tray and reopen the folder, and it worked again. If you still want my backup files, I can send them but I don't think that was the issue.

Do we still want it?

guihkx commented 1 year ago

Do we still want it?

I don't think it will be helpful to reproduce the issue, so probably not...

nuttyartist commented 1 year ago

I'm closing this until someone else reports the same issue.

zjeffer commented 1 year ago

I've had this issue for a while, reopening. Not sure what causes it.

guihkx commented 1 year ago

I found a really easy way to consistently reproduce this on a fresh database. There might be more ways, however.

Steps:

  1. Open Notes
  2. Click on the "+" button to create a new note
  3. Drag this newly created note and drop it onto the default "Notes" folder (on the first panel)
  4. Repeat step 3
  5. Create a folder
  6. Deleting this folder won't work (renaming it still does, however)

My initial observation is that this process causes a whole mess in all values of the absolute_path column in node_table.

Video:

https://github.com/nuttyartist/notes/assets/626206/bc32cce5-b858-4bc8-9bb7-bfe409fcdb28

nuttyartist commented 1 year ago

Ugh... What an annoying bug. Unfortunately I don't know much about SQL and the C++ DB code to solve this.

At least we can reproduce this now.