SlicerJupyter
SlicerJupyter copied to clipboard
Already used connection error
From @jcfr: "At some point I got an already used connection message ... but I am not able to reproduce it yet."
When user requests a kernel restart or Jupyter determines that the kernel is dead then, Jupyter sends a server stop request to Slicer. If Slicer is busy (in the middle of a long computation) then Jupyter kills the process - which is actually just the launcher, so not SlicerApp-real keeps running, still using the server port.
Maybe the kernelspec could be changed so that SlicerApp-real is launched directly?
Or the launcher could kill SlicerApp-real when it gets a kill signal (or more generally, it could pass all signals to the subprocess). This would make things more consistent across platforms since on mac there's no launcher.