Closed lhagan closed 1 year ago
Hi @lhagan, sorry you are facing this issue! I have just released a potential fix! Could you try v1.0.4 and let me know if it works for you?
In case you are interested in more detailed information: The (potential) fix checks to make sure the particular notes object that the application is attempting to parse is not null before attempting to determine what type it is. My suspicion is that the particular notes object that the application is attempting to parse is deleted but still lingering around as an attachment in the note data itself. My general impression is that deleted note objects and references to deleted note objects can still linger around in the Notes.app database for quite some time, and apple-notes-liberator
doesn't handle such cases as well as it should. Hopefully with this change though, it should no longer attempt to determine the type of a deleted notes object and thus not throw a NullPointerException
.
Of course I could be wrong and the problem could be something else entirely! I am curious to see if v1.0.4 works for you.
Long-term, I would like to be able to have better tests for deleted notes cases, but right now my test case is "manually run against my Notes.app database that contains deleted notes and see if it works", which I know is not great. Perhaps I can seed some test sqlite databases with data representing different scenarios and use them to write some automated tests. But anyway, I digress. :)
Thank you for taking the time to make an issue and I hope to hear back from you!
Wow -- thanks for the quick solution! v1.0.4 fixed this issue.
Awesome! Glad to hear it!
I'm getting the following error when I run the jar:
apple-notes-liberator
appears to have found the correct database since it copiednotes.sqlite
into theliberated-notes
folder. I manually queried that database using the following command:The extracted data includes the text of one of my notes, so I don't think the problem is with the source data.
My configuration:
Here's some additional information from the log:
Any ideas of what might be tripping it up?