-
Notifications
You must be signed in to change notification settings - Fork 305
Description
Hi, I am working on a provisioner for remote kernels via SSH (https://github.com/caenrigen/sshpyk/tree/provisioner).
I noticed that my provisioner's async def terminate(self, restart: bool = False) never receives a restart=True value even if I restart the kernel (in JupyterLab).
From inspecting jupyter_client this happens because async def _async_send_kernel_sigterm(self, restart: bool = False) is never being passed the restart argument at all (and it defaults always to False from default python args):
jupyter_client/jupyter_client/manager.py
Line 480 in 6ea834d
| await self._async_send_kernel_sigterm() |
Is this a bug or intended behaviour? Would you accept a PR if it is a bug? though I probably have to implement a workaround anyway for some backwards compatibility with previous version of jupyter_client, I think I should be able to by caching the restart argument passed to provisioner.shutdown_requested.
As a side note I also notice that _async_kill_kernel does not always receive the argument either, intended?
jupyter_client/jupyter_client/manager.py
Line 545 in 6ea834d
| await self._async_kill_kernel() |