mirror of
https://github.com/vale981/emacs-jupyter
synced 2025-03-05 23:41:38 -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)))
|
:code code)))
|
||||||
(setf (jupyter-request-run-handlers-p req) (not silently))
|
(setf (jupyter-request-run-handlers-p req) (not silently))
|
||||||
(jupyter-add-callback req
|
(jupyter-add-callback req
|
||||||
:error (lambda (msg)
|
:execute-reply (lambda (msg)
|
||||||
(cl-destructuring-bind (&key ename evalue &allow-other-keys)
|
(cl-destructuring-bind (&key status ename evalue &allow-other-keys)
|
||||||
(jupyter-message-content msg)
|
(jupyter-message-content msg)
|
||||||
(message "jupyter (%s): %s" ename
|
(unless (equal status "ok")
|
||||||
(xterm-color-filter evalue))))
|
(message "jupyter (%s): %s" ename
|
||||||
|
(xterm-color-filter evalue)))))
|
||||||
:execute-result
|
:execute-result
|
||||||
(lambda (msg)
|
(lambda (msg)
|
||||||
(let ((res (jupyter-message-data msg :text/plain)))
|
(let ((res (jupyter-message-data msg :text/plain)))
|
||||||
|
|
Loading…
Add table
Reference in a new issue