unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
From: Andreas Enge <andreas@enge.fr>
To: 57077@debbugs.gnu.org
Subject: bug#57077: guix-jupyter fails a test
Date: Tue, 9 Aug 2022 15:23:57 +0200	[thread overview]
Message-ID: <YvJf7XqVKOxrgvh6@jurong> (raw)

Hello,

guix-jupyter currently fails to build with the error message below. While I
noticed it when updating python-sympy, the problem was already present
before.

Andreas


test-name: execute_request
location: /tmp/guix-build-guix-jupyter-0.2.2.drv-0/source/tests/kernels.scm:100
source:
+ (test-equal
+   "execute_request"
+   42
+   (let ((request
+           (message
+             (header "execute_request" "luser" "12345")
+             (scm->json-string
+               (execute-request->json
+                 (execute-request (code "40 + 2\n")))))))
+     (send-message %kernel request)
+     (let* ((replies
+              (unfold
+                (cut > <> 4)
+                (lambda (_) (read-message %kernel 10000))
+                #{1+}#
+                0)))
+       (define (type-predicate type)
+         (lambda (message)
+           (string=? (message-type message) type)))
+       (and (every message? (pk 'replies replies))
+            (match (filter (type-predicate "status") replies)
+                   ((busy idle)
+                    (and (eq? 'busy
+                              (kernel-status-execution-state
+                                (json->kernel-status (message-content busy))))
+                         (eq? 'idle
+                              (kernel-status-execution-state
+                                (json->kernel-status (message-content idle))))
+                         (equal?
+                           (message-parent-header busy)
+                           (message-header request))
+                         (equal?
+                           (message-parent-header idle)
+                           (message-header request)))))
+            (let ((input (find (type-predicate "execute_input") replies)))
+              (equal?
+                (message-parent-header input)
+                (message-header request)))
+            (let ((reply (find (type-predicate "execute_reply") replies)))
+              (equal?
+                (message-parent-header reply)
+                (message-header request)))
+            (let ((result
+                    (find (type-predicate "execute_result") replies)))
+              (and (equal?
+                     (message-parent-header result)
+                     (message-header request))
+                   (let* ((content
+                            (json-string->scm (message-content result)))
+                          (data (assoc-ref content "data"))
+                          (text (assoc-ref data "text/plain")))
+                     (string->number text))))))))

;;; (replies (#<<message> header: #<<header> id: "5103841f-98e1ea45964e58d9ba214dc5_900_3" user: "username" session: "5103841f-98e1ea45964e58d9ba214dc5" date: "2022-08-09T13:21:24.436017Z" type: "kernel_info_reply" version: "5.3" sender: #f> parent-header: #<<header> id: "7b136e32ddcbe2e226edffb116a4fca9" user: "luser" session: "12345" date: "2022-08-09T13:21:24.298532000" type: "kernel_info_request" version: "5.0" sender: #f> metadata: "{}" content: "{\"status\": \"ok\", \"protocol_version\": \"5.3\", \"implementation\": \"ipython\", \"implementation_version\": \"8.2.0\", \"language_info\": {\"name\": \"python\", \"version\": \"3.9.9\", \"mimetype\": \"text/x-python\", \"codemirror_mode\": {\"name\": \"ipython\", \"version\": 3}, \"pygments_lexer\": \"ipython3\", \"nbconvert_exporter\": \"python\", \"file_extension\": \".py\"}, \"banner\": \"Python 3.9.9 (main, Jan  1 1970, 00:00:01) \\nType 'copyright', 'credits' or 'license' for more information\\nIPython 8.2.0 -- An enhanced Interactive Python. Type '?' for help.\\n\", \"help_links\": [{\"text\": \"Python Reference\", \"url\": \"https://docs.python.org/3.9\"}, {\"text\": \"IPython Reference\", \"url\": \"https://ipython.org/documentation.html\"}, {\"text\": \"NumPy Reference\", \"url\": \"https://docs.scipy.org/doc/numpy/reference/\"}, {\"text\": \"SciPy Reference\", \"url\": \"https://docs.scipy.org/doc/scipy/reference/\"}, {\"text\": \"Matplotlib Reference\", \"url\": \"https://matplotlib.org/contents.html\"}, {\"text\": \"SymPy Reference\", \"url\": \"http://docs.sympy.org/latest/index.html\"}, {\"text\": \"pandas Reference\", \"url\": \"https://pandas.pydata.org/pandas-docs/stable/\"}]}" buffers: ()> #<<message> header: #<<header> id: "5103841f-98e1ea45964e58d9ba214dc5_900_4" user: "username" session: "5103841f-98e1ea45964e58d9ba214dc5" date: "2022-08-09T13:21:24.438407Z" type: "status" version: "5.3" sender: #vu8(107 101 114 110 101 108 46 100 53 55 102 102 101 102 53 45 48 98 102 50 45 52 97 57 102 45 97 99 50 52 45 53 53 100 54 97 97 100 102 53 56 52 97 46 115 116 97 116 117 115)> parent-header: #<<header> id: "7b136e32ddcbe2e226edffb116a4fca9" user: "luser" session: "12345" date: "2022-08-09T13:21:24.298532000" type: "kernel_info_request" version: "5.0" sender: #f> metadata: "{}" content: "{\"execution_state\": \"idle\"}" buffers: ()> #<<message> header: #<<header> id: "5103841f-98e1ea45964e58d9ba214dc5_900_5" user: "username" session: "5103841f-98e1ea45964e58d9ba214dc5" date: "2022-08-09T13:21:24.470543Z" type: "status" version: "5.3" sender: #vu8(107 101 114 110 101 108 46 100 53 55 102 102 101 102 53 45 48 98 102 50 45 52 97 57 102 45 97 99 50 52 45 53 53 100 54 97 97 100 102 53 56 52 97 46 115 116 97 116 117 115)> parent-header: #<<header> id: "b101b0c27f41055fc03178fdce86a4f6" user: "luser" session: "12345" date: "2022-08-09T13:21:24.465152000" type: "execute_request" version: "5.0" sender: #f> metadata: "{}" content: "{\"execution_state\": \"busy\"}" buffers: ()> #<<message> header: #<<header> id: "5103841f-98e1ea45964e58d9ba214dc5_900_6" user: "username" session: "5103841f-98e1ea45964e58d9ba214dc5" date: "2022-08-09T13:21:24.471181Z" type: "execute_input" version: "5.3" sender: #vu8(107 101 114 110 101 108 46 100 53 55 102 102 101 102 53 45 48 98 102 50 45 52 97 57 102 45 97 99 50 52 45 53 53 100 54 97 97 100 102 53 56 52 97 46 101 120 101 99 117 116 101 95 105 110 112 117 116)> parent-header: #<<header> id: "b101b0c27f41055fc03178fdce86a4f6" user: "luser" session: "12345" date: "2022-08-09T13:21:24.465152000" type: "execute_request" version: "5.0" sender: #f> metadata: "{}" content: "{\"code\": \"40 + 2\\n\", \"execution_count\": 1}" buffers: ()> #<<message> header: #<<header> id: "5103841f-98e1ea45964e58d9ba214dc5_900_7" user: "username" session: "5103841f-98e1ea45964e58d9ba214dc5" date: "2022-08-09T13:21:24.497586Z" type: "execute_result" version: "5.3" sender: #vu8(107 101 114 110 101 108 46 100 53 55 102 102 101 102 53 45 48 98 102 50 45 52 97 57 102 45 97 99 50 52 45 53 53 100 54 97 97 100 102 53 56 52 97 46 101 120 101 99 117 116 101 95 114 101 115 117 108 116)> parent-header: #<<header> id: "b101b0c27f41055fc03178fdce86a4f6" user: "luser" session: "12345" date: "2022-08-09T13:21:24.465152000" type: "execute_request" version: "5.0" sender: #f> metadata: "{}" content: "{\"data\": {\"text/plain\": \"42\"}, \"metadata\": {}, \"execution_count\": 1}" buffers: ()>))
expected-value: 42
actual-value: #f
result: FAIL



error: in phase 'check': uncaught exception:
%exception #<&invoke-error program: "make" arguments: ("check" "-j" "4") exit-status: 2 term-signal: #f stop-signal: #f>
phase `check' failed after 10.7 seconds
command "make" "check" "-j" "4" failed with status 2
builder for `/gnu/store/i1r5p6g0k3a98316x3s2yrpx9kwjq9vn-guix-jupyter-0.2.2.drv' failed with exit code 1





             reply	other threads:[~2022-08-09 13:25 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-09 13:23 Andreas Enge [this message]
2022-08-09 21:17 ` bug#57077: guix-jupyter fails a test Ludovic Courtès
2022-09-08 19:35   ` Ludovic Courtès
2022-09-14 20:34 ` Ricardo Wurmus
2022-09-15 16:35 ` bug#57077: gnu: guix-jupyter: Fix build and check phase MadalinIonel.Patrascu
2022-09-15 16:37 ` bug#57077: [PATCH] " Mădălin Ionel Patrașcu
2023-01-20 11:24   ` bug#57077: guix-jupyter fails a test Ludovic Courtès
2023-01-22  2:02     ` bug#57077: [ext] " MadalinIonel.Patrascu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=YvJf7XqVKOxrgvh6@jurong \
    --to=andreas@enge.fr \
    --cc=57077@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).