Skip to content

Commit 3130a2e

Browse files
authored
Merge pull request #908 from datalayer-externals/feat/resource-usage-pid
2 parents dc3cfe3 + a274c4d commit 3130a2e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ipykernel/kernelbase.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -962,7 +962,7 @@ def get_process_metric_value(self, process, name, attribute=None):
962962
return None
963963

964964
async def usage_request(self, stream, ident, parent):
965-
reply_content = {"hostname": socket.gethostname()}
965+
reply_content = {"hostname": socket.gethostname(), "pid": os.getpid()}
966966
current_process = psutil.Process()
967967
all_processes = [current_process] + current_process.children(recursive=True)
968968
process_metric_value = self.get_process_metric_value

0 commit comments

Comments
 (0)