-
Notifications
You must be signed in to change notification settings - Fork 43
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Node output does not match RunJs #225
Comments
@palgramming thanks for raising this, looks like this is a bug that was introduced recently in version 1.13 |
well I am glad I was helpful and not just a idiot .... Also it seems like when the program first launches one has access to the settings menu but once you run a program the first time the settings menu will no longer open. I have verified this on a windows 10 64 bit machine with the version you mentioned 1.13.1.0 Even with Bugs thanks for your program |
@palgramming thanks again, I've now released version 1.14.0 that includes a number of updates and a fix for the original issue you saw. Regarding the settings menu, I've checked through various scenarios on Windows 10 and I've not been able to recreate that issue. Please let me know if you're still seeing it on 1.14.0. |
ok well the first issue is solved but the setting menu issue is still happening 1 open RunJS > file > settings and the preferences menu opens then close it so I closed runJS and then did this like 3 times and same thing happened once more than one code statement is executed the then got the same results. Put both console.logs on same line with semi-colons and they output correct but then settings will not open close program and all is good again hope this helps ... Thanks for you hard work on this |
@lukehaas not sure if related - I'll open a new issue if not - but here's another weird case: when in fact, |
@selrond this is unrelated. If there is an error in the code, RunJS will display the error and nothing else. |
Thanks for the reply. Given that JS has a compilation phase, and execution phase - current RunJs behavior is implicitly suggesting, that the error is compile-time – (nothing else is run, only error is visible) – instead of execution-time (runtime) – which Considering that RunJs is being used for teaching a lot (@getify uses it for instance), this confusion might manifest itself even more (certainly did for me). I think having the "standard" output behavior is essential for a tool like this. |
@selrond some very good points. I will work towards this for the next release. The reasoning for the current behaviour was for the aim of providing more helpful errors that potentially relate to features of RunJS. For example, if you try and use a NPM package that hasn't yet been installed RunJS will give you the option to install it with the error message: |
I too have been bitten by this, even recently. Very common debugging process is to put a console.log statement right before a line of code you suspect is throwing an exception. Was quite confused why it did not show the console message. Then realized I had to comment out the throwing line and insert a return instead, to see my output. I would recommend maybe a compromise here, where the console always shows messages that happened during runtime, but then a little banner at the top of the code frame could highlight (with color!) the uncaught exception, and would be expandable to show the stack trace. In that same banner could be the prompt you suggest to be able that install a missing dependency, or toggle a feature, or whatever. That would be quite useful! |
@getify great suggestion. Will aim to have some improvements in this area soon. |
I think the attached image show what is happening Node output the console log statements properly but same code duplicates the array after it is reversed and does not print it before being reversed .... Any help and explanation would be helpful
The text was updated successfully, but these errors were encountered: