Closed jenga201 closed 1 year ago
Interesting.
I will say that it is entirely reasonable that the tree can be corrupted.
If it isn't an issue, could you send the response from /tree
?
I'd say your guess is probably correct. I'll make a branch with a small change that should eliminate all undefined values.
I actually see some error JS generated right after the call to tree is made
Here's the tree file pulled from minio (renamed to .txt to support github upload). I'm not sure if it matters, but I'm unable to get it directly from notea.
Quick update: I forgot to push the new branch earlier, so I did it now and created a draft for a PR: #158. Could you tell me if the version changes anything for you?
Also, it is weird that you're unable to just call /api/tree
and get the tree like so.
I'm running this on unraid using the image in docker hub, so I'm not sure I can build this PR locally. Is it possible for you to upload a new tag to docker hub?
Also, yes.. using /api/tree works fine. I was trying /tree initially.
I uploaded a build as teccthedev/notea:pr-160
, which you should be able to use. Please tell me if it fixes the problem.
Also, sorry for the delay.
The new PR worked wonderfully.
The initial page load showed the same error, then a page refresh seemed to clean everything up.
I'm not sure if it's expected, but going back to the main branch shows the error again. I'm guessing the tree isn't saved after it's loaded & modified.
No, the tree isn't saved. The fix only applies to when the tree is requested by the client. I'm mildly scared to apply the fix to the saving system as well since that could potentially lose data (if there's a bug), but hey. Anyways, I'll go ahead and merge the change since it clearly works.
I've had a notea/minio installation for about a year now. This error started showing up after the latest update.
There are no errors in the logs for either notea or minio. This seems to be a JS error only.
Is it possible that the /tree JSON can become corrupt with orphaned records to cause an undefined object member error?