[BUG] Invalid or unexpected token
dispbd opened this issue · 5 comments
Describe the bug
Apparently, when accessing the database, an error occurs, but the problem is that it is not clear where in the code.
I haven’t seen an error before, so I don’t understand how to deal with it yet.
Is it possible for the engine to show a more detailed error?
Screenshots
https://i.vgy.me/V9KFCg.png
Must gather (please complete the following information):
- total.js version 0.0.40
- node.js version 15.14.0
- operating system Windows Server 2016
Additional context
I thought that the problem is in accessing the file, but everything seems to be ok. Reboot didn't help.
Hi @dispbd, I think that DB reports
is broken. Can you check DB? Maybe try to drag & drop it to https://nosql.totaljs.com and if it will work, then the DB is OK. Let me know.
All ok.
https://i.vgy.me/Le0SXK.gif
or how to understand that there is an error in the file?
Hmm. I'm looking into the source-code and that exception is evaluated if the file is broken. Can you send me your DB to my email or some shared drive? Please send me info about it on petersirka@gmail.com
I forgot to write that I figured it out.
As it turned out, the problem is in one line. The code editor glitched and projected the commentary keyboard shortcut, which is why the pound sign appeared on the line.
https://i.vgy.me/5V2usl.png
Initially, this was not obvious, since there are already more than 40 thousand lines in the database. Found it due to the inconsistency of the number of lines in the code editor and on the site. He helped in the end, thanks!
The web server, most surprisingly, continued to work despite the error, but at the same time with oddities. That is, it nevertheless partially processes the document.
On the one hand, it's good that the site doesn't crash because of one line in the database. On the other hand, I would like a more detailed error to understand similar problems in the future, if possible. Thanks a lot!
Great! Thank you.