I've found an issue where a while loop without any timing delays causes the browser to think it's a rouge script and presents a dialogue to force it to stop. This code reproduces it on FF.
from sense_hat import *
sense = SenseHat()
while True:
sense.set_pixel(0,0, 255,255,255)
After manually clicking Stop script the following error is thrown from right down inside Skulpt;
[Exception... "Unexpected error" nsresult: "0x8000ffff (NS_ERROR_UNEXPECTED)" location: "JS frame :: https://trinket-cdn.trinket.io/361592c4-skulpt.min.js :: Sk.misceval.asyncToPromise :: line 270" data: no] in https://trinket-cdn.trinket.io/361592c4-skulpt.min.js
One possible solution to this would be to force a time delay inside a while loop that doesn't implement any explicitly. I think we need to avoid tripping the browser's own script protection mechanisms.
FireFox 47.0, Mozilla Firefox for Ubuntu canonical - 1.0.
Linux 3.13.0-91-generic #138-Ubuntu SMP Fri Jun 24 17:00:34 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
I've found an issue where a while loop without any timing delays causes the browser to think it's a rouge script and presents a dialogue to force it to stop. This code reproduces it on FF.
After manually clicking
Stop script
the following error is thrown from right down inside Skulpt;One possible solution to this would be to force a time delay inside a while loop that doesn't implement any explicitly. I think we need to avoid tripping the browser's own script protection mechanisms.
FireFox 47.0, Mozilla Firefox for Ubuntu canonical - 1.0. Linux 3.13.0-91-generic #138-Ubuntu SMP Fri Jun 24 17:00:34 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux