mirror of
https://github.com/vale981/emacs-jupyter
synced 2025-03-05 07:41:37 -05:00
Use the execute-reply
callback to check for errors
This seems to be the more general way to check for errors.
This commit is contained in:
parent
b2d8dfc2a7
commit
78174f4334
1 changed files with 6 additions and 5 deletions
|
@ -1430,11 +1430,12 @@ displayed without anything showing up in the REPL buffer."
|
|||
:code code)))
|
||||
(setf (jupyter-request-run-handlers-p req) (not silently))
|
||||
(jupyter-add-callback req
|
||||
:error (lambda (msg)
|
||||
(cl-destructuring-bind (&key ename evalue &allow-other-keys)
|
||||
(jupyter-message-content msg)
|
||||
(message "jupyter (%s): %s" ename
|
||||
(xterm-color-filter evalue))))
|
||||
:execute-reply (lambda (msg)
|
||||
(cl-destructuring-bind (&key status ename evalue &allow-other-keys)
|
||||
(jupyter-message-content msg)
|
||||
(unless (equal status "ok")
|
||||
(message "jupyter (%s): %s" ename
|
||||
(xterm-color-filter evalue)))))
|
||||
:execute-result
|
||||
(lambda (msg)
|
||||
(let ((res (jupyter-message-data msg :text/plain)))
|
||||
|
|
Loading…
Add table
Reference in a new issue