From 3b2e553b05d84ea9de15d27b8e4ef5544e541cb1 Mon Sep 17 00:00:00 2001 From: Kyle Kelley Date: Sat, 16 Sep 2023 19:02:21 -0700 Subject: set `evalue` to a one space string for truthiness on old jupyter (#20531) "Fixes" the exception display issue of #20524 on older versions of Jupyter that required `evalue` to be truthy. For now, until we can do proper processing of the `ExceptionDetails` this will make Jupyter Notebook 6.5.1 and below happy. This is the alternative "just work now" PR to #20530 --- cli/tools/jupyter/server.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'cli/tools') diff --git a/cli/tools/jupyter/server.rs b/cli/tools/jupyter/server.rs index c15dab6c2..e3e712065 100644 --- a/cli/tools/jupyter/server.rs +++ b/cli/tools/jupyter/server.rs @@ -358,7 +358,7 @@ impl JupyterServer { .new_message("error") .with_content(json!({ "ename": err.to_string(), - "evalue": "", + "evalue": " ", // Fake value, otherwise old Jupyter frontends don't show the error "traceback": [], })) .send(&mut *self.iopub_socket.lock().await) @@ -425,7 +425,7 @@ impl JupyterServer { .new_message("error") .with_content(json!({ "ename": name, - "evalue": "", + "evalue": " ", // Fake value, otherwise old Jupyter frontends don't show the error "traceback": [], })) .send(&mut *self.iopub_socket.lock().await) -- cgit v1.2.3