Is there some hidden differences between terminal and editor in Espruino IDE #348
Replies: 12 comments
-
Posted at 2015-02-12 by @gfwilliams I just tried your code in the right-hand side of the Web IDE and it seems to work for me? (although I did have to remove the 2 strange characters that the forum added) Are you getting any errors/warnings highlighted in the right-hand side of the IDE where your code is? I know one really easy way to confuse it is to put more open brackets than close brackets - but the recent Web IDE has changes that should detect that and complain about it before the upload. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-02-12 by @gfwilliams Just to add - there is very little difference between right and left, apart from how newlines are treated. I got lots of complaints that people were doing things like this:
and it was breaking - because obviously if you type that into the left-hand side the code will be executed right after the first line. So now, the Web IDE tries to detect stuff like that and in those cases it replaces the newline with Hope that helps! |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-02-12 by Ritvars Nop. The code in right side of my IDE is the exactly like this in forum thread. When i copy/pasted to left side, is working perfectly. Btw, this is first time when i get some strange (no syntactic) errors or behaviour. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-02-12 by Ritvars One more thing. On terminal side cursor are in waiting mode. Its like broken terminal, when Rx or Tx line is disconnected and user still writing in console. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-02-12 by @gfwilliams That is strange. I use Ubuntu all the time, so I would have thought I'd have noticed problems if there were any. Actually sorry - I forgot to add I had to change Maybe type:
If it was an error sending to the board, that should help to recover from it. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-02-12 by Ritvars Actually it's my fault matrix, matrica. Diff between english and my native language. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-02-12 by Ritvars Brokened part of my example is found. Before posting of my code i deleted some commented lines out from code. Without thees lines code is running on board and nothing hangs. But anyway, case is wierd. Theese lines are commented anyway. Why interpreter hangs?
At end of each line is comment in my native language for myself. To remember what is done already. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-02-12 by @gfwilliams I still can't get it to happen - can you click 'save' in the Web IDE, save the file, and e-mail it to me? It might help me to figure out what's going on. I guess it's possible that there is some issue with uploading the comments (maybe it's something to do with UTF8 characters?). Probably if you turned on 'whitespace minification' in settings it would solve the problem? It makes it harder to debug though. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-02-12 by Ritvars After i turned on 'Whitespace Only' for code and modules, there is no more faults. Code downloaded to board and running like shown on video. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-02-12 by @gfwilliams Ok, It'll be fixed in the latest Web IDE from Git, or when I next do a release. The issue was that the character code of |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-02-12 by DrAzzy The IDE should probably throw up a warning when you try to send code that contains unicode characters - there's nothing good that can come from sending munged unicode to the Espruino, so we should notify people when it's doing that. (Of course, for this to be useful, something also needs to be done about how error message are displayed in the IDE, because they pop up and then vanish too fast to read them - maybe ones that are yellow/red, indicating errors, should stay for longer?) |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-02-13 by @gfwilliams Yes, I suppose it's an idea - currently it warns in the console and just replaces with a By the way, I just increased the timeout for notifications |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Posted at 2015-02-12 by Ritvars
The problem in short: i have written some small light show code for 8x8 LED matrix display using MAX7219 driver. Each small part of my code is designed and tested in left side of IDE window. All seems to working as expected. When i try to run all code parts together, my Espruino board hangs and should be restarted. All my code is bellow:
There is link to Youtube video: http://youtu.be/cTESkFNigac
Code should be buggy. Or... i can't understand where is difference between two parts of Espruino IDE.
Btw, sorry for worst english grammar ever, still learning.
Beta Was this translation helpful? Give feedback.
All reactions