Don't permit raise of SystemExit when some library calls sys.exit().
MODIFY
runtime/src/jycessing/mode/run/SketchRunner.java
runtime/src/jycessing/mode/run/SketchRunner.java
@@ -118,8 +118,12 @@ public class SketchRunner implements SketchService {
Runner.runSketchBlocking(sketch, stdout, stderr, sketchPositionListener);
} catch (final PythonSketchError e1) {
log("Sketch runner caught " + e1);
+ if (e1.getMessage().startsWith("SystemExit")) {
+ // Someone called sys.exit(). No-op.
+ } else {
modeService.handleSketchException(
id, convertPythonSketchError(e1, sketch.codeFileNames));
+ }
} catch (final Exception e2) {
if (e2.getCause() != null && e2.getCause() instanceof PythonSketchError) {
modeService.handleSketchException(

Don't permit raise of SystemExit when some library calls sys.exit(). #264.