boltex / leojs

Leo Literate Editor with Outline in Typescript
MIT License
23 stars 0 forks source link

"es_exception called without error!" - a frequently seen message #103

Closed tbpassin closed 6 months ago

tbpassin commented 6 months ago

Introducing a deliberate error into a script (using print()) produces the message, as do other errors -

exception executing script
ReferenceError: print is not defined
    at eval (eval at executeScriptHelper (c:\Users\tom\.vscode-oss\extensions\boltex.leojs-0.2.8-universal\dist\extension-node.js:2:1065610), <anonymous>:9:1)
    at eval (eval at executeScriptHelper (c:\Users\tom\.vscode-oss\extensions\boltex.leojs-0.2.8-universal\dist\extension-node.js:2:1065610), <anonymous>:13:3)
    at Commands.executeScriptHelper (c:\Users\tom\.vscode-oss\extensions\boltex.leojs-0.2.8-universal\dist\extension-node.js:2:1065648)
    at Commands.executeScript (c:\Users\tom\.vscode-oss\extensions\boltex.leojs-0.2.8-universal\dist\extension-node.js:2:1064871)
es_exception called without error!
saved: workbook.leo

It seems to be a minor error, but it seems pointless it it gets omitted over and over. The exclamation mark at the end becomes annoying, too.

boltex commented 6 months ago

@tbpassin Thanks for reporting the 'es_exception called without error!' message.

I was hunting for them some days ago - seems like I missed the one that is occurring when running a script triggers an error!

boltex commented 6 months ago

@tbpassin I found the bug: the actual check for es_exception being called without an error parameter was wrong.

Thanks again for filing in this issue! 😁

boltex commented 6 months ago

@tbpassin Fixed in https://github.com/boltex/leojs/pull/106 🥳