Quick fix for jupyter logging
@@ -97,6 +97,8 @@ def notebook_metadata():
logger.exception("Failed to query for notebook sessions")
return {}
for nn in res:
+ # TODO: wandb/client#400 found a case where res returned an array of strings...
+ if isinstance(nn, dict) and nn.get("kernel"):
if nn['kernel']['id'] == kernel_id:
return {"root": s['notebook_dir'], "path": nn['notebook']['path'], "name": nn['notebook']['name']}
return {}
