From 59eba9d3c4a034d188d5b94836af9b8203a411a4 Mon Sep 17 00:00:00 2001 From: Nathaniel Nicandro Date: Sat, 6 Oct 2018 13:57:12 -0500 Subject: [PATCH] Check for widget dependencies in `jupyter-repl-insert-data` --- jupyter-repl.el | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/jupyter-repl.el b/jupyter-repl.el index 92944ae..433eb7e 100644 --- a/jupyter-repl.el +++ b/jupyter-repl.el @@ -580,7 +580,9 @@ When no valid mimetype is present in DATA, a warning is shown." (not (memq k jupyter-repl-graphic-mimetypes)))) collect k))) (cond - ((memq :application/vnd.jupyter.widget-view+json mimetypes) + ((and (memq :application/vnd.jupyter.widget-view+json mimetypes) + (require 'websocket nil t) + (require 'simple-httpd nil t)) (jupyter-widgets-display-model jupyter-current-client (plist-get (plist-get data :application/vnd.jupyter.widget-view+json)