[Snap!] Detect script changes

Issue #2 closed
Bernat Romagosa created an issue

We should detect when a script changes in the IDE and recompile + send it to the board to update.

Comments (5)

  1. John Maloney repo owner

    How do we handle the case where the script is already running? Unfortunately it not possible, in general, to change a script while it is running with the uBlocks VM design, although some special cases (e.g. changing a constant) are possible. A simple first cut would be to stop the script if it is running and let the user click on it to restart it with the new version of the code.

  2. Bernat Romagosa reporter

    What I did in the WhiteCat environment is to stop that script and start it back again, but stopping it and not starting it automatically is also okay I guess :)

  3. John Maloney repo owner

    Initially let's stop the script and let the user restart it manually. That seems simpler to debug. Later, we could add auto-restart like WhiteCat.

  4. Log in to comment