Skip to content

Commit

Permalink
Fix kernel lookup
Browse files Browse the repository at this point in the history
  • Loading branch information
davidbrochart committed Apr 12, 2021
1 parent 02cc7d7 commit 9fa0bbf
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion jupyter_server/services/kernels/kernelmanager.py
Original file line number Diff line number Diff line change
Expand Up @@ -379,12 +379,14 @@ def kernel_model(self, kernel_id):
self._check_kernel_id(kernel_id)
kernel = self._kernels[kernel_id]

connections = self._kernel_connections.get(kernel_id, 0)

model = {
"id":kernel_id,
"name": kernel.kernel_name,
"last_activity": isoformat(kernel.last_activity),
"execution_state": kernel.execution_state,
"connections": self._kernel_connections[kernel_id],
"connections": connections,
}
return model

Expand Down

0 comments on commit 9fa0bbf

Please sign in to comment.