0s autopkgtest [04:14:33]: starting date and time: 2026-02-06 04:14:33+0000 0s autopkgtest [04:14:33]: git checkout: 508d4a25 a-v-ssh wait_for_ssh: demote "ssh connection failed" to a debug message 0s autopkgtest [04:14:33]: host juju-7f2275-prod-proposed-migration-environment-9; command line: /home/ubuntu/autopkgtest/runner/autopkgtest --output-dir /tmp/autopkgtest-work.fhg862li/out --timeout-copy=6000 --setup-commands 'ln -s /dev/null /etc/systemd/system/bluetooth.service; printf "http_proxy=http://squid.internal:3128\nhttps_proxy=http://squid.internal:3128\nno_proxy=127.0.0.1,127.0.1.1,localhost,localdomain,internal,login.ubuntu.com,archive.ubuntu.com,ports.ubuntu.com,security.ubuntu.com,ddebs.ubuntu.com,changelogs.ubuntu.com,keyserver.ubuntu.com,launchpadlibrarian.net,launchpadcontent.net,launchpad.net,keystone.ps5.canonical.com,objectstorage.prodstack5.canonical.com,radosgw.ps5.canonical.com\n" >> /etc/environment' --apt-pocket=proposed=src:jinja2,src:underscore --apt-upgrade jupyter-notebook --timeout-short=300 --timeout-copy=20000 --timeout-build=20000 '--env=ADT_TEST_TRIGGERS=jinja2/3.1.6-1build1 underscore/1.13.7~dfsg+~1.13.0-6' -- lxd -r lxd-armhf-10.145.243.197 lxd-armhf-10.145.243.197:autopkgtest/ubuntu/resolute/armhf 27s autopkgtest [04:15:00]: testbed dpkg architecture: armhf 29s autopkgtest [04:15:02]: testbed apt version: 3.1.14 33s autopkgtest [04:15:06]: @@@@@@@@@@@@@@@@@@@@ test bed setup 35s autopkgtest [04:15:08]: testbed release detected to be: None 43s autopkgtest [04:15:16]: updating testbed package index (apt update) 44s Get:1 http://ftpmaster.internal/ubuntu resolute-proposed InRelease [124 kB] 45s Get:2 http://ftpmaster.internal/ubuntu resolute InRelease [124 kB] 45s Hit:3 http://ftpmaster.internal/ubuntu resolute-updates InRelease 45s Hit:4 http://ftpmaster.internal/ubuntu resolute-security InRelease 45s Get:5 http://ftpmaster.internal/ubuntu resolute-proposed/multiverse Sources [32.6 kB] 45s Get:6 http://ftpmaster.internal/ubuntu resolute-proposed/main Sources [220 kB] 45s Get:7 http://ftpmaster.internal/ubuntu resolute-proposed/universe Sources [1593 kB] 45s Get:8 http://ftpmaster.internal/ubuntu resolute-proposed/restricted Sources [5260 B] 45s Get:9 http://ftpmaster.internal/ubuntu resolute-proposed/main armhf Packages [254 kB] 45s Get:10 http://ftpmaster.internal/ubuntu resolute-proposed/universe armhf Packages [1304 kB] 45s Get:11 http://ftpmaster.internal/ubuntu resolute-proposed/multiverse armhf Packages [8048 B] 45s Get:12 http://ftpmaster.internal/ubuntu resolute/multiverse Sources [310 kB] 45s Get:13 http://ftpmaster.internal/ubuntu resolute/main Sources [1410 kB] 45s Get:14 http://ftpmaster.internal/ubuntu resolute/universe Sources [21.3 MB] 46s Get:15 http://ftpmaster.internal/ubuntu resolute/main armhf Packages [1374 kB] 46s Get:16 http://ftpmaster.internal/ubuntu resolute/universe armhf Packages [14.9 MB] 46s Get:17 http://ftpmaster.internal/ubuntu resolute/multiverse armhf Packages [176 kB] 49s Fetched 43.2 MB in 5s (8812 kB/s) 50s Reading package lists... 57s autopkgtest [04:15:30]: upgrading testbed (apt dist-upgrade and autopurge) 59s Reading package lists... 59s Building dependency tree... 59s Reading state information... 59s Calculating upgrade... 60s The following packages will be upgraded: 60s python3-jinja2 60s 1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 60s Need to get 109 kB of archives. 60s After this operation, 0 B of additional disk space will be used. 60s Get:1 http://ftpmaster.internal/ubuntu resolute-proposed/main armhf python3-jinja2 all 3.1.6-1build1 [109 kB] 61s Fetched 109 kB in 0s (263 kB/s) 61s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 68395 files and directories currently installed.) 61s Preparing to unpack .../python3-jinja2_3.1.6-1build1_all.deb ... 61s Unpacking python3-jinja2 (3.1.6-1build1) over (3.1.6-1) ... 61s Setting up python3-jinja2 (3.1.6-1build1) ... 63s Reading package lists... 63s Building dependency tree... 63s Reading state information... 64s Solving dependencies... 64s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 66s autopkgtest [04:15:39]: rebooting testbed after setup commands that affected boot 110s autopkgtest [04:16:23]: testbed running kernel: Linux 6.8.0-87-generic #88~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Oct 14 14:00:09 UTC 2 136s autopkgtest [04:16:49]: @@@@@@@@@@@@@@@@@@@@ apt-source jupyter-notebook 155s Get:1 http://ftpmaster.internal/ubuntu resolute/universe jupyter-notebook 6.4.13-5ubuntu0.1 (dsc) [3737 B] 155s Get:2 http://ftpmaster.internal/ubuntu resolute/universe jupyter-notebook 6.4.13-5ubuntu0.1 (tar) [8501 kB] 155s Get:3 http://ftpmaster.internal/ubuntu resolute/universe jupyter-notebook 6.4.13-5ubuntu0.1 (diff) [52.5 kB] 156s gpgv: Signature made Tue Apr 22 01:32:11 2025 UTC 156s gpgv: using RSA key 00F6164E9C2D21BAFBC47E0E58DAD120A6939167 156s gpgv: Can't check signature: No public key 156s dpkg-source: warning: cannot verify inline signature for ./jupyter-notebook_6.4.13-5ubuntu0.1.dsc: no acceptable signature found 156s autopkgtest [04:17:09]: testing package jupyter-notebook version 6.4.13-5ubuntu0.1 158s autopkgtest [04:17:11]: build not needed 169s autopkgtest [04:17:22]: test pytest: preparing testbed 171s Reading package lists... 172s Building dependency tree... 172s Reading state information... 172s Solving dependencies... 172s The following NEW packages will be installed: 172s fonts-font-awesome fonts-glyphicons-halflings fonts-lato fonts-mathjax gdb 172s jupyter-core jupyter-notebook libargon2-1 libbabeltrace1 libc6-dbg 172s libdebuginfod-common libdebuginfod1t64 libdw1t64 libjs-backbone 172s libjs-bootstrap libjs-bootstrap-tour libjs-codemirror libjs-es6-promise 172s libjs-jed libjs-jquery libjs-jquery-typeahead libjs-jquery-ui libjs-marked 172s libjs-mathjax libjs-moment libjs-requirejs libjs-requirejs-text 172s libjs-text-encoding libjs-underscore libjs-xterm libnorm1t64 libpgm-5.3-0t64 172s libpython3.14 libpython3.14-minimal libpython3.14-stdlib libsodium23 172s libsource-highlight-common libsource-highlight4t64 libzmq5 node-jed 172s python-notebook-doc python-tinycss2-common python3-all python3-argon2 172s python3-argon2-cffi-bindings python3-astroid python3-asttokens 172s python3-bleach python3-bs4 python3-cffi python3-comm python3-coverage 172s python3-debugpy python3-decorator python3-defusedxml python3-executing 172s python3-fastjsonschema python3-html5lib python3-iniconfig python3-ipykernel 172s python3-ipython python3-ipython-genutils python3-jedi python3-jupyter-client 172s python3-jupyter-core python3-jupyterlab-pygments python3-matplotlib-inline 172s python3-mistune python3-nbclient python3-nbconvert python3-nbformat 172s python3-nest-asyncio python3-notebook python3-pandocfilters python3-parso 172s python3-platformdirs python3-pluggy python3-ply python3-prometheus-client 172s python3-prompt-toolkit python3-psutil python3-pure-eval python3-pycparser 172s python3-pytest python3-requests-unixsocket python3-send2trash 172s python3-soupsieve python3-stack-data python3-terminado python3-tinycss2 172s python3-tornado python3-traitlets python3-typeshed python3-wcwidth 172s python3-webencodings python3-zmq python3.14 python3.14-minimal 172s sphinx-rtd-theme-common 173s 0 upgraded, 99 newly installed, 0 to remove and 0 not upgraded. 173s Need to get 44.8 MB of archives. 173s After this operation, 197 MB of additional disk space will be used. 173s Get:1 http://ftpmaster.internal/ubuntu resolute/main armhf fonts-lato all 2.015-1build1 [2779 kB] 173s Get:2 http://ftpmaster.internal/ubuntu resolute/main armhf libdebuginfod-common all 0.194-1 [15.1 kB] 173s Get:3 http://ftpmaster.internal/ubuntu resolute/main armhf libpython3.14-minimal armhf 3.14.2-1 [905 kB] 173s Get:4 http://ftpmaster.internal/ubuntu resolute/main armhf python3.14-minimal armhf 3.14.2-1 [2155 kB] 173s Get:5 http://ftpmaster.internal/ubuntu resolute/main armhf fonts-font-awesome all 5.0.10+really4.7.0~dfsg-4.1build1 [531 kB] 173s Get:6 http://ftpmaster.internal/ubuntu resolute/universe armhf fonts-glyphicons-halflings all 1.009~3.4.1+dfsg-6 [119 kB] 173s Get:7 http://ftpmaster.internal/ubuntu resolute/main armhf fonts-mathjax all 2.7.9+dfsg-1build1 [2283 kB] 173s Get:8 http://ftpmaster.internal/ubuntu resolute/main armhf libdw1t64 armhf 0.194-1 [254 kB] 173s Get:9 http://ftpmaster.internal/ubuntu resolute/main armhf libbabeltrace1 armhf 1.5.11-5 [155 kB] 173s Get:10 http://ftpmaster.internal/ubuntu resolute/main armhf libdebuginfod1t64 armhf 0.194-1 [18.8 kB] 173s Get:11 http://ftpmaster.internal/ubuntu resolute/main armhf libpython3.14-stdlib armhf 3.14.2-1 [2270 kB] 173s Get:12 http://ftpmaster.internal/ubuntu resolute/main armhf libpython3.14 armhf 3.14.2-1 [2213 kB] 174s Get:13 http://ftpmaster.internal/ubuntu resolute/main armhf libsource-highlight-common all 3.1.9-4.3build2 [64.2 kB] 174s Get:14 http://ftpmaster.internal/ubuntu resolute/main armhf libsource-highlight4t64 armhf 3.1.9-4.3build2 [297 kB] 174s Get:15 http://ftpmaster.internal/ubuntu resolute/main armhf libc6-dbg armhf 2.42-2ubuntu4 [4516 kB] 174s Get:16 http://ftpmaster.internal/ubuntu resolute/main armhf gdb armhf 17.1-2ubuntu1 [3731 kB] 174s Get:17 http://ftpmaster.internal/ubuntu resolute/main armhf python3-platformdirs all 4.5.1-1 [17.1 kB] 174s Get:18 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-traitlets all 5.14.3+really5.14.3-2 [71.7 kB] 174s Get:19 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-jupyter-core all 5.9.1-1 [28.9 kB] 174s Get:20 http://ftpmaster.internal/ubuntu resolute/universe armhf jupyter-core all 5.9.1-1 [6938 B] 174s Get:21 http://ftpmaster.internal/ubuntu resolute-proposed/main armhf libjs-underscore all 1.13.7~dfsg+~1.13.0-6 [86.7 kB] 174s Get:22 http://ftpmaster.internal/ubuntu resolute/universe armhf libjs-backbone all 1.4.1~dfsg+~1.4.15-3build1 [186 kB] 174s Get:23 http://ftpmaster.internal/ubuntu resolute/universe armhf libjs-bootstrap all 3.4.1+dfsg-6 [129 kB] 174s Get:24 http://ftpmaster.internal/ubuntu resolute/main armhf libjs-jquery all 3.7.1+dfsg+~3.5.33-1build1 [321 kB] 174s Get:25 http://ftpmaster.internal/ubuntu resolute/universe armhf libjs-bootstrap-tour all 0.12.0+dfsg-6 [21.6 kB] 174s Get:26 http://ftpmaster.internal/ubuntu resolute/universe armhf libjs-codemirror all 5.65.20+~cs5.83.25-1 [710 kB] 174s Get:27 http://ftpmaster.internal/ubuntu resolute/universe armhf libjs-es6-promise all 4.2.8-12 [14.1 kB] 174s Get:28 http://ftpmaster.internal/ubuntu resolute/universe armhf node-jed all 1.1.1-4 [15.2 kB] 174s Get:29 http://ftpmaster.internal/ubuntu resolute/universe armhf libjs-jed all 1.1.1-4 [2584 B] 174s Get:30 http://ftpmaster.internal/ubuntu resolute/universe armhf libjs-jquery-typeahead all 2.11.0+dfsg1-3build1 [48.3 kB] 174s Get:31 http://ftpmaster.internal/ubuntu resolute/universe armhf libjs-jquery-ui all 1.13.2+dfsg-1build1 [251 kB] 174s Get:32 http://ftpmaster.internal/ubuntu resolute/universe armhf libjs-marked all 4.2.3+ds+~4.0.7-4 [36.2 kB] 174s Get:33 http://ftpmaster.internal/ubuntu resolute/main armhf libjs-mathjax all 2.7.9+dfsg-1build1 [6017 kB] 174s Get:34 http://ftpmaster.internal/ubuntu resolute/universe armhf libjs-moment all 2.29.4+ds-1 [147 kB] 174s Get:35 http://ftpmaster.internal/ubuntu resolute/universe armhf libjs-requirejs all 2.3.8+ds+~2.1.37-1 [201 kB] 174s Get:36 http://ftpmaster.internal/ubuntu resolute/universe armhf libjs-requirejs-text all 2.0.12-2 [9732 B] 174s Get:37 http://ftpmaster.internal/ubuntu resolute/universe armhf libjs-text-encoding all 0.7.0-5 [140 kB] 174s Get:38 http://ftpmaster.internal/ubuntu resolute/universe armhf libjs-xterm all 5.3.0-4 [475 kB] 174s Get:39 http://ftpmaster.internal/ubuntu resolute/main armhf python3-tornado armhf 6.5.4-0.1 [306 kB] 174s Get:40 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-terminado all 0.18.1-1 [13.2 kB] 174s Get:41 http://ftpmaster.internal/ubuntu resolute/main armhf libargon2-1 armhf 0~20190702+dfsg-5 [22.3 kB] 174s Get:42 http://ftpmaster.internal/ubuntu resolute/main armhf python3-ply all 3.11-10 [45.9 kB] 174s Get:43 http://ftpmaster.internal/ubuntu resolute/main armhf python3-pycparser all 2.23-2 [77.0 kB] 174s Get:44 http://ftpmaster.internal/ubuntu resolute/main armhf python3-cffi all 2.0.0-2 [75.5 kB] 174s Get:45 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-argon2-cffi-bindings armhf 25.1.0-2 [13.8 kB] 174s Get:46 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-argon2 armhf 25.1.0-2 [13.8 kB] 174s Get:47 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-comm all 0.2.1-1build1 [7148 B] 174s Get:48 http://ftpmaster.internal/ubuntu resolute/main armhf python3.14 armhf 3.14.2-1 [816 kB] 174s Get:49 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-coverage armhf 7.8.2+dfsg1-1ubuntu1 [158 kB] 174s Get:50 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-debugpy armhf 1.8.19+ds-1ubuntu1 [910 kB] 174s Get:51 http://ftpmaster.internal/ubuntu resolute/main armhf python3-decorator all 5.2.1-2 [28.1 kB] 174s Get:52 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-parso all 0.8.5-1 [68.0 kB] 174s Get:53 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-typeshed all 0.0~git20241223.ea91db2-4 [1554 kB] 174s Get:54 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-jedi all 0.19.1+ds1-1build1 [694 kB] 174s Get:55 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-matplotlib-inline all 0.2.1-1 [9462 B] 174s Get:56 http://ftpmaster.internal/ubuntu resolute/main armhf python3-wcwidth all 0.2.14+dfsg1-1build1 [26.5 kB] 174s Get:57 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-prompt-toolkit all 3.0.52-2 [258 kB] 174s Get:58 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-astroid all 4.0.2-1ubuntu1 [172 kB] 174s Get:59 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-asttokens all 3.0.1-1 [20.7 kB] 174s Get:60 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-executing all 2.2.1-0.1 [26.2 kB] 174s Get:61 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-pure-eval all 0.2.3-1 [11.4 kB] 174s Get:62 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-stack-data all 0.6.3-3 [22.2 kB] 174s Get:63 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-ipython all 8.35.0-2 [575 kB] 174s Get:64 http://ftpmaster.internal/ubuntu resolute/main armhf python3-psutil armhf 7.1.0-1ubuntu1 [189 kB] 175s Get:65 http://ftpmaster.internal/ubuntu resolute/universe armhf libnorm1t64 armhf 1.5.9+dfsg-4 [210 kB] 175s Get:66 http://ftpmaster.internal/ubuntu resolute/universe armhf libpgm-5.3-0t64 armhf 5.3.128~dfsg-2.1build2 [173 kB] 175s Get:67 http://ftpmaster.internal/ubuntu resolute/main armhf libsodium23 armhf 1.0.18-2 [141 kB] 175s Get:68 http://ftpmaster.internal/ubuntu resolute/universe armhf libzmq5 armhf 4.3.5-1build3 [271 kB] 175s Get:69 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-zmq armhf 27.1.0-1 [223 kB] 175s Get:70 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-jupyter-client all 8.7.0-1 [78.5 kB] 175s Get:71 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-nest-asyncio all 1.6.0-1 [6686 B] 175s Get:72 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-ipykernel all 6.30.1-1 [82.8 kB] 175s Get:73 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-ipython-genutils all 0.2.0-7 [22.0 kB] 175s Get:74 http://ftpmaster.internal/ubuntu resolute/universe armhf python-tinycss2-common all 1.5.1-1 [47.3 kB] 175s Get:75 http://ftpmaster.internal/ubuntu resolute/main armhf python3-webencodings all 0.5.1-5build1 [11.7 kB] 175s Get:76 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-tinycss2 all 1.5.1-1 [23.3 kB] 175s Get:77 http://ftpmaster.internal/ubuntu resolute/main armhf python3-html5lib all 1.2-3 [90.6 kB] 175s Get:78 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-bleach all 6.3.0-1 [44.2 kB] 175s Get:79 http://ftpmaster.internal/ubuntu resolute/main armhf python3-soupsieve all 2.8.3-1 [34.0 kB] 175s Get:80 http://ftpmaster.internal/ubuntu resolute/main armhf python3-bs4 all 4.14.3-2build1 [84.8 kB] 175s Get:81 http://ftpmaster.internal/ubuntu resolute/main armhf python3-defusedxml all 0.7.1-3build1 [42.4 kB] 175s Get:82 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-jupyterlab-pygments all 0.2.2-3build1 [6188 B] 175s Get:83 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-mistune all 3.1.4-1 [35.0 kB] 175s Get:84 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-fastjsonschema all 2.21.1-1 [20.4 kB] 175s Get:85 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-nbformat all 5.10.4-1 [39.2 kB] 175s Get:86 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-nbclient all 0.10.4-1 [22.6 kB] 175s Get:87 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-pandocfilters all 1.5.1-1 [23.6 kB] 175s Get:88 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-nbconvert all 7.16.6-1 [140 kB] 175s Get:89 http://ftpmaster.internal/ubuntu resolute/main armhf python3-prometheus-client all 0.21.1+ds1-1build1 [46.0 kB] 175s Get:90 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-send2trash all 1.8.3-1 [14.6 kB] 175s Get:91 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-notebook all 6.4.13-5ubuntu0.1 [1624 kB] 175s Get:92 http://ftpmaster.internal/ubuntu resolute/universe armhf jupyter-notebook all 6.4.13-5ubuntu0.1 [10.4 kB] 175s Get:93 http://ftpmaster.internal/ubuntu resolute/main armhf sphinx-rtd-theme-common all 3.0.2+dfsg-3 [1013 kB] 175s Get:94 http://ftpmaster.internal/ubuntu resolute/universe armhf python-notebook-doc all 6.4.13-5ubuntu0.1 [2545 kB] 175s Get:95 http://ftpmaster.internal/ubuntu resolute/main armhf python3-all armhf 3.13.9-3 [890 B] 175s Get:96 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-iniconfig all 2.1.0-2 [6962 B] 175s Get:97 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-pluggy all 1.6.0-2 [21.1 kB] 175s Get:98 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-pytest all 9.0.2-2 [277 kB] 175s Get:99 http://ftpmaster.internal/ubuntu resolute/universe armhf python3-requests-unixsocket all 1.0.1-1 [8620 B] 176s Preconfiguring packages ... 176s Fetched 44.8 MB in 3s (16.8 MB/s) 176s Selecting previously unselected package fonts-lato. 176s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 68395 files and directories currently installed.) 176s Preparing to unpack .../00-fonts-lato_2.015-1build1_all.deb ... 176s Unpacking fonts-lato (2.015-1build1) ... 176s Selecting previously unselected package libdebuginfod-common. 176s Preparing to unpack .../01-libdebuginfod-common_0.194-1_all.deb ... 176s Unpacking libdebuginfod-common (0.194-1) ... 176s Selecting previously unselected package libpython3.14-minimal:armhf. 176s Preparing to unpack .../02-libpython3.14-minimal_3.14.2-1_armhf.deb ... 176s Unpacking libpython3.14-minimal:armhf (3.14.2-1) ... 176s Selecting previously unselected package python3.14-minimal. 176s Preparing to unpack .../03-python3.14-minimal_3.14.2-1_armhf.deb ... 176s Unpacking python3.14-minimal (3.14.2-1) ... 176s Selecting previously unselected package fonts-font-awesome. 176s Preparing to unpack .../04-fonts-font-awesome_5.0.10+really4.7.0~dfsg-4.1build1_all.deb ... 176s Unpacking fonts-font-awesome (5.0.10+really4.7.0~dfsg-4.1build1) ... 176s Selecting previously unselected package fonts-glyphicons-halflings. 176s Preparing to unpack .../05-fonts-glyphicons-halflings_1.009~3.4.1+dfsg-6_all.deb ... 176s Unpacking fonts-glyphicons-halflings (1.009~3.4.1+dfsg-6) ... 176s Selecting previously unselected package fonts-mathjax. 176s Preparing to unpack .../06-fonts-mathjax_2.7.9+dfsg-1build1_all.deb ... 176s Unpacking fonts-mathjax (2.7.9+dfsg-1build1) ... 176s Selecting previously unselected package libdw1t64:armhf. 176s Preparing to unpack .../07-libdw1t64_0.194-1_armhf.deb ... 176s Unpacking libdw1t64:armhf (0.194-1) ... 176s Selecting previously unselected package libbabeltrace1:armhf. 176s Preparing to unpack .../08-libbabeltrace1_1.5.11-5_armhf.deb ... 176s Unpacking libbabeltrace1:armhf (1.5.11-5) ... 176s Selecting previously unselected package libdebuginfod1t64:armhf. 176s Preparing to unpack .../09-libdebuginfod1t64_0.194-1_armhf.deb ... 176s Unpacking libdebuginfod1t64:armhf (0.194-1) ... 176s Selecting previously unselected package libpython3.14-stdlib:armhf. 176s Preparing to unpack .../10-libpython3.14-stdlib_3.14.2-1_armhf.deb ... 176s Unpacking libpython3.14-stdlib:armhf (3.14.2-1) ... 177s Selecting previously unselected package libpython3.14:armhf. 177s Preparing to unpack .../11-libpython3.14_3.14.2-1_armhf.deb ... 177s Unpacking libpython3.14:armhf (3.14.2-1) ... 177s Selecting previously unselected package libsource-highlight-common. 177s Preparing to unpack .../12-libsource-highlight-common_3.1.9-4.3build2_all.deb ... 177s Unpacking libsource-highlight-common (3.1.9-4.3build2) ... 177s Selecting previously unselected package libsource-highlight4t64:armhf. 177s Preparing to unpack .../13-libsource-highlight4t64_3.1.9-4.3build2_armhf.deb ... 177s Unpacking libsource-highlight4t64:armhf (3.1.9-4.3build2) ... 177s Selecting previously unselected package libc6-dbg:armhf. 177s Preparing to unpack .../14-libc6-dbg_2.42-2ubuntu4_armhf.deb ... 177s Unpacking libc6-dbg:armhf (2.42-2ubuntu4) ... 177s Selecting previously unselected package gdb. 177s Preparing to unpack .../15-gdb_17.1-2ubuntu1_armhf.deb ... 177s Unpacking gdb (17.1-2ubuntu1) ... 177s Selecting previously unselected package python3-platformdirs. 177s Preparing to unpack .../16-python3-platformdirs_4.5.1-1_all.deb ... 177s Unpacking python3-platformdirs (4.5.1-1) ... 177s Selecting previously unselected package python3-traitlets. 177s Preparing to unpack .../17-python3-traitlets_5.14.3+really5.14.3-2_all.deb ... 177s Unpacking python3-traitlets (5.14.3+really5.14.3-2) ... 177s Selecting previously unselected package python3-jupyter-core. 177s Preparing to unpack .../18-python3-jupyter-core_5.9.1-1_all.deb ... 177s Unpacking python3-jupyter-core (5.9.1-1) ... 177s Selecting previously unselected package jupyter-core. 177s Preparing to unpack .../19-jupyter-core_5.9.1-1_all.deb ... 177s Unpacking jupyter-core (5.9.1-1) ... 177s Selecting previously unselected package libjs-underscore. 177s Preparing to unpack .../20-libjs-underscore_1.13.7~dfsg+~1.13.0-6_all.deb ... 177s Unpacking libjs-underscore (1.13.7~dfsg+~1.13.0-6) ... 177s Selecting previously unselected package libjs-backbone. 177s Preparing to unpack .../21-libjs-backbone_1.4.1~dfsg+~1.4.15-3build1_all.deb ... 177s Unpacking libjs-backbone (1.4.1~dfsg+~1.4.15-3build1) ... 177s Selecting previously unselected package libjs-bootstrap. 177s Preparing to unpack .../22-libjs-bootstrap_3.4.1+dfsg-6_all.deb ... 177s Unpacking libjs-bootstrap (3.4.1+dfsg-6) ... 177s Selecting previously unselected package libjs-jquery. 177s Preparing to unpack .../23-libjs-jquery_3.7.1+dfsg+~3.5.33-1build1_all.deb ... 177s Unpacking libjs-jquery (3.7.1+dfsg+~3.5.33-1build1) ... 177s Selecting previously unselected package libjs-bootstrap-tour. 177s Preparing to unpack .../24-libjs-bootstrap-tour_0.12.0+dfsg-6_all.deb ... 177s Unpacking libjs-bootstrap-tour (0.12.0+dfsg-6) ... 177s Selecting previously unselected package libjs-codemirror. 177s Preparing to unpack .../25-libjs-codemirror_5.65.20+~cs5.83.25-1_all.deb ... 177s Unpacking libjs-codemirror (5.65.20+~cs5.83.25-1) ... 177s Selecting previously unselected package libjs-es6-promise. 177s Preparing to unpack .../26-libjs-es6-promise_4.2.8-12_all.deb ... 177s Unpacking libjs-es6-promise (4.2.8-12) ... 177s Selecting previously unselected package node-jed. 177s Preparing to unpack .../27-node-jed_1.1.1-4_all.deb ... 177s Unpacking node-jed (1.1.1-4) ... 178s Selecting previously unselected package libjs-jed. 178s Preparing to unpack .../28-libjs-jed_1.1.1-4_all.deb ... 178s Unpacking libjs-jed (1.1.1-4) ... 178s Selecting previously unselected package libjs-jquery-typeahead. 178s Preparing to unpack .../29-libjs-jquery-typeahead_2.11.0+dfsg1-3build1_all.deb ... 178s Unpacking libjs-jquery-typeahead (2.11.0+dfsg1-3build1) ... 178s Selecting previously unselected package libjs-jquery-ui. 178s Preparing to unpack .../30-libjs-jquery-ui_1.13.2+dfsg-1build1_all.deb ... 178s Unpacking libjs-jquery-ui (1.13.2+dfsg-1build1) ... 178s Selecting previously unselected package libjs-marked. 178s Preparing to unpack .../31-libjs-marked_4.2.3+ds+~4.0.7-4_all.deb ... 178s Unpacking libjs-marked (4.2.3+ds+~4.0.7-4) ... 178s Selecting previously unselected package libjs-mathjax. 178s Preparing to unpack .../32-libjs-mathjax_2.7.9+dfsg-1build1_all.deb ... 178s Unpacking libjs-mathjax (2.7.9+dfsg-1build1) ... 178s Selecting previously unselected package libjs-moment. 178s Preparing to unpack .../33-libjs-moment_2.29.4+ds-1_all.deb ... 178s Unpacking libjs-moment (2.29.4+ds-1) ... 178s Selecting previously unselected package libjs-requirejs. 179s Preparing to unpack .../34-libjs-requirejs_2.3.8+ds+~2.1.37-1_all.deb ... 179s Unpacking libjs-requirejs (2.3.8+ds+~2.1.37-1) ... 179s Selecting previously unselected package libjs-requirejs-text. 179s Preparing to unpack .../35-libjs-requirejs-text_2.0.12-2_all.deb ... 179s Unpacking libjs-requirejs-text (2.0.12-2) ... 179s Selecting previously unselected package libjs-text-encoding. 179s Preparing to unpack .../36-libjs-text-encoding_0.7.0-5_all.deb ... 179s Unpacking libjs-text-encoding (0.7.0-5) ... 179s Selecting previously unselected package libjs-xterm. 179s Preparing to unpack .../37-libjs-xterm_5.3.0-4_all.deb ... 179s Unpacking libjs-xterm (5.3.0-4) ... 179s Selecting previously unselected package python3-tornado. 179s Preparing to unpack .../38-python3-tornado_6.5.4-0.1_armhf.deb ... 179s Unpacking python3-tornado (6.5.4-0.1) ... 179s Selecting previously unselected package python3-terminado. 179s Preparing to unpack .../39-python3-terminado_0.18.1-1_all.deb ... 179s Unpacking python3-terminado (0.18.1-1) ... 179s Selecting previously unselected package libargon2-1:armhf. 179s Preparing to unpack .../40-libargon2-1_0~20190702+dfsg-5_armhf.deb ... 179s Unpacking libargon2-1:armhf (0~20190702+dfsg-5) ... 179s Selecting previously unselected package python3-ply. 179s Preparing to unpack .../41-python3-ply_3.11-10_all.deb ... 179s Unpacking python3-ply (3.11-10) ... 179s Selecting previously unselected package python3-pycparser. 179s Preparing to unpack .../42-python3-pycparser_2.23-2_all.deb ... 179s Unpacking python3-pycparser (2.23-2) ... 179s Selecting previously unselected package python3-cffi. 179s Preparing to unpack .../43-python3-cffi_2.0.0-2_all.deb ... 179s Unpacking python3-cffi (2.0.0-2) ... 179s Selecting previously unselected package python3-argon2-cffi-bindings. 179s Preparing to unpack .../44-python3-argon2-cffi-bindings_25.1.0-2_armhf.deb ... 179s Unpacking python3-argon2-cffi-bindings (25.1.0-2) ... 179s Selecting previously unselected package python3-argon2. 179s Preparing to unpack .../45-python3-argon2_25.1.0-2_armhf.deb ... 179s Unpacking python3-argon2 (25.1.0-2) ... 179s Selecting previously unselected package python3-comm. 179s Preparing to unpack .../46-python3-comm_0.2.1-1build1_all.deb ... 179s Unpacking python3-comm (0.2.1-1build1) ... 179s Selecting previously unselected package python3.14. 179s Preparing to unpack .../47-python3.14_3.14.2-1_armhf.deb ... 179s Unpacking python3.14 (3.14.2-1) ... 179s Selecting previously unselected package python3-coverage. 179s Preparing to unpack .../48-python3-coverage_7.8.2+dfsg1-1ubuntu1_armhf.deb ... 179s Unpacking python3-coverage (7.8.2+dfsg1-1ubuntu1) ... 179s Selecting previously unselected package python3-debugpy. 179s Preparing to unpack .../49-python3-debugpy_1.8.19+ds-1ubuntu1_armhf.deb ... 179s Unpacking python3-debugpy (1.8.19+ds-1ubuntu1) ... 179s Selecting previously unselected package python3-decorator. 179s Preparing to unpack .../50-python3-decorator_5.2.1-2_all.deb ... 179s Unpacking python3-decorator (5.2.1-2) ... 179s Selecting previously unselected package python3-parso. 179s Preparing to unpack .../51-python3-parso_0.8.5-1_all.deb ... 179s Unpacking python3-parso (0.8.5-1) ... 179s Selecting previously unselected package python3-typeshed. 179s Preparing to unpack .../52-python3-typeshed_0.0~git20241223.ea91db2-4_all.deb ... 179s Unpacking python3-typeshed (0.0~git20241223.ea91db2-4) ... 180s Selecting previously unselected package python3-jedi. 180s Preparing to unpack .../53-python3-jedi_0.19.1+ds1-1build1_all.deb ... 180s Unpacking python3-jedi (0.19.1+ds1-1build1) ... 180s Selecting previously unselected package python3-matplotlib-inline. 180s Preparing to unpack .../54-python3-matplotlib-inline_0.2.1-1_all.deb ... 180s Unpacking python3-matplotlib-inline (0.2.1-1) ... 180s Selecting previously unselected package python3-wcwidth. 180s Preparing to unpack .../55-python3-wcwidth_0.2.14+dfsg1-1build1_all.deb ... 180s Unpacking python3-wcwidth (0.2.14+dfsg1-1build1) ... 180s Selecting previously unselected package python3-prompt-toolkit. 180s Preparing to unpack .../56-python3-prompt-toolkit_3.0.52-2_all.deb ... 180s Unpacking python3-prompt-toolkit (3.0.52-2) ... 181s Selecting previously unselected package python3-astroid. 181s Preparing to unpack .../57-python3-astroid_4.0.2-1ubuntu1_all.deb ... 181s Unpacking python3-astroid (4.0.2-1ubuntu1) ... 181s Selecting previously unselected package python3-asttokens. 181s Preparing to unpack .../58-python3-asttokens_3.0.1-1_all.deb ... 181s Unpacking python3-asttokens (3.0.1-1) ... 181s Selecting previously unselected package python3-executing. 181s Preparing to unpack .../59-python3-executing_2.2.1-0.1_all.deb ... 181s Unpacking python3-executing (2.2.1-0.1) ... 181s Selecting previously unselected package python3-pure-eval. 181s Preparing to unpack .../60-python3-pure-eval_0.2.3-1_all.deb ... 181s Unpacking python3-pure-eval (0.2.3-1) ... 181s Selecting previously unselected package python3-stack-data. 181s Preparing to unpack .../61-python3-stack-data_0.6.3-3_all.deb ... 181s Unpacking python3-stack-data (0.6.3-3) ... 181s Selecting previously unselected package python3-ipython. 181s Preparing to unpack .../62-python3-ipython_8.35.0-2_all.deb ... 181s Unpacking python3-ipython (8.35.0-2) ... 181s Selecting previously unselected package python3-psutil. 181s Preparing to unpack .../63-python3-psutil_7.1.0-1ubuntu1_armhf.deb ... 181s Unpacking python3-psutil (7.1.0-1ubuntu1) ... 181s Selecting previously unselected package libnorm1t64:armhf. 181s Preparing to unpack .../64-libnorm1t64_1.5.9+dfsg-4_armhf.deb ... 181s Unpacking libnorm1t64:armhf (1.5.9+dfsg-4) ... 181s Selecting previously unselected package libpgm-5.3-0t64:armhf. 181s Preparing to unpack .../65-libpgm-5.3-0t64_5.3.128~dfsg-2.1build2_armhf.deb ... 181s Unpacking libpgm-5.3-0t64:armhf (5.3.128~dfsg-2.1build2) ... 181s Selecting previously unselected package libsodium23:armhf. 181s Preparing to unpack .../66-libsodium23_1.0.18-2_armhf.deb ... 181s Unpacking libsodium23:armhf (1.0.18-2) ... 181s Selecting previously unselected package libzmq5:armhf. 181s Preparing to unpack .../67-libzmq5_4.3.5-1build3_armhf.deb ... 181s Unpacking libzmq5:armhf (4.3.5-1build3) ... 181s Selecting previously unselected package python3-zmq. 181s Preparing to unpack .../68-python3-zmq_27.1.0-1_armhf.deb ... 181s Unpacking python3-zmq (27.1.0-1) ... 181s Selecting previously unselected package python3-jupyter-client. 181s Preparing to unpack .../69-python3-jupyter-client_8.7.0-1_all.deb ... 181s Unpacking python3-jupyter-client (8.7.0-1) ... 181s Selecting previously unselected package python3-nest-asyncio. 181s Preparing to unpack .../70-python3-nest-asyncio_1.6.0-1_all.deb ... 181s Unpacking python3-nest-asyncio (1.6.0-1) ... 181s Selecting previously unselected package python3-ipykernel. 181s Preparing to unpack .../71-python3-ipykernel_6.30.1-1_all.deb ... 181s Unpacking python3-ipykernel (6.30.1-1) ... 181s Selecting previously unselected package python3-ipython-genutils. 181s Preparing to unpack .../72-python3-ipython-genutils_0.2.0-7_all.deb ... 181s Unpacking python3-ipython-genutils (0.2.0-7) ... 181s Selecting previously unselected package python-tinycss2-common. 181s Preparing to unpack .../73-python-tinycss2-common_1.5.1-1_all.deb ... 181s Unpacking python-tinycss2-common (1.5.1-1) ... 181s Selecting previously unselected package python3-webencodings. 181s Preparing to unpack .../74-python3-webencodings_0.5.1-5build1_all.deb ... 181s Unpacking python3-webencodings (0.5.1-5build1) ... 181s Selecting previously unselected package python3-tinycss2. 181s Preparing to unpack .../75-python3-tinycss2_1.5.1-1_all.deb ... 181s Unpacking python3-tinycss2 (1.5.1-1) ... 181s Selecting previously unselected package python3-html5lib. 181s Preparing to unpack .../76-python3-html5lib_1.2-3_all.deb ... 181s Unpacking python3-html5lib (1.2-3) ... 181s Selecting previously unselected package python3-bleach. 181s Preparing to unpack .../77-python3-bleach_6.3.0-1_all.deb ... 181s Unpacking python3-bleach (6.3.0-1) ... 181s Selecting previously unselected package python3-soupsieve. 181s Preparing to unpack .../78-python3-soupsieve_2.8.3-1_all.deb ... 181s Unpacking python3-soupsieve (2.8.3-1) ... 182s Selecting previously unselected package python3-bs4. 182s Preparing to unpack .../79-python3-bs4_4.14.3-2build1_all.deb ... 182s Unpacking python3-bs4 (4.14.3-2build1) ... 182s Selecting previously unselected package python3-defusedxml. 182s Preparing to unpack .../80-python3-defusedxml_0.7.1-3build1_all.deb ... 182s Unpacking python3-defusedxml (0.7.1-3build1) ... 182s Selecting previously unselected package python3-jupyterlab-pygments. 182s Preparing to unpack .../81-python3-jupyterlab-pygments_0.2.2-3build1_all.deb ... 182s Unpacking python3-jupyterlab-pygments (0.2.2-3build1) ... 182s Selecting previously unselected package python3-mistune. 182s Preparing to unpack .../82-python3-mistune_3.1.4-1_all.deb ... 182s Unpacking python3-mistune (3.1.4-1) ... 182s Selecting previously unselected package python3-fastjsonschema. 182s Preparing to unpack .../83-python3-fastjsonschema_2.21.1-1_all.deb ... 182s Unpacking python3-fastjsonschema (2.21.1-1) ... 182s Selecting previously unselected package python3-nbformat. 182s Preparing to unpack .../84-python3-nbformat_5.10.4-1_all.deb ... 182s Unpacking python3-nbformat (5.10.4-1) ... 182s Selecting previously unselected package python3-nbclient. 182s Preparing to unpack .../85-python3-nbclient_0.10.4-1_all.deb ... 182s Unpacking python3-nbclient (0.10.4-1) ... 182s Selecting previously unselected package python3-pandocfilters. 182s Preparing to unpack .../86-python3-pandocfilters_1.5.1-1_all.deb ... 182s Unpacking python3-pandocfilters (1.5.1-1) ... 182s Selecting previously unselected package python3-nbconvert. 182s Preparing to unpack .../87-python3-nbconvert_7.16.6-1_all.deb ... 182s Unpacking python3-nbconvert (7.16.6-1) ... 182s Selecting previously unselected package python3-prometheus-client. 182s Preparing to unpack .../88-python3-prometheus-client_0.21.1+ds1-1build1_all.deb ... 182s Unpacking python3-prometheus-client (0.21.1+ds1-1build1) ... 182s Selecting previously unselected package python3-send2trash. 182s Preparing to unpack .../89-python3-send2trash_1.8.3-1_all.deb ... 182s Unpacking python3-send2trash (1.8.3-1) ... 182s Selecting previously unselected package python3-notebook. 182s Preparing to unpack .../90-python3-notebook_6.4.13-5ubuntu0.1_all.deb ... 182s Unpacking python3-notebook (6.4.13-5ubuntu0.1) ... 182s Selecting previously unselected package jupyter-notebook. 182s Preparing to unpack .../91-jupyter-notebook_6.4.13-5ubuntu0.1_all.deb ... 182s Unpacking jupyter-notebook (6.4.13-5ubuntu0.1) ... 182s Selecting previously unselected package sphinx-rtd-theme-common. 182s Preparing to unpack .../92-sphinx-rtd-theme-common_3.0.2+dfsg-3_all.deb ... 182s Unpacking sphinx-rtd-theme-common (3.0.2+dfsg-3) ... 182s Selecting previously unselected package python-notebook-doc. 182s Preparing to unpack .../93-python-notebook-doc_6.4.13-5ubuntu0.1_all.deb ... 182s Unpacking python-notebook-doc (6.4.13-5ubuntu0.1) ... 182s Selecting previously unselected package python3-all. 182s Preparing to unpack .../94-python3-all_3.13.9-3_armhf.deb ... 182s Unpacking python3-all (3.13.9-3) ... 182s Selecting previously unselected package python3-iniconfig. 182s Preparing to unpack .../95-python3-iniconfig_2.1.0-2_all.deb ... 182s Unpacking python3-iniconfig (2.1.0-2) ... 182s Selecting previously unselected package python3-pluggy. 182s Preparing to unpack .../96-python3-pluggy_1.6.0-2_all.deb ... 182s Unpacking python3-pluggy (1.6.0-2) ... 182s Selecting previously unselected package python3-pytest. 182s Preparing to unpack .../97-python3-pytest_9.0.2-2_all.deb ... 182s Unpacking python3-pytest (9.0.2-2) ... 183s Selecting previously unselected package python3-requests-unixsocket. 183s Preparing to unpack .../98-python3-requests-unixsocket_1.0.1-1_all.deb ... 183s Unpacking python3-requests-unixsocket (1.0.1-1) ... 183s Setting up libjs-jquery-typeahead (2.11.0+dfsg1-3build1) ... 183s Setting up python3-iniconfig (2.1.0-2) ... 183s Setting up python3-tornado (6.5.4-0.1) ... 184s Setting up libnorm1t64:armhf (1.5.9+dfsg-4) ... 184s Setting up python3-pure-eval (0.2.3-1) ... 185s Setting up python3-send2trash (1.8.3-1) ... 185s Setting up fonts-lato (2.015-1build1) ... 185s Setting up fonts-mathjax (2.7.9+dfsg-1build1) ... 185s Setting up libsodium23:armhf (1.0.18-2) ... 185s Setting up libjs-mathjax (2.7.9+dfsg-1build1) ... 185s Setting up libdebuginfod-common (0.194-1) ... 185s Setting up libjs-requirejs-text (2.0.12-2) ... 185s Setting up python3-parso (0.8.5-1) ... 185s Setting up python3-defusedxml (0.7.1-3build1) ... 185s Setting up python3-ipython-genutils (0.2.0-7) ... 186s Setting up fonts-glyphicons-halflings (1.009~3.4.1+dfsg-6) ... 186s Setting up libargon2-1:armhf (0~20190702+dfsg-5) ... 186s Setting up python3-ply (3.11-10) ... 186s Setting up libpython3.14-minimal:armhf (3.14.2-1) ... 186s Setting up libjs-moment (2.29.4+ds-1) ... 186s Setting up python3-pandocfilters (1.5.1-1) ... 186s Setting up libjs-requirejs (2.3.8+ds+~2.1.37-1) ... 186s Setting up libjs-es6-promise (4.2.8-12) ... 186s Setting up libjs-text-encoding (0.7.0-5) ... 186s Setting up python3-webencodings (0.5.1-5build1) ... 186s Setting up python3-platformdirs (4.5.1-1) ... 187s Setting up python3-psutil (7.1.0-1ubuntu1) ... 187s Setting up libsource-highlight-common (3.1.9-4.3build2) ... 187s Setting up python3-pycparser (2.23-2) ... 188s Setting up libc6-dbg:armhf (2.42-2ubuntu4) ... 188s Setting up libdw1t64:armhf (0.194-1) ... 188s Setting up python3-requests-unixsocket (1.0.1-1) ... 188s Setting up python3-jupyterlab-pygments (0.2.2-3build1) ... 188s Setting up libpgm-5.3-0t64:armhf (5.3.128~dfsg-2.1build2) ... 188s Setting up python3-decorator (5.2.1-2) ... 188s Setting up python3-wcwidth (0.2.14+dfsg1-1build1) ... 189s Setting up node-jed (1.1.1-4) ... 189s Setting up python3-typeshed (0.0~git20241223.ea91db2-4) ... 189s Setting up libjs-xterm (5.3.0-4) ... 189s Setting up python3-nest-asyncio (1.6.0-1) ... 189s Setting up libjs-codemirror (5.65.20+~cs5.83.25-1) ... 189s Setting up libjs-jed (1.1.1-4) ... 189s Setting up python3-html5lib (1.2-3) ... 189s Setting up libbabeltrace1:armhf (1.5.11-5) ... 189s Setting up python3-pluggy (1.6.0-2) ... 190s Setting up python3-fastjsonschema (2.21.1-1) ... 190s Setting up python3-terminado (0.18.1-1) ... 190s Setting up python3-astroid (4.0.2-1ubuntu1) ... 191s Setting up python3-traitlets (5.14.3+really5.14.3-2) ... 191s Setting up python-tinycss2-common (1.5.1-1) ... 191s Setting up libjs-jquery (3.7.1+dfsg+~3.5.33-1build1) ... 191s Setting up python3-mistune (3.1.4-1) ... 191s Setting up python3-soupsieve (2.8.3-1) ... 191s Setting up fonts-font-awesome (5.0.10+really4.7.0~dfsg-4.1build1) ... 191s Setting up sphinx-rtd-theme-common (3.0.2+dfsg-3) ... 191s Setting up python3.14-minimal (3.14.2-1) ... 193s Setting up python3-jupyter-core (5.9.1-1) ... 193s Setting up libjs-bootstrap (3.4.1+dfsg-6) ... 193s Setting up libjs-underscore (1.13.7~dfsg+~1.13.0-6) ... 193s Setting up libjs-marked (4.2.3+ds+~4.0.7-4) ... 193s Setting up python3-prompt-toolkit (3.0.52-2) ... 194s Setting up libdebuginfod1t64:armhf (0.194-1) ... 194s Setting up python3-tinycss2 (1.5.1-1) ... 194s Setting up libzmq5:armhf (4.3.5-1build3) ... 194s Setting up python3-jedi (0.19.1+ds1-1build1) ... 194s Setting up libpython3.14-stdlib:armhf (3.14.2-1) ... 194s Setting up python3-asttokens (3.0.1-1) ... 195s Setting up python3-pytest (9.0.2-2) ... 195s Setting up python3-cffi (2.0.0-2) ... 196s Setting up libjs-bootstrap-tour (0.12.0+dfsg-6) ... 196s Setting up libjs-backbone (1.4.1~dfsg+~1.4.15-3build1) ... 196s Setting up libsource-highlight4t64:armhf (3.1.9-4.3build2) ... 196s Setting up python3-nbformat (5.10.4-1) ... 196s Setting up python-notebook-doc (6.4.13-5ubuntu0.1) ... 196s Setting up python3-bs4 (4.14.3-2build1) ... 196s Setting up python3-bleach (6.3.0-1) ... 197s Setting up python3-matplotlib-inline (0.2.1-1) ... 197s Setting up python3-comm (0.2.1-1build1) ... 197s Setting up python3-prometheus-client (0.21.1+ds1-1build1) ... 198s Setting up libjs-jquery-ui (1.13.2+dfsg-1build1) ... 198s Setting up python3-executing (2.2.1-0.1) ... 198s Setting up python3-zmq (27.1.0-1) ... 198s Setting up python3-argon2-cffi-bindings (25.1.0-2) ... 199s Setting up python3-argon2 (25.1.0-2) ... 199s Setting up libpython3.14:armhf (3.14.2-1) ... 199s Setting up python3-jupyter-client (8.7.0-1) ... 199s Setting up jupyter-core (5.9.1-1) ... 199s Setting up python3.14 (3.14.2-1) ... 201s Setting up python3-stack-data (0.6.3-3) ... 201s Setting up python3-all (3.13.9-3) ... 201s Setting up python3-coverage (7.8.2+dfsg1-1ubuntu1) ... 202s Setting up python3-nbclient (0.10.4-1) ... 202s Setting up gdb (17.1-2ubuntu1) ... 202s Setting up python3-ipython (8.35.0-2) ... 202s /usr/lib/python3/dist-packages/IPython/core/interactiveshell.py:3141: SyntaxWarning: 'return' in a 'finally' block 202s return result 203s Setting up python3-nbconvert (7.16.6-1) ... 204s Setting up python3-debugpy (1.8.19+ds-1ubuntu1) ... 205s Setting up python3-ipykernel (6.30.1-1) ... 205s Setting up python3-notebook (6.4.13-5ubuntu0.1) ... 206s Setting up jupyter-notebook (6.4.13-5ubuntu0.1) ... 206s Processing triggers for systemd (259-1ubuntu3) ... 206s Processing triggers for man-db (2.13.1-1) ... 207s Processing triggers for libc-bin (2.42-2ubuntu4) ... 219s autopkgtest [04:18:12]: test pytest: [----------------------- 221s Testing with python3.14 221s *** STARTING RUN 1: python3.14 -m pytest --pyargs notebook -rsfE --ignore=/usr/lib/python3/dist-packages/notebook/tests/selenium --deselect=services/kernels/tests/test_kernels_api.py::KernelAPITest::test_connections 225s ============================= test session starts ============================== 225s platform linux -- Python 3.14.2, pytest-9.0.2, pluggy-1.6.0 225s rootdir: /tmp/autopkgtest.d1RsUl/autopkgtest_tmp 225s plugins: typeguard-4.4.4 225s collected 330 items / 6 deselected / 324 selected 225s 226s auth/tests/test_login.py .. [ 0%] 227s auth/tests/test_security.py .... [ 1%] 227s bundler/tests/test_bundler_api.py ..... [ 3%] 227s bundler/tests/test_bundler_tools.py ............. [ 7%] 227s bundler/tests/test_bundlerextension.py ... [ 8%] 227s nbconvert/tests/test_nbconvert_handlers.py ssssss [ 10%] 227s services/api/tests/test_api.py ... [ 11%] 227s services/config/tests/test_config_api.py ... [ 12%] 228s services/contents/tests/test_contents_api.py .s..........ss..s.......... [ 20%] 230s ................s...........ss..s......................... [ 38%] 230s services/contents/tests/test_fileio.py ... [ 39%] 230s services/contents/tests/test_largefilemanager.py . [ 39%] 231s services/contents/tests/test_manager.py .....s........ss..........ss.... [ 49%] 231s .... [ 50%] 242s services/kernels/tests/test_kernels_api.py FFFEFFFFFEF.. [ 54%] 242s services/kernelspecs/tests/test_kernelspecs_api.py ....... [ 56%] 243s services/nbconvert/tests/test_nbconvert_api.py . [ 56%] 243s services/sessions/tests/test_sessionmanager.py ......... [ 59%] 245s services/sessions/tests/test_sessions_api.py FFFFFE.FEFE.FFFFFFFE.FEFE.F [ 65%] 245s F [ 66%] 249s terminal/tests/test_terminals_api.py ........ [ 68%] 249s tests/test_config_manager.py . [ 68%] 249s tests/test_files.py ..... [ 70%] 250s tests/test_gateway.py ...... [ 72%] 250s tests/test_i18n.py . [ 72%] 250s tests/test_log.py . [ 72%] 251s tests/test_nbextensions.py ................................... [ 83%] 252s tests/test_notebookapp.py .......................... [ 91%] 252s tests/test_paths.py ... [ 92%] 252s tests/test_serialize.py .. [ 93%] 253s tests/test_serverextensions.py ..... [ 94%] 253s tests/test_traittypes.py ........... [ 98%] 255s tests/test_utils.py ....s [ 99%] 255s tree/tests/test_tree_handler.py . [100%] 255s 255s ==================================== ERRORS ==================================== 255s _________ ERROR at teardown of KernelAPITest.test_main_kernel_handler __________ 255s 255s self = 255s 255s def tearDown(self): 255s for k in self.kern_api.list().json(): 255s > self.kern_api.shutdown(k['id']) 255s 255s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 255s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 255s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 255s return self._req('DELETE', id) 255s ^^^^^^^^^^^^^^^^^^^^^^^ 255s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 255s response.raise_for_status() 255s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 255s 255s self = 255s 255s def raise_for_status(self): 255s """Raises :class:`HTTPError`, if one occurred.""" 255s 255s http_error_msg = "" 255s if isinstance(self.reason, bytes): 255s # We attempt to decode utf-8 first because some servers 255s # choose to localize their reason strings. If the string 255s # isn't utf-8, we fall back to iso-8859-1 for all other 255s # encodings. (See PR #3538) 255s try: 255s reason = self.reason.decode("utf-8") 255s except UnicodeDecodeError: 255s reason = self.reason.decode("iso-8859-1") 255s else: 255s reason = self.reason 255s 255s if 400 <= self.status_code < 500: 255s http_error_msg = ( 255s f"{self.status_code} Client Error: {reason} for url: {self.url}" 255s ) 255s 255s elif 500 <= self.status_code < 600: 255s http_error_msg = ( 255s f"{self.status_code} Server Error: {reason} for url: {self.url}" 255s ) 255s 255s if http_error_msg: 255s > raise HTTPError(http_error_msg, response=self) 255s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/1514df78-fcee-4a38-a2ba-d1a4dd9782a2 255s 255s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 255s ----------------------------- Captured stderr call ----------------------------- 255s Traceback (most recent call last): 255s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 255s return _run_code(code, main_globals, None, 255s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 255s exec(code, run_globals) 255s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 255s from pathlib import Path 255s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 255s from ._abc import * 255s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 255s from glob import _Globber, _no_recurse_symlinks 255s File "/usr/lib/python3.13/glob.py", line 5, in 255s import re 255s File "/usr/lib/python3.13/re/__init__.py", line 125, in 255s import enum 255s File "", line 1360, in _find_and_load 255s File "", line 1331, in _find_and_load_unlocked 255s File "", line 935, in _load_unlocked 255s File "", line 1019, in exec_module 255s File "", line 1109, in get_code 255s File "", line 1232, in path_stats 255s File "", line 152, in _path_stat 255s KeyboardInterrupt 255s Traceback (most recent call last): 255s ------------------------------ Captured log call ------------------------------- 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 255s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpqmf_w3ur/runtime/kernel-1514df78-fcee-4a38-a2ba-d1a4dd9782a2.json'] 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:51361 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:48699 255s INFO NotebookApp:kernelmanager.py:179 Kernel started: 1514df78-fcee-4a38-a2ba-d1a4dd9782a2, name: python3 255s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 255s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 20.460000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.910000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 255s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpqmf_w3ur/runtime/kernel-deb0785e-9fab-49f7-9c85-dffba3702952.json'] 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55871 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:50073 255s INFO NotebookApp:kernelmanager.py:179 Kernel started: deb0785e-9fab-49f7-9c85-dffba3702952, name: python3 255s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 255s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.950000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.360000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: deb0785e-9fab-49f7-9c85-dffba3702952 255s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/deb0785e-9fab-49f7-9c85-dffba3702952/interrupt (127.0.0.1) 1.700000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 255s yield maybe_future(km.restart_kernel(kernel_id)) 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 255s value = future.result() 255s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 255s raise self._exception.with_traceback(self._exception_tb) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 255s result = coro.send(None) 255s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 255s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 255s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 255s return _runner_map[name].run(inner) 255s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 255s return fut.result(None) 255s ~~~~~~~~~~^^^^^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 255s return self.__get_result() 255s ~~~~~~~~~~~~~~~~~^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 255s raise self._exception 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 255s result = coro.send(None) 255s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 255s await ensure_async(kernel.restart_kernel(now=now)) 255s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 255s return _runner_map[name].run(inner) 255s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 255s return fut.result(None) 255s ~~~~~~~~~~^^^^^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 255s return self.__get_result() 255s ~~~~~~~~~~~~~~~~~^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 255s raise self._exception 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 255s result = coro.send(None) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 255s await self._async_shutdown_kernel(now=now, restart=True) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 255s raise e 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s ERROR NotebookApp:log.py:55 { 255s "Host": "localhost:12341", 255s "Accept": "*/*", 255s "User-Agent": "python-requests/2.32.5" 255s } 255s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/deb0785e-9fab-49f7-9c85-dffba3702952/restart (127.0.0.1) 5.440000ms referer=None 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.920000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 1514df78-fcee-4a38-a2ba-d1a4dd9782a2 255s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 1514df78-fcee-4a38-a2ba-d1a4dd9782a2 255s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/1514df78-fcee-4a38-a2ba-d1a4dd9782a2 (127.0.0.1) 255s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/1514df78-fcee-4a38-a2ba-d1a4dd9782a2', version='HTTP/1.1', remote_ip='127.0.0.1') 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 255s result = await result 255s ^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 255s yielded = ctx_run(next, result) 255s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 255s yield maybe_future(km.shutdown_kernel(kernel_id)) 255s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 255s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 255s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 255s return _runner_map[name].run(inner) 255s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 255s return fut.result(None) 255s ~~~~~~~~~~^^^^^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 255s return self.__get_result() 255s ~~~~~~~~~~~~~~~~~^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 255s raise self._exception 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 255s result = coro.send(None) 255s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 255s stopper = ensure_async(km.shutdown_kernel(now, restart)) 255s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 255s return _runner_map[name].run(inner) 255s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 255s return fut.result(None) 255s ~~~~~~~~~~^^^^^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 255s return self.__get_result() 255s ~~~~~~~~~~~~~~~~~^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 255s raise self._exception 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 255s result = coro.send(None) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 255s raise e 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s WARNING NotebookApp:handlers.py:612 Unhandled error 255s ERROR NotebookApp:log.py:55 { 255s "Host": "localhost:12341", 255s "Accept": "*/*", 255s "User-Agent": "python-requests/2.32.5" 255s } 255s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/1514df78-fcee-4a38-a2ba-d1a4dd9782a2 (127.0.0.1) 7.800000ms referer=None 255s --------------------------- Captured stderr teardown --------------------------- 255s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 255s return _run_code(code, main_globals, None, 255s "__main__", mod_spec) 255s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 255s exec(code, run_globals) 255s ~~~~^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 255s from ipykernel import kernelapp as app 255s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 255s from .connect import * # noqa: F403 255s ^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 12, in 255s import jupyter_client 255s File "/usr/lib/python3/dist-packages/jupyter_client/__init__.py", line 4, in 255s from .asynchronous import AsyncKernelClient 255s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/__init__.py", line 1, in 255s from .client import AsyncKernelClient # noqa 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/client.py", line 9, in 255s import zmq.asyncio 255s File "/usr/lib/python3/dist-packages/zmq/asyncio.py", line 10, in 255s import asyncio 255s File "/usr/lib/python3.13/asyncio/__init__.py", line 8, in 255s from .base_events import * 255s File "/usr/lib/python3.13/asyncio/base_events.py", line 18, in 255s import concurrent.futures 255s File "/usr/lib/python3.13/concurrent/futures/__init__.py", line 8, in 255s from concurrent.futures._base import (FIRST_COMPLETED, 255s ...<9 lines>... 255s as_completed) 255s File "", line 1360, in _find_and_load 255s File "", line 1331, in _find_and_load_unlocked 255s File "", line 935, in _load_unlocked 255s File "", line 1019, in exec_module 255s File "", line 1152, in get_code 255s File "", line 783, in _compile_bytecode 255s File "", line 491, in _verbose_message 255s KeyboardInterrupt 255s _______ ERROR at teardown of AsyncKernelAPITest.test_main_kernel_handler _______ 255s 255s self = 255s 255s def tearDown(self): 255s for k in self.kern_api.list().json(): 255s > self.kern_api.shutdown(k['id']) 255s 255s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 255s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 255s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 255s return self._req('DELETE', id) 255s ^^^^^^^^^^^^^^^^^^^^^^^ 255s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 255s response.raise_for_status() 255s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 255s 255s self = 255s 255s def raise_for_status(self): 255s """Raises :class:`HTTPError`, if one occurred.""" 255s 255s http_error_msg = "" 255s if isinstance(self.reason, bytes): 255s # We attempt to decode utf-8 first because some servers 255s # choose to localize their reason strings. If the string 255s # isn't utf-8, we fall back to iso-8859-1 for all other 255s # encodings. (See PR #3538) 255s try: 255s reason = self.reason.decode("utf-8") 255s except UnicodeDecodeError: 255s reason = self.reason.decode("iso-8859-1") 255s else: 255s reason = self.reason 255s 255s if 400 <= self.status_code < 500: 255s http_error_msg = ( 255s f"{self.status_code} Client Error: {reason} for url: {self.url}" 255s ) 255s 255s elif 500 <= self.status_code < 600: 255s http_error_msg = ( 255s f"{self.status_code} Server Error: {reason} for url: {self.url}" 255s ) 255s 255s if http_error_msg: 255s > raise HTTPError(http_error_msg, response=self) 255s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/2ea1ef69-cbb2-4d40-a91e-e687bd997cc0 255s 255s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 255s ----------------------------- Captured stderr call ----------------------------- 255s Traceback (most recent call last): 255s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 255s return _run_code(code, main_globals, None, 255s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 255s exec(code, run_globals) 255s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 255s from pathlib import Path 255s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 255s from ._abc import * 255s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 255s from glob import _Globber, _no_recurse_symlinks 255s File "/usr/lib/python3.13/glob.py", line 3, in 255s import contextlib 255s File "", line 1360, in _find_and_load 255s File "", line 1331, in _find_and_load_unlocked 255s File "", line 935, in _load_unlocked 255s File "", line 1019, in exec_module 255s File "", line 1115, in get_code 255s File "", line 1214, in get_data 255s KeyboardInterrupt 255s Traceback (most recent call last): 255s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 255s return _run_code(code, main_globals, None, 255s "__main__", mod_spec) 255s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 255s exec(code, run_globals) 255s ~~~~^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 255s from ipykernel import kernelapp as app 255s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 255s from .connect import * # noqa: F403 255s ^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 12, in 255s import jupyter_client 255s File "/usr/lib/python3/dist-packages/jupyter_client/__init__.py", line 4, in 255s from .asynchronous import AsyncKernelClient 255s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/__init__.py", line 1, in 255s from .client import AsyncKernelClient # noqa 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/client.py", line 9, in 255s import zmq.asyncio 255s File "/usr/lib/python3/dist-packages/zmq/__init__.py", line 86, in 255s DRAFT_API: bool = backend.has('draft') and backend.PYZMQ_DRAFT_API 255s ~~~~~~~~~~~^^^^^^^^^ 255s File "_zmq.py", line 1547, in zmq.backend.cython._zmq.has 255s File "/usr/lib/python3/dist-packages/zmq/error.py", line 211, in _check_version 255s from zmq import zmq_version_info 255s File "", line 471, in _lock_unlock_module 255s File "", line 316, in acquire 255s KeyboardInterrupt 255s ------------------------------ Captured log call ------------------------------- 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 255s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp0lmkbuy5/runtime/kernel-2ea1ef69-cbb2-4d40-a91e-e687bd997cc0.json'] 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55023 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:38821 255s INFO NotebookApp:kernelmanager.py:179 Kernel started: 2ea1ef69-cbb2-4d40-a91e-e687bd997cc0, name: python3 255s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 255s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.390000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.060000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 255s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp0lmkbuy5/runtime/kernel-20811980-e7dc-40fa-9b87-cf7b007f7afe.json'] 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34677 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:57761 255s INFO NotebookApp:kernelmanager.py:179 Kernel started: 20811980-e7dc-40fa-9b87-cf7b007f7afe, name: python3 255s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 255s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.720000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.980000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: 20811980-e7dc-40fa-9b87-cf7b007f7afe 255s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/20811980-e7dc-40fa-9b87-cf7b007f7afe/interrupt (127.0.0.1) 1.150000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 255s yield maybe_future(km.restart_kernel(kernel_id)) 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 255s value = future.result() 255s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 255s raise self._exception.with_traceback(self._exception_tb) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 291, in __step_run_and_handle_result 255s result = coro.throw(exc) 255s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 255s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 255s File "/usr/lib/python3.14/asyncio/futures.py", line 295, in __await__ 255s yield self # This tells Task to wait for completion. 255s ^^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 255s future.result() 255s ~~~~~~~~~~~~~^^ 255s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 255s raise self._exception.with_traceback(self._exception_tb) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 255s result = coro.send(None) 255s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 255s await ensure_async(kernel.restart_kernel(now=now)) 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 255s result = await obj 255s ^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 255s await self._async_shutdown_kernel(now=now, restart=True) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 255s raise e 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s ERROR NotebookApp:log.py:55 { 255s "Host": "localhost:12341", 255s "Accept": "*/*", 255s "User-Agent": "python-requests/2.32.5" 255s } 255s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/20811980-e7dc-40fa-9b87-cf7b007f7afe/restart (127.0.0.1) 4.180000ms referer=None 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.020000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 2ea1ef69-cbb2-4d40-a91e-e687bd997cc0 255s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 2ea1ef69-cbb2-4d40-a91e-e687bd997cc0 255s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 255s await kernel_awaitable 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 255s result = await obj 255s ^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 255s raise e 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/2ea1ef69-cbb2-4d40-a91e-e687bd997cc0 (127.0.0.1) 255s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/2ea1ef69-cbb2-4d40-a91e-e687bd997cc0', version='HTTP/1.1', remote_ip='127.0.0.1') 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 255s result = await result 255s ^^^^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 255s future.result() 255s ~~~~~~~~~~~~~^^ 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 255s yielded = self.gen.throw(exc) 255s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 255s yield maybe_future(km.shutdown_kernel(kernel_id)) 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 255s value = future.result() 255s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 255s raise self._exception.with_traceback(self._exception_tb) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 255s result = coro.send(None) 255s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 255s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 255s raise km.ready.exception() # type: ignore[misc] 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 255s await kernel_awaitable 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 255s result = await obj 255s ^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 255s raise e 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s WARNING NotebookApp:handlers.py:612 Unhandled error 255s ERROR NotebookApp:log.py:55 { 255s "Host": "localhost:12341", 255s "Accept": "*/*", 255s "User-Agent": "python-requests/2.32.5" 255s } 255s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/2ea1ef69-cbb2-4d40-a91e-e687bd997cc0 (127.0.0.1) 7.420000ms referer=None 255s ________ ERROR at teardown of SessionAPITest.test_create_with_kernel_id ________ 255s 255s @self.addCleanup 255s def cleanup_sessions(): 255s for session in self.sess_api.list().json(): 255s > self.sess_api.delete(session['id']) 255s 255s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 255s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 255s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 255s return self._req('DELETE', id) 255s ^^^^^^^^^^^^^^^^^^^^^^^ 255s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 255s response.raise_for_status() 255s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 255s 255s self = 255s 255s def raise_for_status(self): 255s """Raises :class:`HTTPError`, if one occurred.""" 255s 255s http_error_msg = "" 255s if isinstance(self.reason, bytes): 255s # We attempt to decode utf-8 first because some servers 255s # choose to localize their reason strings. If the string 255s # isn't utf-8, we fall back to iso-8859-1 for all other 255s # encodings. (See PR #3538) 255s try: 255s reason = self.reason.decode("utf-8") 255s except UnicodeDecodeError: 255s reason = self.reason.decode("iso-8859-1") 255s else: 255s reason = self.reason 255s 255s if 400 <= self.status_code < 500: 255s http_error_msg = ( 255s f"{self.status_code} Client Error: {reason} for url: {self.url}" 255s ) 255s 255s elif 500 <= self.status_code < 600: 255s http_error_msg = ( 255s f"{self.status_code} Server Error: {reason} for url: {self.url}" 255s ) 255s 255s if http_error_msg: 255s > raise HTTPError(http_error_msg, response=self) 255s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/4246b68b-5a59-44db-86c7-b7b154cf3598 255s 255s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 255s ----------------------------- Captured stderr call ----------------------------- 255s Traceback (most recent call last): 255s ------------------------------ Captured log call ------------------------------- 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 255s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcqkf_mv7/runtime/kernel-d6da1137-69f4-47f6-bb7e-c7be59058439.json'] 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:39185 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34491 255s INFO NotebookApp:kernelmanager.py:179 Kernel started: d6da1137-69f4-47f6-bb7e-c7be59058439, name: python3 255s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 255s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 27.480000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.120000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.030000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.060000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 812bee6b-f1a7-46ab-a9bc-f71801c62b45 255s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 812bee6b-f1a7-46ab-a9bc-f71801c62b45 255s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/5b494814-58d8-4639-aca2-5796c23fb81a (127.0.0.1) 1.450000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for d6da1137-69f4-47f6-bb7e-c7be59058439 255s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: d6da1137-69f4-47f6-bb7e-c7be59058439 255s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/4246b68b-5a59-44db-86c7-b7b154cf3598 (127.0.0.1) 255s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/4246b68b-5a59-44db-86c7-b7b154cf3598', version='HTTP/1.1', remote_ip='127.0.0.1') 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 255s result = await result 255s ^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 255s yielded = self.gen.throw(exc) 255s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 255s yield maybe_future(sm.delete_session(session_id)) 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 255s value = future.result() 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 255s yielded = self.gen.send(value) 255s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 255s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 255s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 255s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 255s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 255s return _runner_map[name].run(inner) 255s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 255s return fut.result(None) 255s ~~~~~~~~~~^^^^^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 255s return self.__get_result() 255s ~~~~~~~~~~~~~~~~~^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 255s raise self._exception 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 255s result = coro.send(None) 255s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 255s stopper = ensure_async(km.shutdown_kernel(now, restart)) 255s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 255s return _runner_map[name].run(inner) 255s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 255s return fut.result(None) 255s ~~~~~~~~~~^^^^^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 255s return self.__get_result() 255s ~~~~~~~~~~~~~~~~~^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 255s raise self._exception 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 255s result = coro.send(None) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 255s raise e 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s WARNING NotebookApp:handlers.py:612 Unhandled error 255s ERROR NotebookApp:log.py:55 { 255s "Host": "localhost:12341", 255s "Accept": "*/*", 255s "User-Agent": "python-requests/2.32.5" 255s } 255s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/4246b68b-5a59-44db-86c7-b7b154cf3598 (127.0.0.1) 8.570000ms referer=None 255s --------------------------- Captured stderr teardown --------------------------- 255s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 255s return _run_code(code, main_globals, None, 255s "__main__", mod_spec) 255s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 255s exec(code, run_globals) 255s ~~~~^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 255s from ipykernel import kernelapp as app 255s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 255s from .connect import * # noqa: F403 255s ^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 9, in 255s from subprocess import PIPE, Popen 255s File "/usr/lib/python3.13/subprocess.py", line 51, in 255s import threading 255s File "/usr/lib/python3.13/threading.py", line 9, in 255s from _weakrefset import WeakSet 255s File "", line 1360, in _find_and_load 255s File "", line 1322, in _find_and_load_unlocked 255s File "", line 1262, in _find_spec 255s File "", line 1556, in find_spec 255s File "", line 1530, in _get_spec 255s File "", line 1629, in find_spec 255s File "", line 152, in _path_stat 255s KeyboardInterrupt 255s __________ ERROR at teardown of SessionAPITest.test_modify_kernel_id ___________ 255s 255s @self.addCleanup 255s def cleanup_sessions(): 255s for session in self.sess_api.list().json(): 255s > self.sess_api.delete(session['id']) 255s 255s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 255s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 255s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 255s return self._req('DELETE', id) 255s ^^^^^^^^^^^^^^^^^^^^^^^ 255s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 255s response.raise_for_status() 255s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 255s 255s self = 255s 255s def raise_for_status(self): 255s """Raises :class:`HTTPError`, if one occurred.""" 255s 255s http_error_msg = "" 255s if isinstance(self.reason, bytes): 255s # We attempt to decode utf-8 first because some servers 255s # choose to localize their reason strings. If the string 255s # isn't utf-8, we fall back to iso-8859-1 for all other 255s # encodings. (See PR #3538) 255s try: 255s reason = self.reason.decode("utf-8") 255s except UnicodeDecodeError: 255s reason = self.reason.decode("iso-8859-1") 255s else: 255s reason = self.reason 255s 255s if 400 <= self.status_code < 500: 255s http_error_msg = ( 255s f"{self.status_code} Client Error: {reason} for url: {self.url}" 255s ) 255s 255s elif 500 <= self.status_code < 600: 255s http_error_msg = ( 255s f"{self.status_code} Server Error: {reason} for url: {self.url}" 255s ) 255s 255s if http_error_msg: 255s > raise HTTPError(http_error_msg, response=self) 255s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd 255s 255s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 255s ----------------------------- Captured stderr call ----------------------------- 255s Traceback (most recent call last): 255s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 255s return _run_code(code, main_globals, None, 255s "__main__", mod_spec) 255s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 255s exec(code, run_globals) 255s ~~~~^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 255s from ipykernel import kernelapp as app 255s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 255s from .connect import * # noqa: F403 255s ^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 12, in 255s import jupyter_client 255s File "/usr/lib/python3/dist-packages/jupyter_client/__init__.py", line 4, in 255s from .asynchronous import AsyncKernelClient 255s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/__init__.py", line 1, in 255s from .client import AsyncKernelClient # noqa 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/client.py", line 9, in 255s import zmq.asyncio 255s File "", line 1360, in _find_and_load 255s File "", line 1331, in _find_and_load_unlocked 255s File "", line 935, in _load_unlocked 255s File "", line 1019, in exec_module 255s File "", line 1109, in get_code 255s File "", line 1232, in path_stats 255s File "", line 152, in _path_stat 255s KeyboardInterrupt 255s Traceback (most recent call last): 255s ------------------------------ Captured log call ------------------------------- 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 255s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcqkf_mv7/runtime/kernel-a60b5ada-a0ab-466b-8b02-c67a7d5bdaa2.json'] 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:49287 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:52985 255s INFO NotebookApp:kernelmanager.py:179 Kernel started: a60b5ada-a0ab-466b-8b02-c67a7d5bdaa2, name: python3 255s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpcqkf_mv7/notebooks/foo'} 255s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 17.940000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 255s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcqkf_mv7/runtime/kernel-8394ace2-9e71-4fad-9254-122f4049e432.json'] 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:41107 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:50221 255s INFO NotebookApp:kernelmanager.py:179 Kernel started: 8394ace2-9e71-4fad-9254-122f4049e432, name: python3 255s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 255s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 19.690000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for a60b5ada-a0ab-466b-8b02-c67a7d5bdaa2 255s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a60b5ada-a0ab-466b-8b02-c67a7d5bdaa2 255s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s ERROR NotebookApp:web.py:1945 Uncaught exception PATCH /a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd (127.0.0.1) 255s HTTPServerRequest(protocol='http', host='localhost:12341', method='PATCH', uri='/a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd', version='HTTP/1.1', remote_ip='127.0.0.1') 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 255s result = await result 255s ^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 255s yielded = self.gen.send(value) 255s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 154, in patch 255s km.shutdown_kernel(before['kernel']['id']) 255s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 255s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 255s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 255s return _runner_map[name].run(inner) 255s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 255s return fut.result(None) 255s ~~~~~~~~~~^^^^^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 255s return self.__get_result() 255s ~~~~~~~~~~~~~~~~~^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 255s raise self._exception 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 255s result = coro.send(None) 255s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 255s stopper = ensure_async(km.shutdown_kernel(now, restart)) 255s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 255s return _runner_map[name].run(inner) 255s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 255s return fut.result(None) 255s ~~~~~~~~~~^^^^^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 255s return self.__get_result() 255s ~~~~~~~~~~~~~~~~~^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 255s raise self._exception 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 255s result = coro.send(None) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 255s raise e 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s WARNING NotebookApp:handlers.py:612 Unhandled error 255s ERROR NotebookApp:log.py:55 { 255s "Host": "localhost:12341", 255s "Accept": "*/*", 255s "User-Agent": "python-requests/2.32.5" 255s } 255s ERROR NotebookApp:log.py:59 500 PATCH /a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd (127.0.0.1) 9.860000ms referer=None 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.120000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 8394ace2-9e71-4fad-9254-122f4049e432 255s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 8394ace2-9e71-4fad-9254-122f4049e432 255s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd (127.0.0.1) 255s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd', version='HTTP/1.1', remote_ip='127.0.0.1') 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 255s result = await result 255s ^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 255s yielded = self.gen.throw(exc) 255s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 255s yield maybe_future(sm.delete_session(session_id)) 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 255s value = future.result() 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 255s yielded = self.gen.send(value) 255s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 255s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 255s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 255s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 255s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 255s return _runner_map[name].run(inner) 255s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 255s return fut.result(None) 255s ~~~~~~~~~~^^^^^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 255s return self.__get_result() 255s ~~~~~~~~~~~~~~~~~^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 255s raise self._exception 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 255s result = coro.send(None) 255s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 255s stopper = ensure_async(km.shutdown_kernel(now, restart)) 255s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 255s return _runner_map[name].run(inner) 255s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 255s return fut.result(None) 255s ~~~~~~~~~~^^^^^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 255s return self.__get_result() 255s ~~~~~~~~~~~~~~~~~^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 255s raise self._exception 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 255s result = coro.send(None) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 255s raise e 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s WARNING NotebookApp:handlers.py:612 Unhandled error 255s ERROR NotebookApp:log.py:55 { 255s "Host": "localhost:12341", 255s "Accept": "*/*", 255s "User-Agent": "python-requests/2.32.5" 255s } 255s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd (127.0.0.1) 8.580000ms referer=None 255s --------------------------- Captured stderr teardown --------------------------- 255s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 255s return _run_code(code, main_globals, None, 255s "__main__", mod_spec) 255s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 255s exec(code, run_globals) 255s ~~~~^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 255s from ipykernel import kernelapp as app 255s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 255s from .connect import * # noqa: F403 255s ^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 9, in 255s from subprocess import PIPE, Popen 255s File "/usr/lib/python3.13/subprocess.py", line 51, in 255s import threading 255s File "", line 1360, in _find_and_load 255s File "", line 1331, in _find_and_load_unlocked 255s File "", line 935, in _load_unlocked 255s File "", line 1019, in exec_module 255s File "", line 1152, in get_code 255s File "", line 781, in _compile_bytecode 255s KeyboardInterrupt 255s _________ ERROR at teardown of SessionAPITest.test_modify_kernel_name __________ 255s 255s @self.addCleanup 255s def cleanup_sessions(): 255s for session in self.sess_api.list().json(): 255s > self.sess_api.delete(session['id']) 255s 255s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 255s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 255s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 255s return self._req('DELETE', id) 255s ^^^^^^^^^^^^^^^^^^^^^^^ 255s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 255s response.raise_for_status() 255s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 255s 255s self = 255s 255s def raise_for_status(self): 255s """Raises :class:`HTTPError`, if one occurred.""" 255s 255s http_error_msg = "" 255s if isinstance(self.reason, bytes): 255s # We attempt to decode utf-8 first because some servers 255s # choose to localize their reason strings. If the string 255s # isn't utf-8, we fall back to iso-8859-1 for all other 255s # encodings. (See PR #3538) 255s try: 255s reason = self.reason.decode("utf-8") 255s except UnicodeDecodeError: 255s reason = self.reason.decode("iso-8859-1") 255s else: 255s reason = self.reason 255s 255s if 400 <= self.status_code < 500: 255s http_error_msg = ( 255s f"{self.status_code} Client Error: {reason} for url: {self.url}" 255s ) 255s 255s elif 500 <= self.status_code < 600: 255s http_error_msg = ( 255s f"{self.status_code} Server Error: {reason} for url: {self.url}" 255s ) 255s 255s if http_error_msg: 255s > raise HTTPError(http_error_msg, response=self) 255s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd 255s 255s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 255s ----------------------------- Captured stderr call ----------------------------- 255s Traceback (most recent call last): 255s ------------------------------ Captured log call ------------------------------- 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.180000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 255s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcqkf_mv7/runtime/kernel-c83ed830-c109-4c05-9c37-7254a77caeae.json'] 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34069 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:54627 255s INFO NotebookApp:kernelmanager.py:179 Kernel started: c83ed830-c109-4c05-9c37-7254a77caeae, name: python3 255s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3', 'cwd': '/tmp/tmpcqkf_mv7/notebooks/foo'} 255s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 8394ace2-9e71-4fad-9254-122f4049e432 255s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 8394ace2-9e71-4fad-9254-122f4049e432 255s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd (127.0.0.1) 18.880000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.980000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.080000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for c83ed830-c109-4c05-9c37-7254a77caeae 255s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c83ed830-c109-4c05-9c37-7254a77caeae 255s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd (127.0.0.1) 255s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd', version='HTTP/1.1', remote_ip='127.0.0.1') 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 255s result = await result 255s ^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 255s yielded = self.gen.throw(exc) 255s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 255s yield maybe_future(sm.delete_session(session_id)) 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 255s value = future.result() 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 255s yielded = self.gen.send(value) 255s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 255s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 255s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 255s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 255s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 255s return _runner_map[name].run(inner) 255s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 255s return fut.result(None) 255s ~~~~~~~~~~^^^^^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 255s return self.__get_result() 255s ~~~~~~~~~~~~~~~~~^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 255s raise self._exception 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 255s result = coro.send(None) 255s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 255s stopper = ensure_async(km.shutdown_kernel(now, restart)) 255s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 255s return _runner_map[name].run(inner) 255s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 255s return fut.result(None) 255s ~~~~~~~~~~^^^^^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 255s return self.__get_result() 255s ~~~~~~~~~~~~~~~~~^^ 255s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 255s raise self._exception 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 255s result = coro.send(None) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 255s raise e 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s WARNING NotebookApp:handlers.py:612 Unhandled error 255s ERROR NotebookApp:log.py:55 { 255s "Host": "localhost:12341", 255s "Accept": "*/*", 255s "User-Agent": "python-requests/2.32.5" 255s } 255s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd (127.0.0.1) 8.350000ms referer=None 255s --------------------------- Captured stderr teardown --------------------------- 255s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 255s return _run_code(code, main_globals, None, 255s "__main__", mod_spec) 255s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 255s exec(code, run_globals) 255s ~~~~^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 255s from pathlib import Path 255s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 255s from ._local import * 255s File "", line 1360, in _find_and_load 255s File "", line 1331, in _find_and_load_unlocked 255s File "", line 935, in _load_unlocked 255s File "", line 1019, in exec_module 255s File "", line 1152, in get_code 255s File "", line 781, in _compile_bytecode 255s KeyboardInterrupt 255s _____ ERROR at teardown of AsyncSessionAPITest.test_create_with_kernel_id ______ 255s 255s @self.addCleanup 255s def cleanup_sessions(): 255s for session in self.sess_api.list().json(): 255s > self.sess_api.delete(session['id']) 255s 255s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 255s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 255s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 255s return self._req('DELETE', id) 255s ^^^^^^^^^^^^^^^^^^^^^^^ 255s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 255s response.raise_for_status() 255s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 255s 255s self = 255s 255s def raise_for_status(self): 255s """Raises :class:`HTTPError`, if one occurred.""" 255s 255s http_error_msg = "" 255s if isinstance(self.reason, bytes): 255s # We attempt to decode utf-8 first because some servers 255s # choose to localize their reason strings. If the string 255s # isn't utf-8, we fall back to iso-8859-1 for all other 255s # encodings. (See PR #3538) 255s try: 255s reason = self.reason.decode("utf-8") 255s except UnicodeDecodeError: 255s reason = self.reason.decode("iso-8859-1") 255s else: 255s reason = self.reason 255s 255s if 400 <= self.status_code < 500: 255s http_error_msg = ( 255s f"{self.status_code} Client Error: {reason} for url: {self.url}" 255s ) 255s 255s elif 500 <= self.status_code < 600: 255s http_error_msg = ( 255s f"{self.status_code} Server Error: {reason} for url: {self.url}" 255s ) 255s 255s if http_error_msg: 255s > raise HTTPError(http_error_msg, response=self) 255s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/0846bc91-8647-408d-bc1b-f4d9ce6ec2ac 255s 255s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 255s ----------------------------- Captured stderr call ----------------------------- 255s Traceback (most recent call last): 255s ------------------------------ Captured log call ------------------------------- 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 255s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkhe726bz/runtime/kernel-e4652af5-f608-4843-bcbb-87f813fa42ac.json'] 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:39067 255s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:54493 255s INFO NotebookApp:kernelmanager.py:179 Kernel started: e4652af5-f608-4843-bcbb-87f813fa42ac, name: python3 255s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 255s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.300000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.270000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.040000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.020000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 870d4235-a112-4d53-a325-4823b769d30e 255s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 870d4235-a112-4d53-a325-4823b769d30e 255s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/48de1307-3bd3-4f84-b377-a32302296ea8 (127.0.0.1) 1.260000ms 255s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 255s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for e4652af5-f608-4843-bcbb-87f813fa42ac 255s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: e4652af5-f608-4843-bcbb-87f813fa42ac 255s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 255s await kernel_awaitable 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 255s result = await obj 255s ^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 255s raise e 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/0846bc91-8647-408d-bc1b-f4d9ce6ec2ac (127.0.0.1) 255s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/0846bc91-8647-408d-bc1b-f4d9ce6ec2ac', version='HTTP/1.1', remote_ip='127.0.0.1') 255s Traceback (most recent call last): 255s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 255s result = await result 255s ^^^^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 255s future.result() 255s ~~~~~~~~~~~~~^^ 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 255s yielded = self.gen.throw(exc) 255s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 255s yield maybe_future(sm.delete_session(session_id)) 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 255s value = future.result() 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 255s yielded = self.gen.throw(exc) 255s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 255s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 255s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 255s value = future.result() 255s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 255s raise self._exception.with_traceback(self._exception_tb) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 255s result = coro.send(None) 255s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 255s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 255s raise km.ready.exception() # type: ignore[misc] 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 255s await kernel_awaitable 255s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 255s result = await obj 255s ^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 255s raise e 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 255s out = await method(self, *args, **kwargs) 255s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 255s await self._async_finish_shutdown(restart=restart) 255s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 255s await asyncio.wait_for( 255s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 255s ) 255s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 255s async with timeouts.timeout(timeout): 255s ~~~~~~~~~~~~~~~~^^^^^^^^^ 255s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 255s raise RuntimeError("Timeout should be used inside a task") 255s RuntimeError: Timeout should be used inside a task 255s WARNING NotebookApp:handlers.py:612 Unhandled error 255s ERROR NotebookApp:log.py:55 { 255s "Host": "localhost:12341", 255s "Accept": "*/*", 255s "User-Agent": "python-requests/2.32.5" 255s } 255s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/0846bc91-8647-408d-bc1b-f4d9ce6ec2ac (127.0.0.1) 8.150000ms referer=None 255s --------------------------- Captured stderr teardown --------------------------- 255s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 255s return _run_code(code, main_globals, None, 255s "__main__", mod_spec) 255s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 255s exec(code, run_globals) 255s ~~~~^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 255s from ipykernel import kernelapp as app 255s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 255s from .connect import * # noqa: F403 255s ^^^^^^^^^^^^^^^^^^^^^^ 255s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 9, in 255s from subprocess import PIPE, Popen 255s File "/usr/lib/python3.13/subprocess.py", line 46, in 255s import locale 255s File "", line 1360, in _find_and_load 255s File "", line 1331, in _find_and_load_unlocked 255s File "", line 935, in _load_unlocked 255s File "", line 1019, in exec_module 255s File "", line 1152, in get_code 255s File "", line 781, in _compile_bytecode 255s KeyboardInterrupt 255s ________ ERROR at teardown of AsyncSessionAPITest.test_modify_kernel_id ________ 255s 255s @self.addCleanup 255s def cleanup_sessions(): 255s for session in self.sess_api.list().json(): 255s > self.sess_api.delete(session['id']) 255s 255s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 255s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 255s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 255s return self._req('DELETE', id) 255s ^^^^^^^^^^^^^^^^^^^^^^^ 255s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 255s response.raise_for_status() 255s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 255s 255s self = 255s 255s def raise_for_status(self): 255s """Raises :class:`HTTPError`, if one occurred.""" 255s 255s http_error_msg = "" 255s if isinstance(self.reason, bytes): 255s # We attempt to decode utf-8 first because some servers 255s # choose to localize their reason strings. If the string 255s # isn't utf-8, we fall back to iso-8859-1 for all other 255s # encodings. (See PR #3538) 255s try: 255s reason = self.reason.decode("utf-8") 255s except UnicodeDecodeError: 255s reason = self.reason.decode("iso-8859-1") 255s else: 255s reason = self.reason 255s 255s if 400 <= self.status_code < 500: 255s http_error_msg = ( 255s f"{self.status_code} Client Error: {reason} for url: {self.url}" 255s ) 255s 255s elif 500 <= self.status_code < 600: 255s http_error_msg = ( 255s f"{self.status_code} Server Error: {reason} for url: {self.url}" 255s ) 255s 255s if http_error_msg: 255s > raise HTTPError(http_error_msg, response=self) 255s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9 255s 255s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 255s /usr/lib/python3/dist-packages/_pytest/unraisableexception.py:33: RuntimeWarning: coroutine 'KernelManager._async_wait' was never awaited 255s gc.collect() 255s RuntimeWarning: Enable tracemalloc to get the object allocation traceback 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 256s from ipykernel import kernelapp as app 256s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 256s from .connect import * # noqa: F403 256s ^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 10, in 256s from typing import TYPE_CHECKING, Any 256s File "/usr/lib/python3.13/typing.py", line 2174, in 256s class Protocol(Generic, metaclass=_ProtocolMeta): 256s ...<49 lines>... 256s cls.__init__ = _no_init_or_replace_init 256s File "/usr/lib/python3.13/typing.py", line 2083, in __new__ 256s return super().__new__(mcls, name, bases, namespace, **kwargs) 256s ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3.13/abc.py", line 106, in __new__ 256s cls = super().__new__(mcls, name, bases, namespace, **kwargs) 256s File "", line 463, in _lock_unlock_module 256s KeyboardInterrupt 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkhe726bz/runtime/kernel-a629dc73-d6df-4973-912a-e0f27664136c.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55737 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:49375 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: a629dc73-d6df-4973-912a-e0f27664136c, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpkhe726bz/notebooks/foo'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 16.720000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkhe726bz/runtime/kernel-dd2f98a7-54fc-4c31-94ad-007d50d960ae.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:42993 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:60071 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: dd2f98a7-54fc-4c31-94ad-007d50d960ae, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.280000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for a629dc73-d6df-4973-912a-e0f27664136c 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a629dc73-d6df-4973-912a-e0f27664136c 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception PATCH /a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='PATCH', uri='/a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 153, in patch 256s yield maybe_future( 256s km.shutdown_kernel(before['kernel']['id']) 256s ) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 256s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 256s raise km.ready.exception() # type: ignore[misc] 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 PATCH /a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9 (127.0.0.1) 7.660000ms referer=None 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 0.960000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for dd2f98a7-54fc-4c31-94ad-007d50d960ae 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: dd2f98a7-54fc-4c31-94ad-007d50d960ae 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 256s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 256s raise km.ready.exception() # type: ignore[misc] 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9 (127.0.0.1) 8.240000ms referer=None 256s --------------------------- Captured stderr teardown --------------------------- 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 256s from ipykernel import kernelapp as app 256s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 256s from .connect import * # noqa: F403 256s ^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 7, in 256s import json 256s File "/usr/lib/python3.13/json/__init__.py", line 107, in 256s from .encoder import JSONEncoder 256s File "/usr/lib/python3.13/json/encoder.py", line 19, in 256s ESCAPE_ASCII = re.compile(r'([\\"]|[^\ -~])') 256s File "/usr/lib/python3.13/re/__init__.py", line 289, in compile 256s return _compile(pattern, flags) 256s File "/usr/lib/python3.13/re/__init__.py", line 341, in _compile 256s p = _cache.pop(key, None) 256s KeyboardInterrupt 256s _______ ERROR at teardown of AsyncSessionAPITest.test_modify_kernel_name _______ 256s 256s @self.addCleanup 256s def cleanup_sessions(): 256s for session in self.sess_api.list().json(): 256s > self.sess_api.delete(session['id']) 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.260000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkhe726bz/runtime/kernel-5f19324d-14b4-4279-80bb-058bc71fa7c0.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:44021 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34399 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 5f19324d-14b4-4279-80bb-058bc71fa7c0, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3', 'cwd': '/tmp/tmpkhe726bz/notebooks/foo'} 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for dd2f98a7-54fc-4c31-94ad-007d50d960ae 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: dd2f98a7-54fc-4c31-94ad-007d50d960ae 256s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9 (127.0.0.1) 19.520000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.000000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.020000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 5f19324d-14b4-4279-80bb-058bc71fa7c0 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 5f19324d-14b4-4279-80bb-058bc71fa7c0 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 256s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 256s raise km.ready.exception() # type: ignore[misc] 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9 (127.0.0.1) 7.780000ms referer=None 256s --------------------------- Captured stderr teardown --------------------------- 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 256s from pathlib import Path 256s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 256s from ._abc import * 256s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 256s from glob import _Globber, _no_recurse_symlinks 256s File "/usr/lib/python3.13/glob.py", line 6, in 256s import fnmatch 256s File "/usr/lib/python3.13/fnmatch.py", line 38, in 256s @functools.lru_cache(maxsize=32768, typed=True) 256s ~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3.13/functools.py", line 547, in decorating_function 256s return update_wrapper(wrapper, user_function) 256s File "/usr/lib/python3.13/functools.py", line 59, in update_wrapper 256s getattr(wrapper, attr).update(getattr(wrapped, attr, {})) 256s ~~~~~~~^^^^^^^^^^^^^^^^^^^ 256s KeyboardInterrupt 256s =================================== FAILURES =================================== 256s ______________________ KernelAPITest.test_default_kernel _______________________ 256s 256s self = 256s 256s def tearDown(self): 256s for k in self.kern_api.list().json(): 256s > self.kern_api.shutdown(k['id']) 256s 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/59f91014-c1c7-46a7-87f7-282315e1c19f 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ------------------------------ Captured log setup ------------------------------ 256s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmpqmf_w3ur/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmpqmf_w3ur/etc/jupyter'] for config files 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpqmf_w3ur/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpqmf_w3ur/config 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpqmf_w3ur/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpqmf_w3ur/config 256s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmpqmf_w3ur/notebooks 256s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 256s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 256s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 256s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 256s WARNING NotebookApp:handlers.py:612 Forbidden 256s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 0.670000ms referer=None 256s ----------------------------- Captured stderr call ----------------------------- 256s Fatal Python error: init_import_site: Failed to import the site module 256s Python runtime state: initialized 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpqmf_w3ur/runtime/kernel-59f91014-c1c7-46a7-87f7-282315e1c19f.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:44447 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:41701 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 59f91014-c1c7-46a7-87f7-282315e1c19f, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 61.340000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.940000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 59f91014-c1c7-46a7-87f7-282315e1c19f 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 59f91014-c1c7-46a7-87f7-282315e1c19f 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/59f91014-c1c7-46a7-87f7-282315e1c19f (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/59f91014-c1c7-46a7-87f7-282315e1c19f', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 256s yielded = ctx_run(next, result) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 256s yield maybe_future(km.shutdown_kernel(kernel_id)) 256s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 256s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 256s stopper = ensure_async(km.shutdown_kernel(now, restart)) 256s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/59f91014-c1c7-46a7-87f7-282315e1c19f (127.0.0.1) 10.690000ms referer=None 256s --------------------------- Captured stderr teardown --------------------------- 256s Traceback (most recent call last): 256s File "/usr/lib/python3.13/site.py", line 735, in 256s main() 256s ~~~~^^ 256s File "/usr/lib/python3.13/site.py", line 722, in main 256s known_paths = addsitepackages(known_paths) 256s File "/usr/lib/python3.13/site.py", line 441, in addsitepackages 256s addsitedir(sitedir, known_paths) 256s ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3.13/site.py", line 254, in addsitedir 256s addpackage(sitedir, name, known_paths) 256s ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3.13/site.py", line 213, in addpackage 256s exec(line) 256s ~~~~^^^^^^ 256s File "", line 1, in 256s File "", line 1360, in _find_and_load 256s File "", line 1322, in _find_and_load_unlocked 256s File "", line 1262, in _find_spec 256s File "", line 1556, in find_spec 256s File "", line 1530, in _get_spec 256s File "", line 1633, in find_spec 256s File "", line 1676, in _fill_cache 256s KeyboardInterrupt 256s ______________________ KernelAPITest.test_kernel_handler _______________________ 256s 256s self = 256s 256s def test_kernel_handler(self): 256s # GET kernel with given id 256s kid = self.kern_api.start().json()['id'] 256s r = self.kern_api.get(kid) 256s kern1 = r.json() 256s self.assertEqual(r.status_code, 200) 256s assert isinstance(kern1, dict) 256s self.assertIn('id', kern1) 256s self.assertEqual(kern1['id'], kid) 256s 256s # Request a bad kernel id and check that a JSON 256s # message is returned! 256s bad_id = '111-111-111-111-111' 256s with assert_http_error(404, 'Kernel does not exist: ' + bad_id): 256s self.kern_api.get(bad_id) 256s 256s # DELETE kernel with id 256s > r = self.kern_api.shutdown(kid) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:169: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/ba5e7eb8-7d03-4c7e-9dba-fedf3e2f1f5b 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpqmf_w3ur/runtime/kernel-ba5e7eb8-7d03-4c7e-9dba-fedf3e2f1f5b.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:49737 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:47489 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: ba5e7eb8-7d03-4c7e-9dba-fedf3e2f1f5b, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 17.110000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/ba5e7eb8-7d03-4c7e-9dba-fedf3e2f1f5b (127.0.0.1) 0.940000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s WARNING NotebookApp:web.py:1943 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1): Kernel does not exist: 111-111-111-111-111 256s WARNING NotebookApp:handlers.py:612 Kernel does not exist: 111-111-111-111-111 256s WARNING NotebookApp:log.py:59 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1) 1.040000ms referer=None 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ba5e7eb8-7d03-4c7e-9dba-fedf3e2f1f5b 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ba5e7eb8-7d03-4c7e-9dba-fedf3e2f1f5b 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/ba5e7eb8-7d03-4c7e-9dba-fedf3e2f1f5b (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/ba5e7eb8-7d03-4c7e-9dba-fedf3e2f1f5b', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 256s yielded = ctx_run(next, result) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 256s yield maybe_future(km.shutdown_kernel(kernel_id)) 256s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 256s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 256s stopper = ensure_async(km.shutdown_kernel(now, restart)) 256s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/ba5e7eb8-7d03-4c7e-9dba-fedf3e2f1f5b (127.0.0.1) 8.000000ms referer=None 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.980000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 59f91014-c1c7-46a7-87f7-282315e1c19f 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 59f91014-c1c7-46a7-87f7-282315e1c19f 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/59f91014-c1c7-46a7-87f7-282315e1c19f (127.0.0.1) 1.300000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ba5e7eb8-7d03-4c7e-9dba-fedf3e2f1f5b 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ba5e7eb8-7d03-4c7e-9dba-fedf3e2f1f5b 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/ba5e7eb8-7d03-4c7e-9dba-fedf3e2f1f5b (127.0.0.1) 1.250000ms 256s --------------------------- Captured stderr teardown --------------------------- 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 256s from pathlib import Path 256s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 256s from ._abc import * 256s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 256s from glob import _Globber, _no_recurse_symlinks 256s File "/usr/lib/python3.13/glob.py", line 3, in 256s import contextlib 256s File "/usr/lib/python3.13/contextlib.py", line 8, in 256s from types import MethodType, GenericAlias 256s File "/usr/lib/python3.13/types.py", line 334, in __getattr__ 256s def __getattr__(name): 256s 256s KeyboardInterrupt 256s ____________________ KernelAPITest.test_main_kernel_handler ____________________ 256s 256s self = 256s 256s def test_main_kernel_handler(self): 256s # POST request 256s r = self.kern_api.start() 256s kern1 = r.json() 256s self.assertEqual(r.headers['location'], url_path_join(self.url_prefix, 'api/kernels', kern1['id'])) 256s self.assertEqual(r.status_code, 201) 256s self.assertIsInstance(kern1, dict) 256s 256s report_uri = url_path_join(self.url_prefix, 'api/security/csp-report') 256s expected_csp = '; '.join([ 256s "frame-ancestors 'self'", 256s 'report-uri ' + report_uri, 256s "default-src 'none'" 256s ]) 256s self.assertEqual(r.headers['Content-Security-Policy'], expected_csp) 256s 256s # GET request 256s r = self.kern_api.list() 256s self.assertEqual(r.status_code, 200) 256s assert isinstance(r.json(), list) 256s self.assertEqual(r.json()[0]['id'], kern1['id']) 256s self.assertEqual(r.json()[0]['name'], kern1['name']) 256s 256s # create another kernel and check that they both are added to the 256s # list of kernels from a GET request 256s kern2 = self.kern_api.start().json() 256s assert isinstance(kern2, dict) 256s r = self.kern_api.list() 256s kernels = r.json() 256s self.assertEqual(r.status_code, 200) 256s assert isinstance(kernels, list) 256s self.assertEqual(len(kernels), 2) 256s 256s # Interrupt a kernel 256s r = self.kern_api.interrupt(kern2['id']) 256s self.assertEqual(r.status_code, 204) 256s 256s # Restart a kernel 256s > r = self.kern_api.restart(kern2['id']) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:147: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:63: in restart 256s return self._req('POST', url_path_join(id, 'restart')) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: http://localhost:12341/a%40b/api/kernels/deb0785e-9fab-49f7-9c85-dffba3702952/restart 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 256s from pathlib import Path 256s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 256s from ._abc import * 256s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 256s from glob import _Globber, _no_recurse_symlinks 256s File "/usr/lib/python3.13/glob.py", line 5, in 256s import re 256s File "/usr/lib/python3.13/re/__init__.py", line 125, in 256s import enum 256s File "", line 1360, in _find_and_load 256s File "", line 1331, in _find_and_load_unlocked 256s File "", line 935, in _load_unlocked 256s File "", line 1019, in exec_module 256s File "", line 1109, in get_code 256s File "", line 1232, in path_stats 256s File "", line 152, in _path_stat 256s KeyboardInterrupt 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpqmf_w3ur/runtime/kernel-1514df78-fcee-4a38-a2ba-d1a4dd9782a2.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:51361 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:48699 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 1514df78-fcee-4a38-a2ba-d1a4dd9782a2, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 20.460000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.910000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpqmf_w3ur/runtime/kernel-deb0785e-9fab-49f7-9c85-dffba3702952.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55871 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:50073 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: deb0785e-9fab-49f7-9c85-dffba3702952, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.950000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.360000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: deb0785e-9fab-49f7-9c85-dffba3702952 256s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/deb0785e-9fab-49f7-9c85-dffba3702952/interrupt (127.0.0.1) 1.700000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 256s yield maybe_future(km.restart_kernel(kernel_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 256s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 256s await ensure_async(kernel.restart_kernel(now=now)) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 256s await self._async_shutdown_kernel(now=now, restart=True) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/deb0785e-9fab-49f7-9c85-dffba3702952/restart (127.0.0.1) 5.440000ms referer=None 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.920000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 1514df78-fcee-4a38-a2ba-d1a4dd9782a2 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 1514df78-fcee-4a38-a2ba-d1a4dd9782a2 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/1514df78-fcee-4a38-a2ba-d1a4dd9782a2 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/1514df78-fcee-4a38-a2ba-d1a4dd9782a2', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 256s yielded = ctx_run(next, result) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 256s yield maybe_future(km.shutdown_kernel(kernel_id)) 256s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 256s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 256s stopper = ensure_async(km.shutdown_kernel(now, restart)) 256s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/1514df78-fcee-4a38-a2ba-d1a4dd9782a2 (127.0.0.1) 7.800000ms referer=None 256s ________________________ KernelAPITest.test_no_kernels _________________________ 256s 256s self = 256s 256s def test_no_kernels(self): 256s """Make sure there are no kernels running at the start""" 256s kernels = self.kern_api.list().json() 256s > self.assertEqual(kernels, []) 256s E AssertionError: Lists differ: [{'id': '1514df78-fcee-4a38-a2ba-d1a4dd978[281 chars]: 0}] != [] 256s E 256s E First list contains 2 additional elements. 256s E First extra element 0: 256s E {'id': '1514df78-fcee-4a38-a2ba-d1a4dd9782a2', 'name': 'python3', 'last_activity': '2026-02-06T04:18:24.910351Z', 'execution_state': 'starting', 'connections': 0} 256s E 256s E + [] 256s E - [{'connections': 0, 256s E - 'execution_state': 'starting', 256s E - 'id': '1514df78-fcee-4a38-a2ba-d1a4dd9782a2', 256s E - 'last_activity': '2026-02-06T04:18:24.910351Z', 256s E - 'name': 'python3'}, 256s E - {'connections': 0, 256s E - 'execution_state': 'starting', 256s E - 'id': 'deb0785e-9fab-49f7-9c85-dffba3702952', 256s E - 'last_activity': '2026-02-06T04:18:24.933860Z', 256s E - 'name': 'python3'}] 256s 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:91: AssertionError 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.010000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.920000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 1514df78-fcee-4a38-a2ba-d1a4dd9782a2 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 1514df78-fcee-4a38-a2ba-d1a4dd9782a2 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/1514df78-fcee-4a38-a2ba-d1a4dd9782a2 (127.0.0.1) 1.470000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for deb0785e-9fab-49f7-9c85-dffba3702952 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: deb0785e-9fab-49f7-9c85-dffba3702952 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/deb0785e-9fab-49f7-9c85-dffba3702952 (127.0.0.1) 1.670000ms 256s ---------------------------- Captured log teardown ----------------------------- 256s INFO NotebookApp:notebookapp.py:2164 Shutting down 0 kernels 256s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 256s _____________________ AsyncKernelAPITest.test_connections ______________________ 256s 256s self = 256s 256s def tearDown(self): 256s for k in self.kern_api.list().json(): 256s > self.kern_api.shutdown(k['id']) 256s 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/63b5d7a3-b558-48b5-841b-7526dc2cf43c 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ------------------------------ Captured log setup ------------------------------ 256s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmp0lmkbuy5/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmp0lmkbuy5/etc/jupyter'] for config files 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmp0lmkbuy5/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmp0lmkbuy5/config 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmp0lmkbuy5/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmp0lmkbuy5/config 256s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmp0lmkbuy5/notebooks 256s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 256s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 256s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 256s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 256s WARNING NotebookApp:handlers.py:612 Forbidden 256s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 1.610000ms referer=None 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp0lmkbuy5/runtime/kernel-63b5d7a3-b558-48b5-841b-7526dc2cf43c.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:35821 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:60911 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 63b5d7a3-b558-48b5-841b-7526dc2cf43c, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 17.020000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/63b5d7a3-b558-48b5-841b-7526dc2cf43c (127.0.0.1) 1.740000ms 256s DEBUG NotebookApp:zmqhandlers.py:298 Initializing websocket connection /a%40b/api/kernels/63b5d7a3-b558-48b5-841b-7526dc2cf43c/channels 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s WARNING NotebookApp:zmqhandlers.py:286 No session ID specified 256s DEBUG NotebookApp:handlers.py:277 Requesting kernel info from 63b5d7a3-b558-48b5-841b-7526dc2cf43c 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:42715 256s DEBUG NotebookApp:kernelmanager.py:423 activity on 63b5d7a3-b558-48b5-841b-7526dc2cf43c: status (starting) 256s DEBUG NotebookApp:kernelmanager.py:423 activity on 63b5d7a3-b558-48b5-841b-7526dc2cf43c: status (busy) 256s DEBUG NotebookApp:handlers.py:306 Received kernel info: {'status': 'ok', 'protocol_version': '5.3', 'implementation': 'ipython', 'implementation_version': '8.35.0', 'language_info': {'name': 'python', 'version': '3.13.11', 'mimetype': 'text/x-python', 'codemirror_mode': {'name': 'ipython', 'version': 3}, 'pygments_lexer': 'ipython3', 'nbconvert_exporter': 'python', 'file_extension': '.py'}, 'banner': "Python 3.13.11 (main, Dec 6 2025, 13:15:20) [GCC 15.2.0]\nType 'copyright', 'credits' or 'license' for more information\nIPython 8.35.0 -- An enhanced Interactive Python. Type '?' for help.\n", 'help_links': [{'text': 'Python Reference', 'url': 'https://docs.python.org/3.13'}, {'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/'}]} 256s INFO NotebookApp:handlers.py:326 Adapting from protocol version 5.3 (kernel 63b5d7a3-b558-48b5-841b-7526dc2cf43c) to 5.4 (client). 256s DEBUG NotebookApp:log.py:59 101 GET /a%40b/api/kernels/63b5d7a3-b558-48b5-841b-7526dc2cf43c/channels (127.0.0.1) 717.070000ms 256s DEBUG NotebookApp:zmqhandlers.py:159 Opening websocket /a%40b/api/kernels/63b5d7a3-b558-48b5-841b-7526dc2cf43c/channels 256s DEBUG NotebookApp:kernelmanager.py:252 Getting buffer for 63b5d7a3-b558-48b5-841b-7526dc2cf43c 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:60911 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:42715 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:35821 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:39243 256s DEBUG NotebookApp:handlers.py:156 Nudge: not nudging busy kernel 63b5d7a3-b558-48b5-841b-7526dc2cf43c 256s WARNING NotebookApp:websocket.py:1327 The websocket_ping_timeout (90000) cannot be longer than the websocket_ping_interval (30000). 256s Setting websocket_ping_timeout=30000 256s DEBUG NotebookApp:kernelmanager.py:423 activity on 63b5d7a3-b558-48b5-841b-7526dc2cf43c: status (idle) 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/63b5d7a3-b558-48b5-841b-7526dc2cf43c (127.0.0.1) 0.990000ms 256s DEBUG NotebookApp:handlers.py:579 Websocket closed 63b5d7a3-b558-48b5-841b-7526dc2cf43c:877feba1-30bdb1e5675fe25987feef14 256s INFO NotebookApp:kernelmanager.py:222 Starting buffering for 63b5d7a3-b558-48b5-841b-7526dc2cf43c:877feba1-30bdb1e5675fe25987feef14 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 63b5d7a3-b558-48b5-841b-7526dc2cf43c 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/63b5d7a3-b558-48b5-841b-7526dc2cf43c (127.0.0.1) 2.790000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/63b5d7a3-b558-48b5-841b-7526dc2cf43c (127.0.0.1) 1.040000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.900000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 63b5d7a3-b558-48b5-841b-7526dc2cf43c 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 63b5d7a3-b558-48b5-841b-7526dc2cf43c 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/63b5d7a3-b558-48b5-841b-7526dc2cf43c (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/63b5d7a3-b558-48b5-841b-7526dc2cf43c', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 256s yield maybe_future(km.shutdown_kernel(kernel_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 256s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 256s raise km.ready.exception() # type: ignore[misc] 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/63b5d7a3-b558-48b5-841b-7526dc2cf43c (127.0.0.1) 8.720000ms referer=None 256s ____________________ AsyncKernelAPITest.test_default_kernel ____________________ 256s 256s self = 256s 256s def tearDown(self): 256s for k in self.kern_api.list().json(): 256s > self.kern_api.shutdown(k['id']) 256s 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/c01e3838-490c-4eb5-9195-8f7529fdbc6e 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp0lmkbuy5/runtime/kernel-c01e3838-490c-4eb5-9195-8f7529fdbc6e.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:48117 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:60161 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: c01e3838-490c-4eb5-9195-8f7529fdbc6e, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 19.910000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.070000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 63b5d7a3-b558-48b5-841b-7526dc2cf43c 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 63b5d7a3-b558-48b5-841b-7526dc2cf43c 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/63b5d7a3-b558-48b5-841b-7526dc2cf43c (127.0.0.1) 1.250000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for c01e3838-490c-4eb5-9195-8f7529fdbc6e 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c01e3838-490c-4eb5-9195-8f7529fdbc6e 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/c01e3838-490c-4eb5-9195-8f7529fdbc6e (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/c01e3838-490c-4eb5-9195-8f7529fdbc6e', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 256s yield maybe_future(km.shutdown_kernel(kernel_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 256s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 256s raise km.ready.exception() # type: ignore[misc] 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/c01e3838-490c-4eb5-9195-8f7529fdbc6e (127.0.0.1) 7.890000ms referer=None 256s --------------------------- Captured stderr teardown --------------------------- 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 256s from pathlib import Path 256s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 256s from ._local import * 256s File "/usr/lib/python3.13/pathlib/_local.py", line 6, in 256s import warnings 256s File "", line 1360, in _find_and_load 256s File "", line 1331, in _find_and_load_unlocked 256s File "", line 935, in _load_unlocked 256s File "", line 1019, in exec_module 256s File "", line 1115, in get_code 256s File "", line 1215, in get_data 256s KeyboardInterrupt 256s ____________________ AsyncKernelAPITest.test_kernel_handler ____________________ 256s 256s self = 256s 256s def test_kernel_handler(self): 256s # GET kernel with given id 256s kid = self.kern_api.start().json()['id'] 256s r = self.kern_api.get(kid) 256s kern1 = r.json() 256s self.assertEqual(r.status_code, 200) 256s assert isinstance(kern1, dict) 256s self.assertIn('id', kern1) 256s self.assertEqual(kern1['id'], kid) 256s 256s # Request a bad kernel id and check that a JSON 256s # message is returned! 256s bad_id = '111-111-111-111-111' 256s with assert_http_error(404, 'Kernel does not exist: ' + bad_id): 256s self.kern_api.get(bad_id) 256s 256s # DELETE kernel with id 256s > r = self.kern_api.shutdown(kid) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:169: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/df7aba8f-819a-4aae-8d6f-8b183b7048e5 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 256s from pathlib import Path 256s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 256s from ._abc import * 256s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 256s from glob import _Globber, _no_recurse_symlinks 256s File "/usr/lib/python3.13/glob.py", line 6, in 256s import fnmatch 256s File "", line 1360, in _find_and_load 256s File "", line 1331, in _find_and_load_unlocked 256s File "", line 935, in _load_unlocked 256s File "", line 1019, in exec_module 256s File "", line 1152, in get_code 256s File "", line 781, in _compile_bytecode 256s KeyboardInterrupt 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp0lmkbuy5/runtime/kernel-df7aba8f-819a-4aae-8d6f-8b183b7048e5.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:57301 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:57009 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: df7aba8f-819a-4aae-8d6f-8b183b7048e5, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 17.070000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/df7aba8f-819a-4aae-8d6f-8b183b7048e5 (127.0.0.1) 1.020000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s WARNING NotebookApp:web.py:1943 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1): Kernel does not exist: 111-111-111-111-111 256s WARNING NotebookApp:handlers.py:612 Kernel does not exist: 111-111-111-111-111 256s WARNING NotebookApp:log.py:59 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1) 1.210000ms referer=None 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for df7aba8f-819a-4aae-8d6f-8b183b7048e5 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: df7aba8f-819a-4aae-8d6f-8b183b7048e5 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/df7aba8f-819a-4aae-8d6f-8b183b7048e5 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/df7aba8f-819a-4aae-8d6f-8b183b7048e5', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 256s yield maybe_future(km.shutdown_kernel(kernel_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 256s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 256s raise km.ready.exception() # type: ignore[misc] 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/df7aba8f-819a-4aae-8d6f-8b183b7048e5 (127.0.0.1) 7.550000ms referer=None 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.110000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for c01e3838-490c-4eb5-9195-8f7529fdbc6e 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c01e3838-490c-4eb5-9195-8f7529fdbc6e 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/c01e3838-490c-4eb5-9195-8f7529fdbc6e (127.0.0.1) 1.120000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for df7aba8f-819a-4aae-8d6f-8b183b7048e5 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: df7aba8f-819a-4aae-8d6f-8b183b7048e5 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/df7aba8f-819a-4aae-8d6f-8b183b7048e5 (127.0.0.1) 1.110000ms 256s _________________ AsyncKernelAPITest.test_main_kernel_handler __________________ 256s 256s self = 256s 256s def test_main_kernel_handler(self): 256s # POST request 256s r = self.kern_api.start() 256s kern1 = r.json() 256s self.assertEqual(r.headers['location'], url_path_join(self.url_prefix, 'api/kernels', kern1['id'])) 256s self.assertEqual(r.status_code, 201) 256s self.assertIsInstance(kern1, dict) 256s 256s report_uri = url_path_join(self.url_prefix, 'api/security/csp-report') 256s expected_csp = '; '.join([ 256s "frame-ancestors 'self'", 256s 'report-uri ' + report_uri, 256s "default-src 'none'" 256s ]) 256s self.assertEqual(r.headers['Content-Security-Policy'], expected_csp) 256s 256s # GET request 256s r = self.kern_api.list() 256s self.assertEqual(r.status_code, 200) 256s assert isinstance(r.json(), list) 256s self.assertEqual(r.json()[0]['id'], kern1['id']) 256s self.assertEqual(r.json()[0]['name'], kern1['name']) 256s 256s # create another kernel and check that they both are added to the 256s # list of kernels from a GET request 256s kern2 = self.kern_api.start().json() 256s assert isinstance(kern2, dict) 256s r = self.kern_api.list() 256s kernels = r.json() 256s self.assertEqual(r.status_code, 200) 256s assert isinstance(kernels, list) 256s self.assertEqual(len(kernels), 2) 256s 256s # Interrupt a kernel 256s r = self.kern_api.interrupt(kern2['id']) 256s self.assertEqual(r.status_code, 204) 256s 256s # Restart a kernel 256s > r = self.kern_api.restart(kern2['id']) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:147: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:63: in restart 256s return self._req('POST', url_path_join(id, 'restart')) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: http://localhost:12341/a%40b/api/kernels/20811980-e7dc-40fa-9b87-cf7b007f7afe/restart 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 256s from pathlib import Path 256s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 256s from ._abc import * 256s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 256s from glob import _Globber, _no_recurse_symlinks 256s File "/usr/lib/python3.13/glob.py", line 3, in 256s import contextlib 256s File "", line 1360, in _find_and_load 256s File "", line 1331, in _find_and_load_unlocked 256s File "", line 935, in _load_unlocked 256s File "", line 1019, in exec_module 256s File "", line 1115, in get_code 256s File "", line 1214, in get_data 256s KeyboardInterrupt 256s Traceback (most recent call last): 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 256s from ipykernel import kernelapp as app 256s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 256s from .connect import * # noqa: F403 256s ^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 12, in 256s import jupyter_client 256s File "/usr/lib/python3/dist-packages/jupyter_client/__init__.py", line 4, in 256s from .asynchronous import AsyncKernelClient 256s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/__init__.py", line 1, in 256s from .client import AsyncKernelClient # noqa 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/client.py", line 9, in 256s import zmq.asyncio 256s File "/usr/lib/python3/dist-packages/zmq/__init__.py", line 86, in 256s DRAFT_API: bool = backend.has('draft') and backend.PYZMQ_DRAFT_API 256s ~~~~~~~~~~~^^^^^^^^^ 256s File "_zmq.py", line 1547, in zmq.backend.cython._zmq.has 256s File "/usr/lib/python3/dist-packages/zmq/error.py", line 211, in _check_version 256s from zmq import zmq_version_info 256s File "", line 471, in _lock_unlock_module 256s File "", line 316, in acquire 256s KeyboardInterrupt 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp0lmkbuy5/runtime/kernel-2ea1ef69-cbb2-4d40-a91e-e687bd997cc0.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55023 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:38821 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 2ea1ef69-cbb2-4d40-a91e-e687bd997cc0, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.390000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.060000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp0lmkbuy5/runtime/kernel-20811980-e7dc-40fa-9b87-cf7b007f7afe.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34677 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:57761 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 20811980-e7dc-40fa-9b87-cf7b007f7afe, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.720000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.980000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: 20811980-e7dc-40fa-9b87-cf7b007f7afe 256s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/20811980-e7dc-40fa-9b87-cf7b007f7afe/interrupt (127.0.0.1) 1.150000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 256s yield maybe_future(km.restart_kernel(kernel_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 291, in __step_run_and_handle_result 256s result = coro.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 256s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 256s File "/usr/lib/python3.14/asyncio/futures.py", line 295, in __await__ 256s yield self # This tells Task to wait for completion. 256s ^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 256s await ensure_async(kernel.restart_kernel(now=now)) 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 256s await self._async_shutdown_kernel(now=now, restart=True) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/20811980-e7dc-40fa-9b87-cf7b007f7afe/restart (127.0.0.1) 4.180000ms referer=None 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.020000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 2ea1ef69-cbb2-4d40-a91e-e687bd997cc0 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 2ea1ef69-cbb2-4d40-a91e-e687bd997cc0 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/2ea1ef69-cbb2-4d40-a91e-e687bd997cc0 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/2ea1ef69-cbb2-4d40-a91e-e687bd997cc0', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 256s yield maybe_future(km.shutdown_kernel(kernel_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 256s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 256s raise km.ready.exception() # type: ignore[misc] 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/2ea1ef69-cbb2-4d40-a91e-e687bd997cc0 (127.0.0.1) 7.420000ms referer=None 256s ______________________ AsyncKernelAPITest.test_no_kernels ______________________ 256s 256s self = 256s 256s def test_no_kernels(self): 256s """Make sure there are no kernels running at the start""" 256s kernels = self.kern_api.list().json() 256s > self.assertEqual(kernels, []) 256s E AssertionError: Lists differ: [{'id': '2ea1ef69-cbb2-4d40-a91e-e687bd997[281 chars]: 0}] != [] 256s E 256s E First list contains 2 additional elements. 256s E First extra element 0: 256s E {'id': '2ea1ef69-cbb2-4d40-a91e-e687bd997cc0', 'name': 'python3', 'last_activity': '2026-02-06T04:18:26.113385Z', 'execution_state': 'starting', 'connections': 0} 256s E 256s E + [] 256s E - [{'connections': 0, 256s E - 'execution_state': 'starting', 256s E - 'id': '2ea1ef69-cbb2-4d40-a91e-e687bd997cc0', 256s E - 'last_activity': '2026-02-06T04:18:26.113385Z', 256s E - 'name': 'python3'}, 256s E - {'connections': 0, 256s E - 'execution_state': 'starting', 256s E - 'id': '20811980-e7dc-40fa-9b87-cf7b007f7afe', 256s E - 'last_activity': '2026-02-06T04:18:26.136682Z', 256s E - 'name': 'python3'}] 256s 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:91: AssertionError 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.150000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.990000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 2ea1ef69-cbb2-4d40-a91e-e687bd997cc0 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 2ea1ef69-cbb2-4d40-a91e-e687bd997cc0 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/2ea1ef69-cbb2-4d40-a91e-e687bd997cc0 (127.0.0.1) 1.880000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 20811980-e7dc-40fa-9b87-cf7b007f7afe 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 20811980-e7dc-40fa-9b87-cf7b007f7afe 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/20811980-e7dc-40fa-9b87-cf7b007f7afe (127.0.0.1) 1.310000ms 256s ---------------------------- Captured log teardown ----------------------------- 256s INFO NotebookApp:notebookapp.py:2164 Shutting down 0 kernels 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c01e3838-490c-4eb5-9195-8f7529fdbc6e 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 2ea1ef69-cbb2-4d40-a91e-e687bd997cc0 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 63b5d7a3-b558-48b5-841b-7526dc2cf43c 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: df7aba8f-819a-4aae-8d6f-8b183b7048e5 256s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 256s __________________________ SessionAPITest.test_create __________________________ 256s 256s @self.addCleanup 256s def cleanup_sessions(): 256s for session in self.sess_api.list().json(): 256s > self.sess_api.delete(session['id']) 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/031ebc57-b8de-4541-a12e-f31c4ea0ff33 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ------------------------------ Captured log setup ------------------------------ 256s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmpcqkf_mv7/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmpcqkf_mv7/etc/jupyter'] for config files 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpcqkf_mv7/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpcqkf_mv7/config 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpcqkf_mv7/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpcqkf_mv7/config 256s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmpcqkf_mv7/notebooks 256s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 256s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 256s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 256s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 256s WARNING NotebookApp:handlers.py:612 Forbidden 256s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 0.740000ms referer=None 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.310000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcqkf_mv7/runtime/kernel-bc6b44ff-e7be-48a9-acdd-074b5c575885.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:49385 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55271 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: bc6b44ff-e7be-48a9-acdd-074b5c575885, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpcqkf_mv7/notebooks/foo'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 19.440000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.790000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions/031ebc57-b8de-4541-a12e-f31c4ea0ff33 (127.0.0.1) 1.350000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.000000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for bc6b44ff-e7be-48a9-acdd-074b5c575885 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: bc6b44ff-e7be-48a9-acdd-074b5c575885 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/031ebc57-b8de-4541-a12e-f31c4ea0ff33 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/031ebc57-b8de-4541-a12e-f31c4ea0ff33', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 256s yielded = self.gen.send(value) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 256s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 256s stopper = ensure_async(km.shutdown_kernel(now, restart)) 256s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/031ebc57-b8de-4541-a12e-f31c4ea0ff33 (127.0.0.1) 9.250000ms referer=None 256s --------------------------- Captured stderr teardown --------------------------- 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 256s from ipykernel import kernelapp as app 256s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 256s from .connect import * # noqa: F403 256s ^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 7, in 256s import json 256s File "/usr/lib/python3.13/json/__init__.py", line 107, in 256s from .encoder import JSONEncoder 256s File "", line 1360, in _find_and_load 256s File "", line 1331, in _find_and_load_unlocked 256s File "", line 935, in _load_unlocked 256s File "", line 1019, in exec_module 256s File "", line 1115, in get_code 256s File "", line 1215, in get_data 256s KeyboardInterrupt 256s __________________ SessionAPITest.test_create_console_session __________________ 256s 256s @self.addCleanup 256s def cleanup_sessions(): 256s for session in self.sess_api.list().json(): 256s > self.sess_api.delete(session['id']) 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/1aa456ee-abb9-43a3-8ebf-fae15314781e 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcqkf_mv7/runtime/kernel-2fa105a0-f125-4e38-90b9-752aa4b8b809.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:50703 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:50877 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 2fa105a0-f125-4e38-90b9-752aa4b8b809, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpcqkf_mv7/notebooks/foo'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 17.670000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 0.950000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for bc6b44ff-e7be-48a9-acdd-074b5c575885 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: bc6b44ff-e7be-48a9-acdd-074b5c575885 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/031ebc57-b8de-4541-a12e-f31c4ea0ff33 (127.0.0.1) 1.470000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 2fa105a0-f125-4e38-90b9-752aa4b8b809 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 2fa105a0-f125-4e38-90b9-752aa4b8b809 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/1aa456ee-abb9-43a3-8ebf-fae15314781e (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/1aa456ee-abb9-43a3-8ebf-fae15314781e', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 256s yielded = self.gen.send(value) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 256s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 256s stopper = ensure_async(km.shutdown_kernel(now, restart)) 256s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/1aa456ee-abb9-43a3-8ebf-fae15314781e (127.0.0.1) 9.710000ms referer=None 256s --------------------------- Captured stderr teardown --------------------------- 256s Traceback (most recent call last): 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 256s from pathlib import Path 256s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 256s from ._abc import * 256s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 256s from glob import _Globber, _no_recurse_symlinks 256s File "/usr/lib/python3.13/glob.py", line 237, in 256s magic_check_bytes = re.compile(b'([*?[])') 256s File "/usr/lib/python3.13/re/__init__.py", line 289, in compile 256s return _compile(pattern, flags) 256s File "/usr/lib/python3.13/re/__init__.py", line 350, in _compile 256s p = _compiler.compile(pattern, flags) 256s File "/usr/lib/python3.13/re/_compiler.py", line 748, in compile 256s p = _parser.parse(p, flags) 256s File "/usr/lib/python3.13/re/_parser.py", line 980, in parse 256s p = _parse_sub(source, state, flags & SRE_FLAG_VERBOSE, 0) 256s File "/usr/lib/python3.13/re/_parser.py", line 459, in _parse_sub 256s itemsappend(_parse(source, state, verbose, nested + 1, 256s ~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s not nested and not items)) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3.13/re/_parser.py", line 873, in _parse 256s subpatternappend((SUBPATTERN, (group, add_flags, del_flags, p))) 256s ~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3.13/re/_parser.py", line 175, in append 256s def append(self, code): 256s 256s KeyboardInterrupt 256s ____________________ SessionAPITest.test_create_deprecated _____________________ 256s 256s @self.addCleanup 256s def cleanup_sessions(): 256s for session in self.sess_api.list().json(): 256s > self.sess_api.delete(session['id']) 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/6ae22834-48af-4b70-9264-bf4c0804a2f1 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s WARNING NotebookApp:handlers.py:46 Sessions API changed, see updated swagger docs 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcqkf_mv7/runtime/kernel-4f302d95-3d68-4841-8d89-cb0951b95bb1.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:46691 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:36069 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 4f302d95-3d68-4841-8d89-cb0951b95bb1, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpcqkf_mv7/notebooks/foo'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 17.870000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.220000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 2fa105a0-f125-4e38-90b9-752aa4b8b809 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 2fa105a0-f125-4e38-90b9-752aa4b8b809 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/1aa456ee-abb9-43a3-8ebf-fae15314781e (127.0.0.1) 1.410000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 4f302d95-3d68-4841-8d89-cb0951b95bb1 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 4f302d95-3d68-4841-8d89-cb0951b95bb1 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/6ae22834-48af-4b70-9264-bf4c0804a2f1 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/6ae22834-48af-4b70-9264-bf4c0804a2f1', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 256s yielded = self.gen.send(value) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 256s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 256s stopper = ensure_async(km.shutdown_kernel(now, restart)) 256s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/6ae22834-48af-4b70-9264-bf4c0804a2f1 (127.0.0.1) 8.670000ms referer=None 256s --------------------------- Captured stderr teardown --------------------------- 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 256s from pathlib import Path 256s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 256s from ._abc import * 256s File "", line 1357, in _find_and_load 256s File "", line 421, in __exit__ 256s File "", line 378, in release 256s KeyboardInterrupt 256s ___________________ SessionAPITest.test_create_file_session ____________________ 256s 256s @self.addCleanup 256s def cleanup_sessions(): 256s for session in self.sess_api.list().json(): 256s > self.sess_api.delete(session['id']) 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/5b494814-58d8-4639-aca2-5796c23fb81a 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcqkf_mv7/runtime/kernel-812bee6b-f1a7-46ab-a9bc-f71801c62b45.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:37109 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:54671 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 812bee6b-f1a7-46ab-a9bc-f71801c62b45, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpcqkf_mv7/notebooks/foo'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 18.540000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.050000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 4f302d95-3d68-4841-8d89-cb0951b95bb1 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 4f302d95-3d68-4841-8d89-cb0951b95bb1 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/6ae22834-48af-4b70-9264-bf4c0804a2f1 (127.0.0.1) 1.580000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 812bee6b-f1a7-46ab-a9bc-f71801c62b45 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 812bee6b-f1a7-46ab-a9bc-f71801c62b45 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/5b494814-58d8-4639-aca2-5796c23fb81a (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/5b494814-58d8-4639-aca2-5796c23fb81a', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 256s yielded = self.gen.send(value) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 256s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 256s stopper = ensure_async(km.shutdown_kernel(now, restart)) 256s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/5b494814-58d8-4639-aca2-5796c23fb81a (127.0.0.1) 8.510000ms referer=None 256s --------------------------- Captured stderr teardown --------------------------- 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 256s from pathlib import Path 256s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 256s from ._local import * 256s File "/usr/lib/python3.13/pathlib/_local.py", line 6, in 256s import warnings 256s File "", line 1360, in _find_and_load 256s File "", line 1331, in _find_and_load_unlocked 256s File "", line 935, in _load_unlocked 256s File "", line 1019, in exec_module 256s File "", line 1115, in get_code 256s File "", line 1214, in get_data 256s KeyboardInterrupt 256s __________________ SessionAPITest.test_create_with_kernel_id ___________________ 256s 256s self = 256s 256s def test_create_with_kernel_id(self): 256s # create a new kernel 256s r = self.request('POST', 'api/kernels') 256s r.raise_for_status() 256s kernel = r.json() 256s 256s resp = self.sess_api.create('foo/nb1.ipynb', kernel_id=kernel['id']) 256s self.assertEqual(resp.status_code, 201) 256s newsession = resp.json() 256s self.assertIn('id', newsession) 256s self.assertEqual(newsession['path'], 'foo/nb1.ipynb') 256s self.assertEqual(newsession['kernel']['id'], kernel['id']) 256s self.assertEqual(resp.headers['Location'], f'{self.url_prefix}api/sessions/{newsession["id"]}') 256s 256s sessions = self.sess_api.list().json() 256s > self.assertEqual(sessions, [newsession]) 256s E AssertionError: Lists differ: [{'id': '5b494814-58d8-4639-aca2-5796c23fb81a', 'p[553 chars]ne}}] != [{'id': '4246b68b-5a59-44db-86c7-b7b154cf3598', 'p[279 chars]ne}}] 256s E 256s E First differing element 0: 256s E {'id': '5b494814-58d8-4639-aca2-5796c23fb81a', 'p[218 chars]: 0}} 256s E {'id': '4246b68b-5a59-44db-86c7-b7b154cf3598', 'p[278 chars]one}} 256s E 256s E First list contains 1 additional elements. 256s E First extra element 1: 256s E {'id': '4246b68b-5a59-44db-86c7-b7b154cf3598', 'path': 'foo/nb1.ipynb', 'name': None, 'type': 'notebook', 'kernel': {'id': 'd6da1137-69f4-47f6-bb7e-c7be59058439', 'name': 'python3', 'last_activity': '2026-02-06T04:18:36.718271Z', 'execution_state': 'starting', 'connections': 0}, 'notebook': {'path': 'foo/nb1.ipynb', 'name': None}} 256s E 256s E Diff is 830 characters long. Set self.maxDiff to None to see it. 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:178: AssertionError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcqkf_mv7/runtime/kernel-d6da1137-69f4-47f6-bb7e-c7be59058439.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:39185 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34491 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: d6da1137-69f4-47f6-bb7e-c7be59058439, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 27.480000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.120000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.030000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.060000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 812bee6b-f1a7-46ab-a9bc-f71801c62b45 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 812bee6b-f1a7-46ab-a9bc-f71801c62b45 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/5b494814-58d8-4639-aca2-5796c23fb81a (127.0.0.1) 1.450000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for d6da1137-69f4-47f6-bb7e-c7be59058439 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: d6da1137-69f4-47f6-bb7e-c7be59058439 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/4246b68b-5a59-44db-86c7-b7b154cf3598 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/4246b68b-5a59-44db-86c7-b7b154cf3598', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 256s yielded = self.gen.send(value) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 256s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 256s stopper = ensure_async(km.shutdown_kernel(now, restart)) 256s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/4246b68b-5a59-44db-86c7-b7b154cf3598 (127.0.0.1) 8.570000ms referer=None 256s _____________________ SessionAPITest.test_modify_kernel_id _____________________ 256s 256s self = 256s 256s def test_modify_kernel_id(self): 256s before = self.sess_api.create('foo/nb1.ipynb').json() 256s sid = before['id'] 256s 256s # create a new kernel 256s r = self.request('POST', 'api/kernels') 256s r.raise_for_status() 256s kernel = r.json() 256s 256s # Attach our session to the existing kernel 256s > after = self.sess_api.modify_kernel_id(sid, kernel['id']).json() 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:250: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:82: in modify_kernel_id 256s return self._req('PATCH', id, body) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 256s from ipykernel import kernelapp as app 256s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 256s from .connect import * # noqa: F403 256s ^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 12, in 256s import jupyter_client 256s File "/usr/lib/python3/dist-packages/jupyter_client/__init__.py", line 4, in 256s from .asynchronous import AsyncKernelClient 256s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/__init__.py", line 1, in 256s from .client import AsyncKernelClient # noqa 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/client.py", line 9, in 256s import zmq.asyncio 256s File "", line 1360, in _find_and_load 256s File "", line 1331, in _find_and_load_unlocked 256s File "", line 935, in _load_unlocked 256s File "", line 1019, in exec_module 256s File "", line 1109, in get_code 256s File "", line 1232, in path_stats 256s File "", line 152, in _path_stat 256s KeyboardInterrupt 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcqkf_mv7/runtime/kernel-a60b5ada-a0ab-466b-8b02-c67a7d5bdaa2.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:49287 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:52985 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: a60b5ada-a0ab-466b-8b02-c67a7d5bdaa2, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpcqkf_mv7/notebooks/foo'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 17.940000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcqkf_mv7/runtime/kernel-8394ace2-9e71-4fad-9254-122f4049e432.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:41107 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:50221 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 8394ace2-9e71-4fad-9254-122f4049e432, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 19.690000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for a60b5ada-a0ab-466b-8b02-c67a7d5bdaa2 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a60b5ada-a0ab-466b-8b02-c67a7d5bdaa2 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception PATCH /a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='PATCH', uri='/a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 256s yielded = self.gen.send(value) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 154, in patch 256s km.shutdown_kernel(before['kernel']['id']) 256s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 256s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 256s stopper = ensure_async(km.shutdown_kernel(now, restart)) 256s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 PATCH /a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd (127.0.0.1) 9.860000ms referer=None 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.120000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 8394ace2-9e71-4fad-9254-122f4049e432 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 8394ace2-9e71-4fad-9254-122f4049e432 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 256s yielded = self.gen.send(value) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 256s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 256s stopper = ensure_async(km.shutdown_kernel(now, restart)) 256s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd (127.0.0.1) 8.580000ms referer=None 256s ____________________ SessionAPITest.test_modify_kernel_name ____________________ 256s 256s self = 256s 256s def test_modify_kernel_name(self): 256s before = self.sess_api.create('foo/nb1.ipynb').json() 256s sid = before['id'] 256s 256s after = self.sess_api.modify_kernel_name(sid, before['kernel']['name']).json() 256s self.assertEqual(after['id'], sid) 256s self.assertEqual(after['path'], before['path']) 256s self.assertEqual(after['type'], before['type']) 256s self.assertNotEqual(after['kernel']['id'], before['kernel']['id']) 256s 256s # check kernel list, to be sure previous kernel was cleaned up 256s r = self.request('GET', 'api/kernels') 256s r.raise_for_status() 256s kernel_list = r.json() 256s after['kernel'].pop('last_activity') 256s [ k.pop('last_activity') for k in kernel_list ] 256s > self.assertEqual(kernel_list, [after['kernel']]) 256s E AssertionError: Lists differ: [{'id': 'a60b5ada-a0ab-466b-8b02-c67a7d5bdaa2', 'n[177 chars]: 0}] != [{'id': 'c83ed830-c109-4c05-9c37-7254a77caeae', 'n[61 chars]: 0}] 256s E 256s E First differing element 0: 256s E {'id': 'a60b5ada-a0ab-466b-8b02-c67a7d5bdaa2', 'n[60 chars]': 0} 256s E {'id': 'c83ed830-c109-4c05-9c37-7254a77caeae', 'n[60 chars]': 0} 256s E 256s E First list contains 1 additional elements. 256s E First extra element 1: 256s E {'id': 'c83ed830-c109-4c05-9c37-7254a77caeae', 'name': 'python3', 'execution_state': 'starting', 'connections': 0} 256s E 256s E [{'connections': 0, 256s E - 'execution_state': 'starting', 256s E - 'id': 'a60b5ada-a0ab-466b-8b02-c67a7d5bdaa2', 256s E - 'name': 'python3'}, 256s E - {'connections': 0, 256s E 'execution_state': 'starting', 256s E 'id': 'c83ed830-c109-4c05-9c37-7254a77caeae', 256s E 'name': 'python3'}] 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:238: AssertionError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.180000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcqkf_mv7/runtime/kernel-c83ed830-c109-4c05-9c37-7254a77caeae.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34069 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:54627 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: c83ed830-c109-4c05-9c37-7254a77caeae, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3', 'cwd': '/tmp/tmpcqkf_mv7/notebooks/foo'} 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 8394ace2-9e71-4fad-9254-122f4049e432 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 8394ace2-9e71-4fad-9254-122f4049e432 256s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd (127.0.0.1) 18.880000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.980000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.080000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for c83ed830-c109-4c05-9c37-7254a77caeae 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c83ed830-c109-4c05-9c37-7254a77caeae 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 256s yielded = self.gen.send(value) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 256s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 256s stopper = ensure_async(km.shutdown_kernel(now, restart)) 256s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/32b2801c-e6eb-4c0e-b483-9ad866d141dd (127.0.0.1) 8.350000ms referer=None 256s __________________ SessionAPITest.test_modify_path_deprecated __________________ 256s 256s @self.addCleanup 256s def cleanup_sessions(): 256s for session in self.sess_api.list().json(): 256s > self.sess_api.delete(session['id']) 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/e49942a0-6beb-41a1-a92b-ea996e709aa0 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 256s from pathlib import Path 256s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 256s from ._local import * 256s File "/usr/lib/python3.13/pathlib/_local.py", line 12, in 256s import pwd 256s KeyboardInterrupt 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcqkf_mv7/runtime/kernel-61d9e114-c550-487b-bd27-749763247bb3.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:41855 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:57259 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 61d9e114-c550-487b-bd27-749763247bb3, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpcqkf_mv7/notebooks/foo'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 19.500000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s WARNING NotebookApp:handlers.py:124 Sessions API changed, see updated swagger docs 256s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/e49942a0-6beb-41a1-a92b-ea996e709aa0 (127.0.0.1) 1.380000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.080000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 61d9e114-c550-487b-bd27-749763247bb3 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 61d9e114-c550-487b-bd27-749763247bb3 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/e49942a0-6beb-41a1-a92b-ea996e709aa0 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/e49942a0-6beb-41a1-a92b-ea996e709aa0', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 256s yielded = self.gen.send(value) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 256s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 256s stopper = ensure_async(km.shutdown_kernel(now, restart)) 256s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/e49942a0-6beb-41a1-a92b-ea996e709aa0 (127.0.0.1) 8.950000ms referer=None 256s _______________________ SessionAPITest.test_modify_type ________________________ 256s 256s @self.addCleanup 256s def cleanup_sessions(): 256s for session in self.sess_api.list().json(): 256s > self.sess_api.delete(session['id']) 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/8fc88ea5-8b27-4e1d-afce-0aa81ffd71a2 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcqkf_mv7/runtime/kernel-9fb80fbb-8872-4e5e-a1ed-d81c7a9fb5da.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:43715 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:38935 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 9fb80fbb-8872-4e5e-a1ed-d81c7a9fb5da, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpcqkf_mv7/notebooks/foo'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 21.080000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/8fc88ea5-8b27-4e1d-afce-0aa81ffd71a2 (127.0.0.1) 2.070000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.060000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 61d9e114-c550-487b-bd27-749763247bb3 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 61d9e114-c550-487b-bd27-749763247bb3 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/e49942a0-6beb-41a1-a92b-ea996e709aa0 (127.0.0.1) 1.710000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 9fb80fbb-8872-4e5e-a1ed-d81c7a9fb5da 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 9fb80fbb-8872-4e5e-a1ed-d81c7a9fb5da 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/8fc88ea5-8b27-4e1d-afce-0aa81ffd71a2 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/8fc88ea5-8b27-4e1d-afce-0aa81ffd71a2', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 256s yielded = self.gen.send(value) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 256s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 256s stopper = ensure_async(km.shutdown_kernel(now, restart)) 256s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 256s return _runner_map[name].run(inner) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 256s return fut.result(None) 256s ~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 256s return self.__get_result() 256s ~~~~~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 256s raise self._exception 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/8fc88ea5-8b27-4e1d-afce-0aa81ffd71a2 (127.0.0.1) 8.550000ms referer=None 256s --------------------------- Captured stderr teardown --------------------------- 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 256s from pathlib import Path 256s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 256s from ._local import * 256s File "/usr/lib/python3.13/pathlib/_local.py", line 473, in 256s class PureWindowsPath(PurePath): 256s ...<7 lines>... 256s __slots__ = () 256s File "/usr/lib/python3.13/pathlib/_local.py", line 479, in PureWindowsPath 256s import ntpath 256s File "/usr/lib/python3.13/ntpath.py", line 45, in 256s from _winapi import ( 256s ...<2 lines>... 256s LCMAP_LOWERCASE as _LCMAP_LOWERCASE) 256s File "", line 1360, in _find_and_load 256s File "", line 1322, in _find_and_load_unlocked 256s File "", line 1262, in _find_spec 256s File "", line 1556, in find_spec 256s File "", line 1530, in _get_spec 256s File "", line 1629, in find_spec 256s File "", line 152, in _path_stat 256s KeyboardInterrupt 256s ---------------------------- Captured log teardown ----------------------------- 256s INFO NotebookApp:notebookapp.py:2164 Shutting down 2 kernels 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a60b5ada-a0ab-466b-8b02-c67a7d5bdaa2 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 9fb80fbb-8872-4e5e-a1ed-d81c7a9fb5da 256s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 256s _______________________ AsyncSessionAPITest.test_create ________________________ 256s 256s @self.addCleanup 256s def cleanup_sessions(): 256s for session in self.sess_api.list().json(): 256s > self.sess_api.delete(session['id']) 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/88c926ec-1904-455c-a2ab-2b8e82f39af4 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ------------------------------ Captured log setup ------------------------------ 256s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmpkhe726bz/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmpkhe726bz/etc/jupyter'] for config files 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpkhe726bz/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpkhe726bz/config 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpkhe726bz/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 256s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpkhe726bz/config 256s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmpkhe726bz/notebooks 256s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 256s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 256s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 256s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 256s WARNING NotebookApp:handlers.py:612 Forbidden 256s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 0.850000ms referer=None 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.250000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkhe726bz/runtime/kernel-28cc8706-ee43-447e-8d04-75caf12fb1ad.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:53111 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:38619 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 28cc8706-ee43-447e-8d04-75caf12fb1ad, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpkhe726bz/notebooks/foo'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 17.560000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.450000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions/88c926ec-1904-455c-a2ab-2b8e82f39af4 (127.0.0.1) 1.420000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 0.980000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 28cc8706-ee43-447e-8d04-75caf12fb1ad 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 28cc8706-ee43-447e-8d04-75caf12fb1ad 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/88c926ec-1904-455c-a2ab-2b8e82f39af4 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/88c926ec-1904-455c-a2ab-2b8e82f39af4', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 256s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 256s raise km.ready.exception() # type: ignore[misc] 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/88c926ec-1904-455c-a2ab-2b8e82f39af4 (127.0.0.1) 7.980000ms referer=None 256s --------------------------- Captured stderr teardown --------------------------- 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 256s from ipykernel import kernelapp as app 256s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 1, in 256s from ._version import ( 256s ...<4 lines>... 256s ) 256s File "", line 1360, in _find_and_load 256s File "", line 1331, in _find_and_load_unlocked 256s File "", line 935, in _load_unlocked 256s File "", line 1019, in exec_module 256s File "", line 1109, in get_code 256s File "", line 1232, in path_stats 256s File "", line 152, in _path_stat 256s KeyboardInterrupt 256s _______________ AsyncSessionAPITest.test_create_console_session ________________ 256s 256s @self.addCleanup 256s def cleanup_sessions(): 256s for session in self.sess_api.list().json(): 256s > self.sess_api.delete(session['id']) 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/90f0fe4f-946a-48a4-a95f-3ad8abe6410f 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkhe726bz/runtime/kernel-9f9ca658-53a0-441c-b83b-d909183f539d.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:56227 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:44653 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 9f9ca658-53a0-441c-b83b-d909183f539d, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpkhe726bz/notebooks/foo'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 21.250000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.470000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 28cc8706-ee43-447e-8d04-75caf12fb1ad 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 28cc8706-ee43-447e-8d04-75caf12fb1ad 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/88c926ec-1904-455c-a2ab-2b8e82f39af4 (127.0.0.1) 1.710000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 9f9ca658-53a0-441c-b83b-d909183f539d 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 9f9ca658-53a0-441c-b83b-d909183f539d 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/90f0fe4f-946a-48a4-a95f-3ad8abe6410f (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/90f0fe4f-946a-48a4-a95f-3ad8abe6410f', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 256s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 256s raise km.ready.exception() # type: ignore[misc] 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/90f0fe4f-946a-48a4-a95f-3ad8abe6410f (127.0.0.1) 8.290000ms referer=None 256s --------------------------- Captured stderr teardown --------------------------- 256s Traceback (most recent call last): 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 256s from pathlib import Path 256s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 256s from ._abc import * 256s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 256s from glob import _Globber, _no_recurse_symlinks 256s File "/usr/lib/python3.13/glob.py", line 5, in 256s import re 256s File "/usr/lib/python3.13/re/__init__.py", line 143, in 256s @enum._simple_enum(enum.IntFlag, boundary=enum.KEEP) 256s ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3.13/enum.py", line 1814, in convert_class 256s setattr(enum_class, name, enum_method) 256s ~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3.13/enum.py", line 840, in __setattr__ 256s super().__setattr__(name, value) 256s ~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^ 256s KeyboardInterrupt 256s __________________ AsyncSessionAPITest.test_create_deprecated __________________ 256s 256s @self.addCleanup 256s def cleanup_sessions(): 256s for session in self.sess_api.list().json(): 256s > self.sess_api.delete(session['id']) 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/80f5231c-0b99-45b2-976a-024116390025 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s WARNING NotebookApp:handlers.py:46 Sessions API changed, see updated swagger docs 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkhe726bz/runtime/kernel-a880bc78-005e-4ef6-97b2-102857565ff5.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:35647 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:43567 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: a880bc78-005e-4ef6-97b2-102857565ff5, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpkhe726bz/notebooks/foo'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 17.340000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.090000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 9f9ca658-53a0-441c-b83b-d909183f539d 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 9f9ca658-53a0-441c-b83b-d909183f539d 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/90f0fe4f-946a-48a4-a95f-3ad8abe6410f (127.0.0.1) 1.250000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for a880bc78-005e-4ef6-97b2-102857565ff5 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a880bc78-005e-4ef6-97b2-102857565ff5 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/80f5231c-0b99-45b2-976a-024116390025 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/80f5231c-0b99-45b2-976a-024116390025', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 256s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 256s raise km.ready.exception() # type: ignore[misc] 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/80f5231c-0b99-45b2-976a-024116390025 (127.0.0.1) 8.130000ms referer=None 256s --------------------------- Captured stderr teardown --------------------------- 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 256s from pathlib import Path 256s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 256s from ._abc import * 256s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 256s from glob import _Globber, _no_recurse_symlinks 256s File "/usr/lib/python3.13/glob.py", line 5, in 256s import re 256s File "/usr/lib/python3.13/re/__init__.py", line 143, in 256s @enum._simple_enum(enum.IntFlag, boundary=enum.KEEP) 256s ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3.13/enum.py", line 1844, in convert_class 256s contained._add_alias_(name) 256s ~~~~~~~~~~~~~~~~~~~~~^^^^^^ 256s File "/usr/lib/python3.13/enum.py", line 1221, in _add_alias_ 256s self.__class__._add_member_(name, self) 256s ~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^ 256s File "/usr/lib/python3.13/enum.py", line 1071, in _add_member_ 256s attr = base.__dict__.get(name) 256s KeyboardInterrupt 256s _________________ AsyncSessionAPITest.test_create_file_session _________________ 256s 256s @self.addCleanup 256s def cleanup_sessions(): 256s for session in self.sess_api.list().json(): 256s > self.sess_api.delete(session['id']) 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/48de1307-3bd3-4f84-b377-a32302296ea8 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkhe726bz/runtime/kernel-870d4235-a112-4d53-a325-4823b769d30e.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:57611 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:40639 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 870d4235-a112-4d53-a325-4823b769d30e, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpkhe726bz/notebooks/foo'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 17.080000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.030000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for a880bc78-005e-4ef6-97b2-102857565ff5 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a880bc78-005e-4ef6-97b2-102857565ff5 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/80f5231c-0b99-45b2-976a-024116390025 (127.0.0.1) 1.280000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 870d4235-a112-4d53-a325-4823b769d30e 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 870d4235-a112-4d53-a325-4823b769d30e 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/48de1307-3bd3-4f84-b377-a32302296ea8 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/48de1307-3bd3-4f84-b377-a32302296ea8', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 256s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 256s raise km.ready.exception() # type: ignore[misc] 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/48de1307-3bd3-4f84-b377-a32302296ea8 (127.0.0.1) 7.970000ms referer=None 256s --------------------------- Captured stderr teardown --------------------------- 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 256s from pathlib import Path 256s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 256s from ._abc import * 256s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 256s from glob import _Globber, _no_recurse_symlinks 256s File "/usr/lib/python3.13/glob.py", line 337, in 256s class _Globber: 256s ...<192 lines>... 256s pass 256s File "/usr/lib/python3.13/glob.py", line 349, in _Globber 256s lstat = operator.methodcaller('lstat') 256s KeyboardInterrupt 256s ________________ AsyncSessionAPITest.test_create_with_kernel_id ________________ 256s 256s self = 256s 256s def test_create_with_kernel_id(self): 256s # create a new kernel 256s r = self.request('POST', 'api/kernels') 256s r.raise_for_status() 256s kernel = r.json() 256s 256s resp = self.sess_api.create('foo/nb1.ipynb', kernel_id=kernel['id']) 256s self.assertEqual(resp.status_code, 201) 256s newsession = resp.json() 256s self.assertIn('id', newsession) 256s self.assertEqual(newsession['path'], 'foo/nb1.ipynb') 256s self.assertEqual(newsession['kernel']['id'], kernel['id']) 256s self.assertEqual(resp.headers['Location'], f'{self.url_prefix}api/sessions/{newsession["id"]}') 256s 256s sessions = self.sess_api.list().json() 256s > self.assertEqual(sessions, [newsession]) 256s E AssertionError: Lists differ: [{'id': '48de1307-3bd3-4f84-b377-a32302296ea8', 'p[553 chars]ne}}] != [{'id': '0846bc91-8647-408d-bc1b-f4d9ce6ec2ac', 'p[279 chars]ne}}] 256s E 256s E First differing element 0: 256s E {'id': '48de1307-3bd3-4f84-b377-a32302296ea8', 'p[218 chars]: 0}} 256s E {'id': '0846bc91-8647-408d-bc1b-f4d9ce6ec2ac', 'p[278 chars]one}} 256s E 256s E First list contains 1 additional elements. 256s E First extra element 1: 256s E {'id': '0846bc91-8647-408d-bc1b-f4d9ce6ec2ac', 'path': 'foo/nb1.ipynb', 'name': None, 'type': 'notebook', 'kernel': {'id': 'e4652af5-f608-4843-bcbb-87f813fa42ac', 'name': 'python3', 'last_activity': '2026-02-06T04:18:37.779224Z', 'execution_state': 'starting', 'connections': 0}, 'notebook': {'path': 'foo/nb1.ipynb', 'name': None}} 256s E 256s E Diff is 830 characters long. Set self.maxDiff to None to see it. 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:178: AssertionError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkhe726bz/runtime/kernel-e4652af5-f608-4843-bcbb-87f813fa42ac.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:39067 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:54493 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: e4652af5-f608-4843-bcbb-87f813fa42ac, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.300000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.270000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.040000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.020000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 870d4235-a112-4d53-a325-4823b769d30e 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 870d4235-a112-4d53-a325-4823b769d30e 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/48de1307-3bd3-4f84-b377-a32302296ea8 (127.0.0.1) 1.260000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for e4652af5-f608-4843-bcbb-87f813fa42ac 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: e4652af5-f608-4843-bcbb-87f813fa42ac 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/0846bc91-8647-408d-bc1b-f4d9ce6ec2ac (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/0846bc91-8647-408d-bc1b-f4d9ce6ec2ac', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 256s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 256s raise km.ready.exception() # type: ignore[misc] 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/0846bc91-8647-408d-bc1b-f4d9ce6ec2ac (127.0.0.1) 8.150000ms referer=None 256s __________________ AsyncSessionAPITest.test_modify_kernel_id ___________________ 256s 256s self = 256s 256s def test_modify_kernel_id(self): 256s before = self.sess_api.create('foo/nb1.ipynb').json() 256s sid = before['id'] 256s 256s # create a new kernel 256s r = self.request('POST', 'api/kernels') 256s r.raise_for_status() 256s kernel = r.json() 256s 256s # Attach our session to the existing kernel 256s > after = self.sess_api.modify_kernel_id(sid, kernel['id']).json() 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:250: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:82: in modify_kernel_id 256s return self._req('PATCH', id, body) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 256s from ipykernel import kernelapp as app 256s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 256s from .connect import * # noqa: F403 256s ^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 10, in 256s from typing import TYPE_CHECKING, Any 256s File "/usr/lib/python3.13/typing.py", line 2174, in 256s class Protocol(Generic, metaclass=_ProtocolMeta): 256s ...<49 lines>... 256s cls.__init__ = _no_init_or_replace_init 256s File "/usr/lib/python3.13/typing.py", line 2083, in __new__ 256s return super().__new__(mcls, name, bases, namespace, **kwargs) 256s ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3.13/abc.py", line 106, in __new__ 256s cls = super().__new__(mcls, name, bases, namespace, **kwargs) 256s File "", line 463, in _lock_unlock_module 256s KeyboardInterrupt 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkhe726bz/runtime/kernel-a629dc73-d6df-4973-912a-e0f27664136c.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55737 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:49375 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: a629dc73-d6df-4973-912a-e0f27664136c, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpkhe726bz/notebooks/foo'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 16.720000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkhe726bz/runtime/kernel-dd2f98a7-54fc-4c31-94ad-007d50d960ae.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:42993 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:60071 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: dd2f98a7-54fc-4c31-94ad-007d50d960ae, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.280000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for a629dc73-d6df-4973-912a-e0f27664136c 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a629dc73-d6df-4973-912a-e0f27664136c 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception PATCH /a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='PATCH', uri='/a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 153, in patch 256s yield maybe_future( 256s km.shutdown_kernel(before['kernel']['id']) 256s ) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 256s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 256s raise km.ready.exception() # type: ignore[misc] 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 PATCH /a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9 (127.0.0.1) 7.660000ms referer=None 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 0.960000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for dd2f98a7-54fc-4c31-94ad-007d50d960ae 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: dd2f98a7-54fc-4c31-94ad-007d50d960ae 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 256s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 256s raise km.ready.exception() # type: ignore[misc] 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9 (127.0.0.1) 8.240000ms referer=None 256s _________________ AsyncSessionAPITest.test_modify_kernel_name __________________ 256s 256s self = 256s 256s def test_modify_kernel_name(self): 256s before = self.sess_api.create('foo/nb1.ipynb').json() 256s sid = before['id'] 256s 256s after = self.sess_api.modify_kernel_name(sid, before['kernel']['name']).json() 256s self.assertEqual(after['id'], sid) 256s self.assertEqual(after['path'], before['path']) 256s self.assertEqual(after['type'], before['type']) 256s self.assertNotEqual(after['kernel']['id'], before['kernel']['id']) 256s 256s # check kernel list, to be sure previous kernel was cleaned up 256s r = self.request('GET', 'api/kernels') 256s r.raise_for_status() 256s kernel_list = r.json() 256s after['kernel'].pop('last_activity') 256s [ k.pop('last_activity') for k in kernel_list ] 256s > self.assertEqual(kernel_list, [after['kernel']]) 256s E AssertionError: Lists differ: [{'id': 'a629dc73-d6df-4973-912a-e0f27664136c', 'n[177 chars]: 0}] != [{'id': '5f19324d-14b4-4279-80bb-058bc71fa7c0', 'n[61 chars]: 0}] 256s E 256s E First differing element 0: 256s E {'id': 'a629dc73-d6df-4973-912a-e0f27664136c', 'n[60 chars]': 0} 256s E {'id': '5f19324d-14b4-4279-80bb-058bc71fa7c0', 'n[60 chars]': 0} 256s E 256s E First list contains 1 additional elements. 256s E First extra element 1: 256s E {'id': '5f19324d-14b4-4279-80bb-058bc71fa7c0', 'name': 'python3', 'execution_state': 'starting', 'connections': 0} 256s E 256s E [{'connections': 0, 256s E - 'execution_state': 'starting', 256s E - 'id': 'a629dc73-d6df-4973-912a-e0f27664136c', 256s E - 'name': 'python3'}, 256s E - {'connections': 0, 256s E 'execution_state': 'starting', 256s E 'id': '5f19324d-14b4-4279-80bb-058bc71fa7c0', 256s E 'name': 'python3'}] 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:238: AssertionError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.260000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkhe726bz/runtime/kernel-5f19324d-14b4-4279-80bb-058bc71fa7c0.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:44021 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34399 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 5f19324d-14b4-4279-80bb-058bc71fa7c0, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3', 'cwd': '/tmp/tmpkhe726bz/notebooks/foo'} 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for dd2f98a7-54fc-4c31-94ad-007d50d960ae 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: dd2f98a7-54fc-4c31-94ad-007d50d960ae 256s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9 (127.0.0.1) 19.520000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.000000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.020000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 5f19324d-14b4-4279-80bb-058bc71fa7c0 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 5f19324d-14b4-4279-80bb-058bc71fa7c0 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 256s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 256s raise km.ready.exception() # type: ignore[misc] 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/980e3de6-42fb-4921-92ac-09e2c8d888e9 (127.0.0.1) 7.780000ms referer=None 256s _______________ AsyncSessionAPITest.test_modify_path_deprecated ________________ 256s 256s @self.addCleanup 256s def cleanup_sessions(): 256s for session in self.sess_api.list().json(): 256s > self.sess_api.delete(session['id']) 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/29ddb716-08e0-4c02-afcb-35fa3e8a37fb 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkhe726bz/runtime/kernel-79a2500e-f03f-4869-a67c-1ed7a80fdd55.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:35077 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:49237 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 79a2500e-f03f-4869-a67c-1ed7a80fdd55, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpkhe726bz/notebooks/foo'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 17.130000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s WARNING NotebookApp:handlers.py:124 Sessions API changed, see updated swagger docs 256s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/29ddb716-08e0-4c02-afcb-35fa3e8a37fb (127.0.0.1) 1.570000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.150000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 79a2500e-f03f-4869-a67c-1ed7a80fdd55 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 79a2500e-f03f-4869-a67c-1ed7a80fdd55 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/29ddb716-08e0-4c02-afcb-35fa3e8a37fb (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/29ddb716-08e0-4c02-afcb-35fa3e8a37fb', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 256s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 256s raise km.ready.exception() # type: ignore[misc] 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/29ddb716-08e0-4c02-afcb-35fa3e8a37fb (127.0.0.1) 9.030000ms referer=None 256s --------------------------- Captured stderr teardown --------------------------- 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 256s from pathlib import Path 256s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 256s from ._abc import * 256s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 256s from glob import _Globber, _no_recurse_symlinks 256s File "/usr/lib/python3.13/glob.py", line 5, in 256s import re 256s File "/usr/lib/python3.13/re/__init__.py", line 126, in 256s from . import _compiler, _parser 256s File "/usr/lib/python3.13/re/_compiler.py", line 14, in 256s from . import _parser 256s File "/usr/lib/python3.13/re/_parser.py", line 15, in 256s from ._constants import * 256s File "", line 1357, in _find_and_load 256s File "", line 418, in __enter__ 256s File "", line 316, in acquire 256s KeyboardInterrupt 256s _____________________ AsyncSessionAPITest.test_modify_type _____________________ 256s 256s @self.addCleanup 256s def cleanup_sessions(): 256s for session in self.sess_api.list().json(): 256s > self.sess_api.delete(session['id']) 256s 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 256s return self._req('DELETE', id) 256s ^^^^^^^^^^^^^^^^^^^^^^^ 256s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 256s response.raise_for_status() 256s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 256s 256s self = 256s 256s def raise_for_status(self): 256s """Raises :class:`HTTPError`, if one occurred.""" 256s 256s http_error_msg = "" 256s if isinstance(self.reason, bytes): 256s # We attempt to decode utf-8 first because some servers 256s # choose to localize their reason strings. If the string 256s # isn't utf-8, we fall back to iso-8859-1 for all other 256s # encodings. (See PR #3538) 256s try: 256s reason = self.reason.decode("utf-8") 256s except UnicodeDecodeError: 256s reason = self.reason.decode("iso-8859-1") 256s else: 256s reason = self.reason 256s 256s if 400 <= self.status_code < 500: 256s http_error_msg = ( 256s f"{self.status_code} Client Error: {reason} for url: {self.url}" 256s ) 256s 256s elif 500 <= self.status_code < 600: 256s http_error_msg = ( 256s f"{self.status_code} Server Error: {reason} for url: {self.url}" 256s ) 256s 256s if http_error_msg: 256s > raise HTTPError(http_error_msg, response=self) 256s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/9fb25d3e-8aa3-440a-ad87-16edf71e3064 256s 256s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 256s ----------------------------- Captured stderr call ----------------------------- 256s Traceback (most recent call last): 256s ------------------------------ Captured log call ------------------------------- 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 256s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkhe726bz/runtime/kernel-88b85c31-eb5a-4d45-a5af-cecb41f802f8.json'] 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:44019 256s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:33771 256s INFO NotebookApp:kernelmanager.py:179 Kernel started: 88b85c31-eb5a-4d45-a5af-cecb41f802f8, name: python3 256s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpkhe726bz/notebooks/foo'} 256s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 19.840000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/9fb25d3e-8aa3-440a-ad87-16edf71e3064 (127.0.0.1) 1.330000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.280000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 79a2500e-f03f-4869-a67c-1ed7a80fdd55 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 79a2500e-f03f-4869-a67c-1ed7a80fdd55 256s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/29ddb716-08e0-4c02-afcb-35fa3e8a37fb (127.0.0.1) 1.360000ms 256s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 256s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 88b85c31-eb5a-4d45-a5af-cecb41f802f8 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 88b85c31-eb5a-4d45-a5af-cecb41f802f8 256s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/9fb25d3e-8aa3-440a-ad87-16edf71e3064 (127.0.0.1) 256s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/9fb25d3e-8aa3-440a-ad87-16edf71e3064', version='HTTP/1.1', remote_ip='127.0.0.1') 256s Traceback (most recent call last): 256s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 256s result = await result 256s ^^^^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 256s future.result() 256s ~~~~~~~~~~~~~^^ 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 256s yield maybe_future(sm.delete_session(session_id)) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 256s yielded = self.gen.throw(exc) 256s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 256s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 256s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 256s value = future.result() 256s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 256s raise self._exception.with_traceback(self._exception_tb) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 256s result = coro.send(None) 256s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 256s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 256s raise km.ready.exception() # type: ignore[misc] 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 256s await kernel_awaitable 256s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 256s result = await obj 256s ^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 256s raise e 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 256s out = await method(self, *args, **kwargs) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 256s await self._async_finish_shutdown(restart=restart) 256s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 256s await asyncio.wait_for( 256s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 256s ) 256s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 256s async with timeouts.timeout(timeout): 256s ~~~~~~~~~~~~~~~~^^^^^^^^^ 256s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 256s raise RuntimeError("Timeout should be used inside a task") 256s RuntimeError: Timeout should be used inside a task 256s WARNING NotebookApp:handlers.py:612 Unhandled error 256s ERROR NotebookApp:log.py:55 { 256s "Host": "localhost:12341", 256s "Accept": "*/*", 256s "User-Agent": "python-requests/2.32.5" 256s } 256s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/9fb25d3e-8aa3-440a-ad87-16edf71e3064 (127.0.0.1) 9.910000ms referer=None 256s --------------------------- Captured stderr teardown --------------------------- 256s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 256s return _run_code(code, main_globals, None, 256s "__main__", mod_spec) 256s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 256s exec(code, run_globals) 256s ~~~~^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 256s from ipykernel import kernelapp as app 256s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 256s from .connect import * # noqa: F403 256s ^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 9, in 256s from subprocess import PIPE, Popen 256s File "/usr/lib/python3.13/subprocess.py", line 49, in 256s import signal 256s File "/usr/lib/python3.13/signal.py", line 7, in 256s _IntEnum._convert_( 256s ~~~~~~~~~~~~~~~~~~^ 256s 'Signals', __name__, 256s ^^^^^^^^^^^^^^^^^^^^ 256s ...<2 lines>... 256s and (name.startswith('SIG') and not name.startswith('SIG_')) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s or name.startswith('CTRL_')) 256s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 256s File "/usr/lib/python3.13/enum.py", line 916, in _convert_ 256s (name, value) 256s KeyboardInterrupt 256s ---------------------------- Captured log teardown ----------------------------- 256s INFO NotebookApp:notebookapp.py:2164 Shutting down 2 kernels 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a629dc73-d6df-4973-912a-e0f27664136c 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a880bc78-005e-4ef6-97b2-102857565ff5 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 88b85c31-eb5a-4d45-a5af-cecb41f802f8 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: dd2f98a7-54fc-4c31-94ad-007d50d960ae 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 9f9ca658-53a0-441c-b83b-d909183f539d 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: e4652af5-f608-4843-bcbb-87f813fa42ac 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 5f19324d-14b4-4279-80bb-058bc71fa7c0 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 79a2500e-f03f-4869-a67c-1ed7a80fdd55 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 870d4235-a112-4d53-a325-4823b769d30e 256s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 28cc8706-ee43-447e-8d04-75caf12fb1ad 256s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 256s =============================== warnings summary =============================== 256s ../../../usr/lib/python3/dist-packages/notebook/utils.py:280 256s ../../../usr/lib/python3/dist-packages/notebook/utils.py:280 256s /usr/lib/python3/dist-packages/notebook/utils.py:280: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead. 256s return LooseVersion(v) >= LooseVersion(check) 256s 256s ../../../usr/lib/python3/dist-packages/notebook/_tz.py:29: 1 warning 256s auth/tests/test_login.py: 2 warnings 256s bundler/tests/test_bundler_api.py: 2 warnings 256s services/api/tests/test_api.py: 4 warnings 256s services/config/tests/test_config_api.py: 7 warnings 256s services/contents/tests/test_contents_api.py: 318 warnings 256s services/kernels/tests/test_kernels_api.py: 109 warnings 256s services/kernelspecs/tests/test_kernelspecs_api.py: 7 warnings 256s services/nbconvert/tests/test_nbconvert_api.py: 3 warnings 256s services/sessions/tests/test_sessionmanager.py: 9 warnings 256s services/sessions/tests/test_sessions_api.py: 128 warnings 256s terminal/tests/test_terminals_api.py: 50 warnings 256s tests/test_files.py: 2 warnings 256s tests/test_gateway.py: 21 warnings 256s tests/test_notebookapp.py: 8 warnings 256s tests/test_paths.py: 2 warnings 256s tree/tests/test_tree_handler.py: 2 warnings 256s /usr/lib/python3/dist-packages/notebook/_tz.py:29: DeprecationWarning: datetime.datetime.utcnow() is deprecated and scheduled for removal in a future version. Use timezone-aware objects to represent datetimes in UTC: datetime.datetime.now(datetime.UTC). 256s dt = unaware(*args, **kwargs) 256s 256s ../../../usr/lib/python3/dist-packages/notebook/tests/test_notebookapp_integration.py:14 256s /usr/lib/python3/dist-packages/notebook/tests/test_notebookapp_integration.py:14: PytestUnknownMarkWarning: Unknown pytest.mark.integration_tests - is this a typo? You can register custom marks to avoid this warning - for details, see https://docs.pytest.org/en/stable/how-to/mark.html 256s pytestmark = pytest.mark.integration_tests 256s 256s auth/tests/test_login.py: 3 warnings 256s bundler/tests/test_bundler_api.py: 3 warnings 256s services/api/tests/test_api.py: 3 warnings 256s services/config/tests/test_config_api.py: 3 warnings 256s services/contents/tests/test_contents_api.py: 6 warnings 256s services/kernels/tests/test_kernels_api.py: 12 warnings 256s services/kernelspecs/tests/test_kernelspecs_api.py: 3 warnings 256s services/nbconvert/tests/test_nbconvert_api.py: 3 warnings 256s services/sessions/tests/test_sessions_api.py: 6 warnings 256s terminal/tests/test_terminals_api.py: 6 warnings 256s tests/test_files.py: 3 warnings 256s tests/test_gateway.py: 3 warnings 256s tests/test_notebookapp.py: 11 warnings 256s tests/test_paths.py: 3 warnings 256s tree/tests/test_tree_handler.py: 3 warnings 256s /usr/lib/python3/dist-packages/nest_asyncio.py:71: DeprecationWarning: 'asyncio.get_event_loop_policy' is deprecated and slated for removal in Python 3.16 256s policy = events.get_event_loop_policy() 256s 256s auth/tests/test_login.py: 8 warnings 256s bundler/tests/test_bundler_api.py: 8 warnings 256s services/api/tests/test_api.py: 8 warnings 256s services/config/tests/test_config_api.py: 8 warnings 256s services/contents/tests/test_contents_api.py: 16 warnings 256s services/kernels/tests/test_kernels_api.py: 43 warnings 256s services/kernelspecs/tests/test_kernelspecs_api.py: 8 warnings 256s services/nbconvert/tests/test_nbconvert_api.py: 8 warnings 256s services/sessions/tests/test_sessionmanager.py: 18 warnings 256s services/sessions/tests/test_sessions_api.py: 17 warnings 256s terminal/tests/test_terminals_api.py: 16 warnings 256s tests/test_files.py: 8 warnings 256s tests/test_gateway.py: 8 warnings 256s tests/test_notebookapp.py: 26 warnings 256s tests/test_paths.py: 8 warnings 256s tree/tests/test_tree_handler.py: 8 warnings 256s /usr/lib/python3/dist-packages/nest_asyncio.py:40: DeprecationWarning: 'asyncio.get_event_loop_policy' is deprecated and slated for removal in Python 3.16 256s loop = events.get_event_loop_policy().get_event_loop() 256s 256s bundler/tests/test_bundler_api.py: 6 warnings 256s services/api/tests/test_api.py: 6 warnings 256s services/contents/tests/test_contents_api.py: 806 warnings 256s services/contents/tests/test_largefilemanager.py: 42 warnings 256s services/contents/tests/test_manager.py: 526 warnings 256s tests/test_files.py: 8 warnings 256s tree/tests/test_tree_handler.py: 6 warnings 256s /usr/lib/python3/dist-packages/notebook/_tz.py:29: DeprecationWarning: datetime.datetime.utcfromtimestamp() is deprecated and scheduled for removal in a future version. Use timezone-aware objects to represent datetimes in UTC: datetime.datetime.fromtimestamp(timestamp, datetime.UTC). 256s dt = unaware(*args, **kwargs) 256s 256s services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_connections 256s services/kernels/tests/test_kernels_api.py::KernelCullingTest::test_culling 256s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:67: DeprecationWarning: make_current is deprecated; start the event loop first 256s loop.make_current() 256s 256s services/kernelspecs/tests/test_kernelspecs_api.py::APITest::test_list_kernelspecs 256s services/kernelspecs/tests/test_kernelspecs_api.py::APITest::test_list_kernelspecs_bad 256s /usr/lib/python3/dist-packages/jupyter_client/kernelspec.py:302: UserWarning: Invalid kernelspec directory name (Kernel names can only contain ASCII letters and numbers and these separators: - . _ (hyphen, period, and underscore).): /tmp/tmp8emf8ja9/data/kernels/sample 2 256s d = self.find_kernel_specs() 256s 256s terminal/tests/test_terminals_api.py::TerminalAPITest::test_create_terminal 256s terminal/tests/test_terminals_api.py::TerminalAPITest::test_create_terminal_via_get 256s terminal/tests/test_terminals_api.py::TerminalAPITest::test_create_terminal_via_get 256s terminal/tests/test_terminals_api.py::TerminalAPITest::test_create_terminal_with_name 256s terminal/tests/test_terminals_api.py::TerminalAPITest::test_terminal_handler 256s terminal/tests/test_terminals_api.py::TerminalAPITest::test_terminal_root_handler 256s terminal/tests/test_terminals_api.py::TerminalAPITest::test_terminal_root_handler 256s terminal/tests/test_terminals_api.py::TerminalCullingTest::test_culling 256s /usr/lib/python3.14/pty.py:66: DeprecationWarning: This process (pid=2575) is multi-threaded, use of forkpty() may lead to deadlocks in the child. 256s pid, fd = os.forkpty() 256s 256s tests/test_files.py::FilesTest::test_contents_manager 256s /usr/lib/python3/dist-packages/traitlets/config/loader.py:1022: RuntimeWarning: coroutine 'KernelManager._async_wait' was never awaited 256s argparse_traits[argname] = (trait, argparse_kwds) 256s Enable tracemalloc to get traceback where the object was allocated. 256s See https://docs.pytest.org/en/stable/how-to/capture-warnings.html#resource-warnings for more info. 256s 256s tests/test_gateway.py::TestGateway::test_gateway_kernel_lifecycle 256s tests/test_gateway.py::TestGateway::test_gateway_session_lifecycle 256s /usr/lib/python3/dist-packages/notebook/tests/test_gateway.py:34: DeprecationWarning: datetime.datetime.utcnow() is deprecated and scheduled for removal in a future version. Use timezone-aware objects to represent datetimes in UTC: datetime.datetime.now(datetime.UTC). 256s dt = datetime.utcnow().isoformat() + 'Z' 256s 256s -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html 256s =========================== short test summary info ============================ 256s SKIPPED [1] ../../../usr/lib/python3/dist-packages/notebook/nbconvert/tests/test_nbconvert_handlers.py:86: Pandoc wasn't found. Skipping this test. 256s SKIPPED [1] ../../../usr/lib/python3/dist-packages/notebook/nbconvert/tests/test_nbconvert_handlers.py:101: Pandoc wasn't found. Skipping this test. 256s SKIPPED [1] ../../../usr/lib/python3/dist-packages/notebook/nbconvert/tests/test_nbconvert_handlers.py:109: Pandoc wasn't found. Skipping this test. 256s SKIPPED [1] ../../../usr/lib/python3/dist-packages/notebook/nbconvert/tests/test_nbconvert_handlers.py:119: Pandoc wasn't found. Skipping this test. 256s SKIPPED [1] ../../../usr/lib/python3/dist-packages/notebook/nbconvert/tests/test_nbconvert_handlers.py:128: Pandoc wasn't found. Skipping this test. 256s SKIPPED [1] ../../../usr/lib/python3/dist-packages/notebook/nbconvert/tests/test_nbconvert_handlers.py:145: Pandoc wasn't found. Skipping this test. 256s SKIPPED [2] ../../../usr/lib/python3/dist-packages/notebook/services/contents/tests/test_contents_api.py:682: skip send2trash tests 256s SKIPPED [2] ../../../usr/lib/python3/dist-packages/notebook/services/contents/tests/test_contents_api.py:592: skip send2trash tests 256s SKIPPED [2] ../../../usr/lib/python3/dist-packages/notebook/services/contents/tests/test_contents_api.py:606: skip send2trash tests 256s SKIPPED [2] ../../../usr/lib/python3/dist-packages/notebook/services/contents/tests/test_contents_api.py:616: skip send2trash tests 256s SKIPPED [1] ../../../usr/lib/python3/dist-packages/notebook/services/contents/tests/test_manager.py:332: skip send2trash tests 256s SKIPPED [2] ../../../usr/lib/python3/dist-packages/notebook/services/contents/tests/test_manager.py:658: skip send2trash tests 256s SKIPPED [2] ../../../usr/lib/python3/dist-packages/notebook/services/contents/tests/test_manager.py:727: skip send2trash tests 256s SKIPPED [1] ../../../usr/lib/python3/dist-packages/notebook/tests/test_utils.py:83: run on windows only 256s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_default_kernel 256s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_kernel_handler 256s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_main_kernel_handler 256s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_no_kernels 256s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_connections 256s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_default_kernel 256s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_kernel_handler 256s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_main_kernel_handler 256s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_no_kernels 256s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create 256s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_console_session 256s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_deprecated 256s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_file_session 256s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_with_kernel_id 256s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_modify_kernel_id 256s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_modify_kernel_name 256s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_modify_path_deprecated 256s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_modify_type 256s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create 256s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_console_session 256s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_deprecated 256s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_file_session 256s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_with_kernel_id 256s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_modify_kernel_id 256s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_modify_kernel_name 256s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_modify_path_deprecated 256s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_modify_type 256s ERROR services/kernels/tests/test_kernels_api.py::KernelAPITest::test_main_kernel_handler 256s ERROR services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_main_kernel_handler 256s ERROR services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_with_kernel_id 256s ERROR services/sessions/tests/test_sessions_api.py::SessionAPITest::test_modify_kernel_id 256s ERROR services/sessions/tests/test_sessions_api.py::SessionAPITest::test_modify_kernel_name 256s ERROR services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_with_kernel_id 256s ERROR services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_modify_kernel_id 256s ERROR services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_modify_kernel_name 256s = 27 failed, 277 passed, 20 skipped, 6 deselected, 2380 warnings, 8 errors in 33.60s = 257s *** END OF RUN 1: NOT ALL TESTS HAVE YET PASSED/XFAILED *** 257s *** STARTING RUN 2: python3.14 -m pytest --pyargs notebook -rfE --last-failed --last-failed-no-failures none --ignore=/usr/lib/python3/dist-packages/notebook/tests/selenium --deselect=services/kernels/tests/test_kernels_api.py::KernelAPITest::test_connections 260s ============================= test session starts ============================== 260s platform linux -- Python 3.14.2, pytest-9.0.2, pluggy-1.6.0 260s rootdir: /tmp/autopkgtest.d1RsUl/autopkgtest_tmp 260s plugins: typeguard-4.4.4 260s collected 330 items / 303 deselected / 27 selected 260s run-last-failure: rerun previous 27 failures 260s 262s services/kernels/tests/test_kernels_api.py FFFEFFFFFEF [ 33%] 264s services/sessions/tests/test_sessions_api.py FFFFFEFF.FFFFFFEFF.F [100%] 264s 264s ==================================== ERRORS ==================================== 264s _________ ERROR at teardown of KernelAPITest.test_main_kernel_handler __________ 264s 264s self = 264s 264s def tearDown(self): 264s for k in self.kern_api.list().json(): 264s > self.kern_api.shutdown(k['id']) 264s 264s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 264s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 264s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 264s return self._req('DELETE', id) 264s ^^^^^^^^^^^^^^^^^^^^^^^ 264s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 264s response.raise_for_status() 264s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 264s 264s self = 264s 264s def raise_for_status(self): 264s """Raises :class:`HTTPError`, if one occurred.""" 264s 264s http_error_msg = "" 264s if isinstance(self.reason, bytes): 264s # We attempt to decode utf-8 first because some servers 264s # choose to localize their reason strings. If the string 264s # isn't utf-8, we fall back to iso-8859-1 for all other 264s # encodings. (See PR #3538) 264s try: 264s reason = self.reason.decode("utf-8") 264s except UnicodeDecodeError: 264s reason = self.reason.decode("iso-8859-1") 264s else: 264s reason = self.reason 264s 264s if 400 <= self.status_code < 500: 264s http_error_msg = ( 264s f"{self.status_code} Client Error: {reason} for url: {self.url}" 264s ) 264s 264s elif 500 <= self.status_code < 600: 264s http_error_msg = ( 264s f"{self.status_code} Server Error: {reason} for url: {self.url}" 264s ) 264s 264s if http_error_msg: 264s > raise HTTPError(http_error_msg, response=self) 264s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/a2c5e7be-cfd7-44f4-90b4-863c82126d49 264s 264s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 264s ----------------------------- Captured stderr call ----------------------------- 264s Traceback (most recent call last): 264s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 264s return _run_code(code, main_globals, None, 264s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 264s exec(code, run_globals) 264s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 264s from pathlib import Path 264s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 264s from ._abc import * 264s File "/usr/lib/python3.13/pathlib/_abc.py", line 14, in 264s import functools 264s File "/usr/lib/python3.13/functools.py", line 18, in 264s from collections import namedtuple 264s File "/usr/lib/python3.13/collections/__init__.py", line 38, in 264s from keyword import iskeyword as _iskeyword 264s File "", line 1360, in _find_and_load 264s File "", line 1331, in _find_and_load_unlocked 264s File "", line 935, in _load_unlocked 264s File "", line 1019, in exec_module 264s File "", line 1109, in get_code 264s File "", line 1232, in path_stats 264s File "", line 152, in _path_stat 264s KeyboardInterrupt 264s Traceback (most recent call last): 264s ------------------------------ Captured log call ------------------------------- 264s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 264s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 264s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp790eae4_/runtime/kernel-a2c5e7be-cfd7-44f4-90b4-863c82126d49.json'] 264s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:54621 264s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:41321 264s INFO NotebookApp:kernelmanager.py:179 Kernel started: a2c5e7be-cfd7-44f4-90b4-863c82126d49, name: python3 264s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 264s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 22.260000ms 264s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 264s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.970000ms 264s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 264s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 264s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp790eae4_/runtime/kernel-115a7bfc-c988-418e-a1cf-43fe9de55d19.json'] 264s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:35727 264s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:46057 264s INFO NotebookApp:kernelmanager.py:179 Kernel started: 115a7bfc-c988-418e-a1cf-43fe9de55d19, name: python3 264s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 264s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 22.320000ms 264s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 264s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 3.300000ms 264s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 264s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: 115a7bfc-c988-418e-a1cf-43fe9de55d19 264s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/115a7bfc-c988-418e-a1cf-43fe9de55d19/interrupt (127.0.0.1) 1.490000ms 264s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 264s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 264s Traceback (most recent call last): 264s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 264s out = await method(self, *args, **kwargs) 264s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 264s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 264s await self._async_finish_shutdown(restart=restart) 264s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 264s await asyncio.wait_for( 264s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 264s ) 264s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 264s async with timeouts.timeout(timeout): 264s ~~~~~~~~~~~~~~~~^^^^^^^^^ 264s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 264s raise RuntimeError("Timeout should be used inside a task") 264s RuntimeError: Timeout should be used inside a task 264s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 264s Traceback (most recent call last): 264s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 264s yield maybe_future(km.restart_kernel(kernel_id)) 264s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 264s value = future.result() 264s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 264s raise self._exception.with_traceback(self._exception_tb) 264s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 264s result = coro.send(None) 264s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 264s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 264s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^ 264s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 264s return _runner_map[name].run(inner) 264s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 264s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 264s return fut.result(None) 264s ~~~~~~~~~~^^^^^^ 264s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 264s return self.__get_result() 264s ~~~~~~~~~~~~~~~~~^^ 264s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 264s raise self._exception 264s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 264s result = coro.send(None) 264s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 264s await ensure_async(kernel.restart_kernel(now=now)) 264s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^ 264s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 264s return _runner_map[name].run(inner) 264s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 264s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 264s return fut.result(None) 264s ~~~~~~~~~~^^^^^^ 264s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 264s return self.__get_result() 264s ~~~~~~~~~~~~~~~~~^^ 264s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 264s raise self._exception 264s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 264s result = coro.send(None) 264s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 264s await self._async_shutdown_kernel(now=now, restart=True) 264s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 264s raise e 264s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 264s out = await method(self, *args, **kwargs) 264s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 264s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 264s await self._async_finish_shutdown(restart=restart) 264s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 264s await asyncio.wait_for( 264s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 264s ) 264s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 264s async with timeouts.timeout(timeout): 264s ~~~~~~~~~~~~~~~~^^^^^^^^^ 264s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 264s raise RuntimeError("Timeout should be used inside a task") 264s RuntimeError: Timeout should be used inside a task 264s ERROR NotebookApp:log.py:55 { 264s "Host": "localhost:12341", 264s "Accept": "*/*", 264s "User-Agent": "python-requests/2.32.5" 264s } 264s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/115a7bfc-c988-418e-a1cf-43fe9de55d19/restart (127.0.0.1) 5.890000ms referer=None 264s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 264s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.010000ms 264s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 264s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for a2c5e7be-cfd7-44f4-90b4-863c82126d49 264s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a2c5e7be-cfd7-44f4-90b4-863c82126d49 264s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 264s Traceback (most recent call last): 264s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 264s out = await method(self, *args, **kwargs) 264s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 264s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 264s await self._async_finish_shutdown(restart=restart) 264s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 264s await asyncio.wait_for( 264s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 264s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/a2c5e7be-cfd7-44f4-90b4-863c82126d49 (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/a2c5e7be-cfd7-44f4-90b4-863c82126d49', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 265s yielded = ctx_run(next, result) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 265s yield maybe_future(km.shutdown_kernel(kernel_id)) 265s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 265s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 265s stopper = ensure_async(km.shutdown_kernel(now, restart)) 265s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/a2c5e7be-cfd7-44f4-90b4-863c82126d49 (127.0.0.1) 11.310000ms referer=None 265s --------------------------- Captured stderr teardown --------------------------- 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 265s from .connect import * # noqa: F403 265s ^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 12, in 265s import jupyter_client 265s File "/usr/lib/python3/dist-packages/jupyter_client/__init__.py", line 4, in 265s from .asynchronous import AsyncKernelClient 265s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/__init__.py", line 1, in 265s from .client import AsyncKernelClient # noqa 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/client.py", line 9, in 265s import zmq.asyncio 265s File "/usr/lib/python3/dist-packages/zmq/asyncio.py", line 10, in 265s import asyncio 265s File "/usr/lib/python3.13/asyncio/__init__.py", line 8, in 265s from .base_events import * 265s File "/usr/lib/python3.13/asyncio/base_events.py", line 23, in 265s import socket 265s File "/usr/lib/python3.13/socket.py", line 76, in 265s IntEnum._convert_( 265s ~~~~~~~~~~~~~~~~~^ 265s 'AddressFamily', 265s ^^^^^^^^^^^^^^^^ 265s __name__, 265s ^^^^^^^^^ 265s lambda C: C.isupper() and C.startswith('AF_')) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3.13/enum.py", line 927, in _convert_ 265s tmp_cls = type(name, (object, ), body) 265s KeyboardInterrupt 265s _______ ERROR at teardown of AsyncKernelAPITest.test_main_kernel_handler _______ 265s 265s self = 265s 265s def tearDown(self): 265s for k in self.kern_api.list().json(): 265s > self.kern_api.shutdown(k['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/bc5461eb-4847-40c5-8876-263090e68dea 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 265s from pathlib import Path 265s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 265s from ._abc import * 265s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 265s from glob import _Globber, _no_recurse_symlinks 265s File "/usr/lib/python3.13/glob.py", line 5, in 265s import re 265s File "/usr/lib/python3.13/re/__init__.py", line 125, in 265s import enum 265s File "/usr/lib/python3.13/enum.py", line 23, in 265s class nonmember(object): 265s KeyboardInterrupt 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 265s from .connect import * # noqa: F403 265s ^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 12, in 265s import jupyter_client 265s File "/usr/lib/python3/dist-packages/jupyter_client/__init__.py", line 4, in 265s from .asynchronous import AsyncKernelClient 265s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/__init__.py", line 1, in 265s from .client import AsyncKernelClient # noqa 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/client.py", line 9, in 265s import zmq.asyncio 265s File "/usr/lib/python3/dist-packages/zmq/asyncio.py", line 10, in 265s import asyncio 265s File "/usr/lib/python3.13/asyncio/__init__.py", line 8, in 265s from .base_events import * 265s File "/usr/lib/python3.13/asyncio/base_events.py", line 23, in 265s import socket 265s File "/usr/lib/python3.13/socket.py", line 76, in 265s IntEnum._convert_( 265s ~~~~~~~~~~~~~~~~~^ 265s 'AddressFamily', 265s ^^^^^^^^^^^^^^^^ 265s __name__, 265s ^^^^^^^^^ 265s lambda C: C.isupper() and C.startswith('AF_')) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3.13/enum.py", line 928, in _convert_ 265s cls = _simple_enum(etype=cls, boundary=boundary or KEEP)(tmp_cls) 265s File "/usr/lib/python3.13/enum.py", line 1909, in convert_class 265s setattr(enum_class, name, member) 265s ~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3.13/enum.py", line 829, in __setattr__ 265s def __setattr__(cls, name, value): 265s 265s KeyboardInterrupt 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpscvvf8gi/runtime/kernel-bc5461eb-4847-40c5-8876-263090e68dea.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:37845 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:59371 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: bc5461eb-4847-40c5-8876-263090e68dea, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 20.840000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.060000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpscvvf8gi/runtime/kernel-d3a74d5c-10c6-4028-9fa1-1b0d1ea68774.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:42381 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:46991 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: d3a74d5c-10c6-4028-9fa1-1b0d1ea68774, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 20.060000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.090000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: d3a74d5c-10c6-4028-9fa1-1b0d1ea68774 265s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/d3a74d5c-10c6-4028-9fa1-1b0d1ea68774/interrupt (127.0.0.1) 1.460000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 265s yield maybe_future(km.restart_kernel(kernel_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 291, in __step_run_and_handle_result 265s result = coro.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 265s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 265s File "/usr/lib/python3.14/asyncio/futures.py", line 295, in __await__ 265s yield self # This tells Task to wait for completion. 265s ^^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 265s future.result() 265s ~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kerne/usr/lib/python3/dist-packages/_pytest/unraisableexception.py:33: RuntimeWarning: coroutine 'KernelManager._async_wait' was never awaited 265s gc.collect() 265s RuntimeWarning: Enable tracemalloc to get the object allocation traceback 265s l 265s await ensure_async(kernel.restart_kernel(now=now)) 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 265s await self._async_shutdown_kernel(now=now, restart=True) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/d3a74d5c-10c6-4028-9fa1-1b0d1ea68774/restart (127.0.0.1) 9.890000ms referer=None 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.160000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for bc5461eb-4847-40c5-8876-263090e68dea 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: bc5461eb-4847-40c5-8876-263090e68dea 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/bc5461eb-4847-40c5-8876-263090e68dea (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/bc5461eb-4847-40c5-8876-263090e68dea', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 265s future.result() 265s ~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 265s yield maybe_future(km.shutdown_kernel(kernel_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 265s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 265s raise km.ready.exception() # type: ignore[misc] 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/bc5461eb-4847-40c5-8876-263090e68dea (127.0.0.1) 11.750000ms referer=None 265s ________ ERROR at teardown of SessionAPITest.test_create_with_kernel_id ________ 265s 265s @self.addCleanup 265s def cleanup_sessions(): 265s for session in self.sess_api.list().json(): 265s > self.sess_api.delete(session['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/4666c052-1748-488f-8757-8c243d31895d 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkt2qg12p/runtime/kernel-da2f684e-a243-4573-805f-5e368fed74c9.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:35533 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:41407 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: da2f684e-a243-4573-805f-5e368fed74c9, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 20.630000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.310000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.050000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.010000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 85fa53da-3715-43d4-9257-4913a8fa0705 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 85fa53da-3715-43d4-9257-4913a8fa0705 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/7c6250ea-254e-48aa-949f-e0bc743c0ce5 (127.0.0.1) 1.810000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for da2f684e-a243-4573-805f-5e368fed74c9 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: da2f684e-a243-4573-805f-5e368fed74c9 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/4666c052-1748-488f-8757-8c243d31895d (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/4666c052-1748-488f-8757-8c243d31895d', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 265s yielded = self.gen.send(value) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 265s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 265s stopper = ensure_async(km.shutdown_kernel(now, restart)) 265s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/4666c052-1748-488f-8757-8c243d31895d (127.0.0.1) 10.040000ms referer=None 265s --------------------------- Captured stderr teardown --------------------------- 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 265s from .connect import * # noqa: F403 265s ^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 10, in 265s from typing import TYPE_CHECKING, Any 265s File "/usr/lib/python3.13/typing.py", line 2959, in 265s class SupportsIndex(Protocol): 265s ...<6 lines>... 265s pass 265s File "/usr/lib/python3.13/typing.py", line 2083, in __new__ 265s return super().__new__(mcls, name, bases, namespace, **kwargs) 265s ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3.13/abc.py", line 106, in __new__ 265s cls = super().__new__(mcls, name, bases, namespace, **kwargs) 265s File "/usr/lib/python3.13/typing.py", line 2211, in __init_subclass__ 265s def __init_subclass__(cls, *args, **kwargs): 265s 265s KeyboardInterrupt 265s _____ ERROR at teardown of AsyncSessionAPITest.test_create_with_kernel_id ______ 265s 265s @self.addCleanup 265s def cleanup_sessions(): 265s for session in self.sess_api.list().json(): 265s > self.sess_api.delete(session['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/345c243f-8560-420b-857b-80d119edb15f 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpalhrix9x/runtime/kernel-1d6da3da-53c2-49a1-927c-f961055c2814.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:48395 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:59339 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: 1d6da3da-53c2-49a1-927c-f961055c2814, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.800000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.170000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.260000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.170000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 472f6dc8-c4ef-4e3e-9f10-aeb57e1cab99 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 472f6dc8-c4ef-4e3e-9f10-aeb57e1cab99 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/9877c12e-f190-497f-a0b6-c718a4aaac5b (127.0.0.1) 1.390000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 1d6da3da-53c2-49a1-927c-f961055c2814 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 1d6da3da-53c2-49a1-927c-f961055c2814 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/345c243f-8560-420b-857b-80d119edb15f (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/345c243f-8560-420b-857b-80d119edb15f', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 265s future.result() 265s ~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 265s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 265s raise km.ready.exception() # type: ignore[misc] 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/345c243f-8560-420b-857b-80d119edb15f (127.0.0.1) 8.090000ms referer=None 265s --------------------------- Captured stderr teardown --------------------------- 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 265s from .connect import * # noqa: F403 265s ^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 9, in 265s from subprocess import PIPE, Popen 265s File "/usr/lib/python3.13/subprocess.py", line 46, in 265s import locale 265s File "/usr/lib/python3.13/locale.py", line 180, in 265s _percent_re = re.compile(r'%(?:\((?P.*?)\))?' 265s r'(?P[-#0-9 +*.hlL]*?)[eEfFgGdiouxXcrs%]') 265s File "/usr/lib/python3.13/re/__init__.py", line 289, in compile 265s return _compile(pattern, flags) 265s File "/usr/lib/python3.13/re/__init__.py", line 350, in _compile 265s p = _compiler.compile(pattern, flags) 265s File "/usr/lib/python3.13/re/_compiler.py", line 752, in compile 265s code = _code(p, flags) 265s File "/usr/lib/python3.13/re/_compiler.py", line 585, in _code 265s _compile(code, p.data, flags) 265s ~~~~~~~~^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3.13/re/_compiler.py", line 117, in _compile 265s _compile(code, av[2], flags) 265s ~~~~~~~~^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3.13/re/_compiler.py", line 126, in _compile 265s _compile(code, p, _combine_flags(flags, add_flags, del_flags)) 265s ~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3.13/re/_compiler.py", line 109, in _compile 265s _compile(code, av[2], flags) 265s ~~~~~~~~^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3.13/re/_compiler.py", line 102, in _compile 265s emit(ANY) 265s ~~~~^^^^^ 265s KeyboardInterrupt 265s =================================== FAILURES =================================== 265s ______________________ KernelAPITest.test_default_kernel _______________________ 265s 265s self = 265s 265s def tearDown(self): 265s for k in self.kern_api.list().json(): 265s > self.kern_api.shutdown(k['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/57d1d7b9-7f79-4f58-89f2-3ba37e7ead18 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ------------------------------ Captured log setup ------------------------------ 265s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmp790eae4_/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmp790eae4_/etc/jupyter'] for config files 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmp790eae4_/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmp790eae4_/config 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmp790eae4_/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmp790eae4_/config 265s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmp790eae4_/notebooks 265s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 265s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 265s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 265s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 265s WARNING NotebookApp:handlers.py:612 Forbidden 265s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 1.050000ms referer=None 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 265s from pathlib import Path 265s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 265s from ._local import * 265s File "/usr/lib/python3.13/pathlib/_local.py", line 473, in 265s class PureWindowsPath(PurePath): 265s ...<7 lines>... 265s __slots__ = () 265s File "/usr/lib/python3.13/pathlib/_local.py", line 479, in PureWindowsPath 265s import ntpath 265s File "/usr/lib/python3.13/ntpath.py", line 277, in 265s from nt import _getvolumepathname 265s File "", line 1360, in _find_and_load 265s File "", line 1322, in _find_and_load_unlocked 265s File "", line 1262, in _find_spec 265s File "", line 1556, in find_spec 265s File "", line 1530, in _get_spec 265s File "", line 1629, in find_spec 265s File "", line 152, in _path_stat 265s KeyboardInterrupt 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp790eae4_/runtime/kernel-57d1d7b9-7f79-4f58-89f2-3ba37e7ead18.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:51473 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:52669 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: 57d1d7b9-7f79-4f58-89f2-3ba37e7ead18, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 78.750000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.410000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 57d1d7b9-7f79-4f58-89f2-3ba37e7ead18 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 57d1d7b9-7f79-4f58-89f2-3ba37e7ead18 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/57d1d7b9-7f79-4f58-89f2-3ba37e7ead18 (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/57d1d7b9-7f79-4f58-89f2-3ba37e7ead18', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 265s yielded = ctx_run(next, result) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 265s yield maybe_future(km.shutdown_kernel(kernel_id)) 265s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 265s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 265s stopper = ensure_async(km.shutdown_kernel(now, restart)) 265s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/57d1d7b9-7f79-4f58-89f2-3ba37e7ead18 (127.0.0.1) 11.200000ms referer=None 265s ______________________ KernelAPITest.test_kernel_handler _______________________ 265s 265s self = 265s 265s def test_kernel_handler(self): 265s # GET kernel with given id 265s kid = self.kern_api.start().json()['id'] 265s r = self.kern_api.get(kid) 265s kern1 = r.json() 265s self.assertEqual(r.status_code, 200) 265s assert isinstance(kern1, dict) 265s self.assertIn('id', kern1) 265s self.assertEqual(kern1['id'], kid) 265s 265s # Request a bad kernel id and check that a JSON 265s # message is returned! 265s bad_id = '111-111-111-111-111' 265s with assert_http_error(404, 'Kernel does not exist: ' + bad_id): 265s self.kern_api.get(bad_id) 265s 265s # DELETE kernel with id 265s > r = self.kern_api.shutdown(kid) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:169: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/565194a3-c765-49c7-bd2c-cae5f5acc649 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 265s from pathlib import Path 265s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 265s from ._abc import * 265s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 265s from glob import _Globber, _no_recurse_symlinks 265s File "/usr/lib/python3.13/glob.py", line 5, in 265s import re 265s File "/usr/lib/python3.13/re/__init__.py", line 126, in 265s from . import _compiler, _parser 265s File "/usr/lib/python3.13/re/_compiler.py", line 13, in 265s import _sre 265s File "", line 1357, in _find_and_load 265s File "", line 418, in __enter__ 265s File "", line 316, in acquire 265s KeyboardInterrupt 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp790eae4_/runtime/kernel-565194a3-c765-49c7-bd2c-cae5f5acc649.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:35495 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:47575 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: 565194a3-c765-49c7-bd2c-cae5f5acc649, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 17.600000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/565194a3-c765-49c7-bd2c-cae5f5acc649 (127.0.0.1) 2.740000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s WARNING NotebookApp:web.py:1943 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1): Kernel does not exist: 111-111-111-111-111 265s WARNING NotebookApp:handlers.py:612 Kernel does not exist: 111-111-111-111-111 265s WARNING NotebookApp:log.py:59 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1) 4.730000ms referer=None 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 565194a3-c765-49c7-bd2c-cae5f5acc649 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 565194a3-c765-49c7-bd2c-cae5f5acc649 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/565194a3-c765-49c7-bd2c-cae5f5acc649 (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/565194a3-c765-49c7-bd2c-cae5f5acc649', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 265s yielded = ctx_run(next, result) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 265s yield maybe_future(km.shutdown_kernel(kernel_id)) 265s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 265s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 265s stopper = ensure_async(km.shutdown_kernel(now, restart)) 265s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/565194a3-c765-49c7-bd2c-cae5f5acc649 (127.0.0.1) 11.830000ms referer=None 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.090000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 57d1d7b9-7f79-4f58-89f2-3ba37e7ead18 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 57d1d7b9-7f79-4f58-89f2-3ba37e7ead18 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/57d1d7b9-7f79-4f58-89f2-3ba37e7ead18 (127.0.0.1) 1.620000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 565194a3-c765-49c7-bd2c-cae5f5acc649 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 565194a3-c765-49c7-bd2c-cae5f5acc649 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/565194a3-c765-49c7-bd2c-cae5f5acc649 (127.0.0.1) 1.730000ms 265s ____________________ KernelAPITest.test_main_kernel_handler ____________________ 265s 265s self = 265s 265s def test_main_kernel_handler(self): 265s # POST request 265s r = self.kern_api.start() 265s kern1 = r.json() 265s self.assertEqual(r.headers['location'], url_path_join(self.url_prefix, 'api/kernels', kern1['id'])) 265s self.assertEqual(r.status_code, 201) 265s self.assertIsInstance(kern1, dict) 265s 265s report_uri = url_path_join(self.url_prefix, 'api/security/csp-report') 265s expected_csp = '; '.join([ 265s "frame-ancestors 'self'", 265s 'report-uri ' + report_uri, 265s "default-src 'none'" 265s ]) 265s self.assertEqual(r.headers['Content-Security-Policy'], expected_csp) 265s 265s # GET request 265s r = self.kern_api.list() 265s self.assertEqual(r.status_code, 200) 265s assert isinstance(r.json(), list) 265s self.assertEqual(r.json()[0]['id'], kern1['id']) 265s self.assertEqual(r.json()[0]['name'], kern1['name']) 265s 265s # create another kernel and check that they both are added to the 265s # list of kernels from a GET request 265s kern2 = self.kern_api.start().json() 265s assert isinstance(kern2, dict) 265s r = self.kern_api.list() 265s kernels = r.json() 265s self.assertEqual(r.status_code, 200) 265s assert isinstance(kernels, list) 265s self.assertEqual(len(kernels), 2) 265s 265s # Interrupt a kernel 265s r = self.kern_api.interrupt(kern2['id']) 265s self.assertEqual(r.status_code, 204) 265s 265s # Restart a kernel 265s > r = self.kern_api.restart(kern2['id']) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:147: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:63: in restart 265s return self._req('POST', url_path_join(id, 'restart')) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: http://localhost:12341/a%40b/api/kernels/115a7bfc-c988-418e-a1cf-43fe9de55d19/restart 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 265s from pathlib import Path 265s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 265s from ._abc import * 265s File "/usr/lib/python3.13/pathlib/_abc.py", line 14, in 265s import functools 265s File "/usr/lib/python3.13/functools.py", line 18, in 265s from collections import namedtuple 265s File "/usr/lib/python3.13/collections/__init__.py", line 38, in 265s from keyword import iskeyword as _iskeyword 265s File "", line 1360, in _find_and_load 265s File "", line 1331, in _find_and_load_unlocked 265s File "", line 935, in _load_unlocked 265s File "", line 1019, in exec_module 265s File "", line 1109, in get_code 265s File "", line 1232, in path_stats 265s File "", line 152, in _path_stat 265s KeyboardInterrupt 265s Traceback (most recent call last): 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp790eae4_/runtime/kernel-a2c5e7be-cfd7-44f4-90b4-863c82126d49.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:54621 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:41321 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: a2c5e7be-cfd7-44f4-90b4-863c82126d49, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 22.260000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.970000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp790eae4_/runtime/kernel-115a7bfc-c988-418e-a1cf-43fe9de55d19.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:35727 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:46057 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: 115a7bfc-c988-418e-a1cf-43fe9de55d19, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 22.320000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 3.300000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: 115a7bfc-c988-418e-a1cf-43fe9de55d19 265s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/115a7bfc-c988-418e-a1cf-43fe9de55d19/interrupt (127.0.0.1) 1.490000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 265s yield maybe_future(km.restart_kernel(kernel_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 265s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 265s await ensure_async(kernel.restart_kernel(now=now)) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 265s await self._async_shutdown_kernel(now=now, restart=True) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/115a7bfc-c988-418e-a1cf-43fe9de55d19/restart (127.0.0.1) 5.890000ms referer=None 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.010000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for a2c5e7be-cfd7-44f4-90b4-863c82126d49 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a2c5e7be-cfd7-44f4-90b4-863c82126d49 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/a2c5e7be-cfd7-44f4-90b4-863c82126d49 (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/a2c5e7be-cfd7-44f4-90b4-863c82126d49', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 265s yielded = ctx_run(next, result) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 265s yield maybe_future(km.shutdown_kernel(kernel_id)) 265s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 265s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 265s stopper = ensure_async(km.shutdown_kernel(now, restart)) 265s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/a2c5e7be-cfd7-44f4-90b4-863c82126d49 (127.0.0.1) 11.310000ms referer=None 265s ________________________ KernelAPITest.test_no_kernels _________________________ 265s 265s self = 265s 265s def test_no_kernels(self): 265s """Make sure there are no kernels running at the start""" 265s kernels = self.kern_api.list().json() 265s > self.assertEqual(kernels, []) 265s E AssertionError: Lists differ: [{'id': 'a2c5e7be-cfd7-44f4-90b4-863c82126[281 chars]: 0}] != [] 265s E 265s E First list contains 2 additional elements. 265s E First extra element 0: 265s E {'id': 'a2c5e7be-cfd7-44f4-90b4-863c82126d49', 'name': 'python3', 'last_activity': '2026-02-06T04:18:54.453394Z', 'execution_state': 'starting', 'connections': 0} 265s E 265s E + [] 265s E - [{'connections': 0, 265s E - 'execution_state': 'starting', 265s E - 'id': 'a2c5e7be-cfd7-44f4-90b4-863c82126d49', 265s E - 'last_activity': '2026-02-06T04:18:54.453394Z', 265s E - 'name': 'python3'}, 265s E - {'connections': 0, 265s E - 'execution_state': 'starting', 265s E - 'id': '115a7bfc-c988-418e-a1cf-43fe9de55d19', 265s E - 'last_activity': '2026-02-06T04:18:54.485379Z', 265s E - 'name': 'python3'}] 265s 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:91: AssertionError 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.050000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.000000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for a2c5e7be-cfd7-44f4-90b4-863c82126d49 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a2c5e7be-cfd7-44f4-90b4-863c82126d49 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/a2c5e7be-cfd7-44f4-90b4-863c82126d49 (127.0.0.1) 1.690000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 115a7bfc-c988-418e-a1cf-43fe9de55d19 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 115a7bfc-c988-418e-a1cf-43fe9de55d19 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/115a7bfc-c988-418e-a1cf-43fe9de55d19 (127.0.0.1) 1.660000ms 265s ---------------------------- Captured log teardown ----------------------------- 265s INFO NotebookApp:notebookapp.py:2164 Shutting down 0 kernels 265s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 265s _____________________ AsyncKernelAPITest.test_connections ______________________ 265s 265s self = 265s 265s def tearDown(self): 265s for k in self.kern_api.list().json(): 265s > self.kern_api.shutdown(k['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/147cf816-561e-4d7e-a6f4-ea58425d26ed 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ------------------------------ Captured log setup ------------------------------ 265s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmpscvvf8gi/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmpscvvf8gi/etc/jupyter'] for config files 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpscvvf8gi/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpscvvf8gi/config 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpscvvf8gi/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpscvvf8gi/config 265s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmpscvvf8gi/notebooks 265s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 265s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 265s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 265s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 265s WARNING NotebookApp:handlers.py:612 Forbidden 265s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 0.830000ms referer=None 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpscvvf8gi/runtime/kernel-147cf816-561e-4d7e-a6f4-ea58425d26ed.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34563 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34313 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: 147cf816-561e-4d7e-a6f4-ea58425d26ed, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 29.930000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/147cf816-561e-4d7e-a6f4-ea58425d26ed (127.0.0.1) 1.780000ms 265s DEBUG NotebookApp:zmqhandlers.py:298 Initializing websocket connection /a%40b/api/kernels/147cf816-561e-4d7e-a6f4-ea58425d26ed/channels 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s WARNING NotebookApp:zmqhandlers.py:286 No session ID specified 265s DEBUG NotebookApp:handlers.py:277 Requesting kernel info from 147cf816-561e-4d7e-a6f4-ea58425d26ed 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:40781 265s DEBUG NotebookApp:kernelmanager.py:423 activity on 147cf816-561e-4d7e-a6f4-ea58425d26ed: status (starting) 265s DEBUG NotebookApp:kernelmanager.py:423 activity on 147cf816-561e-4d7e-a6f4-ea58425d26ed: status (busy) 265s DEBUG NotebookApp:handlers.py:306 Received kernel info: {'status': 'ok', 'protocol_version': '5.3', 'implementation': 'ipython', 'implementation_version': '8.35.0', 'language_info': {'name': 'python', 'version': '3.13.11', 'mimetype': 'text/x-python', 'codemirror_mode': {'name': 'ipython', 'version': 3}, 'pygments_lexer': 'ipython3', 'nbconvert_exporter': 'python', 'file_extension': '.py'}, 'banner': "Python 3.13.11 (main, Dec 6 2025, 13:15:20) [GCC 15.2.0]\nType 'copyright', 'credits' or 'license' for more information\nIPython 8.35.0 -- An enhanced Interactive Python. Type '?' for help.\n", 'help_links': [{'text': 'Python Reference', 'url': 'https://docs.python.org/3.13'}, {'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/'}]} 265s INFO NotebookApp:handlers.py:326 Adapting from protocol version 5.3 (kernel 147cf816-561e-4d7e-a6f4-ea58425d26ed) to 5.4 (client). 265s DEBUG NotebookApp:kernelmanager.py:423 activity on 147cf816-561e-4d7e-a6f4-ea58425d26ed: status (idle) 265s DEBUG NotebookApp:log.py:59 101 GET /a%40b/api/kernels/147cf816-561e-4d7e-a6f4-ea58425d26ed/channels (127.0.0.1) 676.630000ms 265s DEBUG NotebookApp:zmqhandlers.py:159 Opening websocket /a%40b/api/kernels/147cf816-561e-4d7e-a6f4-ea58425d26ed/channels 265s DEBUG NotebookApp:kernelmanager.py:252 Getting buffer for 147cf816-561e-4d7e-a6f4-ea58425d26ed 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34313 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:40781 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34563 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:33851 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:40781 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34563 265s WARNING NotebookApp:websocket.py:1327 The websocket_ping_timeout (90000) cannot be longer than the websocket_ping_interval (30000). 265s Setting websocket_ping_timeout=30000 265s DEBUG NotebookApp:handlers.py:255 Nudge: attempt 1 on kernel 147cf816-561e-4d7e-a6f4-ea58425d26ed 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/147cf816-561e-4d7e-a6f4-ea58425d26ed (127.0.0.1) 2.300000ms 265s DEBUG NotebookApp:kernelmanager.py:423 activity on 147cf816-561e-4d7e-a6f4-ea58425d26ed: status (busy) 265s DEBUG NotebookApp:handlers.py:207 Nudge: IOPub received: 147cf816-561e-4d7e-a6f4-ea58425d26ed 265s DEBUG NotebookApp:handlers.py:210 Nudge: resolving iopub future: 147cf816-561e-4d7e-a6f4-ea58425d26ed 265s DEBUG NotebookApp:kernelmanager.py:423 activity on 147cf816-561e-4d7e-a6f4-ea58425d26ed: status (busy) 265s DEBUG NotebookApp:kernelmanager.py:423 activity on 147cf816-561e-4d7e-a6f4-ea58425d26ed: status (idle) 265s DEBUG NotebookApp:handlers.py:195 Nudge: shell info reply received: 147cf816-561e-4d7e-a6f4-ea58425d26ed 265s DEBUG NotebookApp:handlers.py:197 Nudge: resolving shell future: 147cf816-561e-4d7e-a6f4-ea58425d26ed 265s DEBUG NotebookApp:handlers.py:201 Nudge: control info reply received: 147cf816-561e-4d7e-a6f4-ea58425d26ed 265s DEBUG NotebookApp:kernelmanager.py:423 activity on 147cf816-561e-4d7e-a6f4-ea58425d26ed: status (idle) 265s DEBUG NotebookApp:handlers.py:579 Websocket closed 147cf816-561e-4d7e-a6f4-ea58425d26ed:5811a87c-307bff1d7693f4aa93564bf6 265s INFO NotebookApp:kernelmanager.py:222 Starting buffering for 147cf816-561e-4d7e-a6f4-ea58425d26ed:5811a87c-307bff1d7693f4aa93564bf6 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 147cf816-561e-4d7e-a6f4-ea58425d26ed 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:235 Buffering msg on 147cf816-561e-4d7e-a6f4-ea58425d26ed:iopub 265s DEBUG NotebookApp:kernelmanager.py:235 Buffering msg on 147cf816-561e-4d7e-a6f4-ea58425d26ed:iopub 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/147cf816-561e-4d7e-a6f4-ea58425d26ed (127.0.0.1) 1.330000ms 265s DEBUG NotebookApp:kernelmanager.py:235 Buffering msg on 147cf816-561e-4d7e-a6f4-ea58425d26ed:iopub 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/147cf816-561e-4d7e-a6f4-ea58425d26ed (127.0.0.1) 1.220000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 5.780000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 147cf816-561e-4d7e-a6f4-ea58425d26ed 265s INFO NotebookApp:kernelmanager.py:286 Discarding 3 buffered messages for 147cf816-561e-4d7e-a6f4-ea58425d26ed:5811a87c-307bff1d7693f4aa93564bf6 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 147cf816-561e-4d7e-a6f4-ea58425d26ed 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/147cf816-561e-4d7e-a6f4-ea58425d26ed (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/147cf816-561e-4d7e-a6f4-ea58425d26ed', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 265s future.result() 265s ~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 265s yield maybe_future(km.shutdown_kernel(kernel_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 265s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 265s raise km.ready.exception() # type: ignore[misc] 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/147cf816-561e-4d7e-a6f4-ea58425d26ed (127.0.0.1) 8.640000ms referer=None 265s ____________________ AsyncKernelAPITest.test_default_kernel ____________________ 265s 265s self = 265s 265s def tearDown(self): 265s for k in self.kern_api.list().json(): 265s > self.kern_api.shutdown(k['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/4aded73f-b802-497e-aed7-532e2cebc415 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpscvvf8gi/runtime/kernel-4aded73f-b802-497e-aed7-532e2cebc415.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:50343 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:51389 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: 4aded73f-b802-497e-aed7-532e2cebc415, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 22.450000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.990000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 147cf816-561e-4d7e-a6f4-ea58425d26ed 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 147cf816-561e-4d7e-a6f4-ea58425d26ed 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/147cf816-561e-4d7e-a6f4-ea58425d26ed (127.0.0.1) 1.410000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 4aded73f-b802-497e-aed7-532e2cebc415 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 4aded73f-b802-497e-aed7-532e2cebc415 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/4aded73f-b802-497e-aed7-532e2cebc415 (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/4aded73f-b802-497e-aed7-532e2cebc415', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 265s future.result() 265s ~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 265s yield maybe_future(km.shutdown_kernel(kernel_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 265s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 265s raise km.ready.exception() # type: ignore[misc] 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/4aded73f-b802-497e-aed7-532e2cebc415 (127.0.0.1) 7.270000ms referer=None 265s --------------------------- Captured stderr teardown --------------------------- 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 265s from .connect import * # noqa: F403 265s ^^^^^^^^^^^^^^^^^^^^^^ 265s KeyboardInterrupt 265s ____________________ AsyncKernelAPITest.test_kernel_handler ____________________ 265s 265s self = 265s 265s def test_kernel_handler(self): 265s # GET kernel with given id 265s kid = self.kern_api.start().json()['id'] 265s r = self.kern_api.get(kid) 265s kern1 = r.json() 265s self.assertEqual(r.status_code, 200) 265s assert isinstance(kern1, dict) 265s self.assertIn('id', kern1) 265s self.assertEqual(kern1['id'], kid) 265s 265s # Request a bad kernel id and check that a JSON 265s # message is returned! 265s bad_id = '111-111-111-111-111' 265s with assert_http_error(404, 'Kernel does not exist: ' + bad_id): 265s self.kern_api.get(bad_id) 265s 265s # DELETE kernel with id 265s > r = self.kern_api.shutdown(kid) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:169: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/bc732eff-9072-48e2-bde9-d4dccbda9bf7 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 265s from pathlib import Path 265s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 265s from ._local import * 265s File "/usr/lib/python3.13/pathlib/_local.py", line 6, in 265s import warnings 265s File "", line 1360, in _find_and_load 265s File "", line 1322, in _find_and_load_unlocked 265s File "", line 1262, in _find_spec 265s File "", line 1556, in find_spec 265s File "", line 1530, in _get_spec 265s File "", line 1629, in find_spec 265s File "", line 152, in _path_stat 265s KeyboardInterrupt 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpscvvf8gi/runtime/kernel-bc732eff-9072-48e2-bde9-d4dccbda9bf7.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:45161 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:46671 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: bc732eff-9072-48e2-bde9-d4dccbda9bf7, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 18.280000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/bc732eff-9072-48e2-bde9-d4dccbda9bf7 (127.0.0.1) 1.020000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s WARNING NotebookApp:web.py:1943 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1): Kernel does not exist: 111-111-111-111-111 265s WARNING NotebookApp:handlers.py:612 Kernel does not exist: 111-111-111-111-111 265s WARNING NotebookApp:log.py:59 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1) 1.130000ms referer=None 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for bc732eff-9072-48e2-bde9-d4dccbda9bf7 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: bc732eff-9072-48e2-bde9-d4dccbda9bf7 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/bc732eff-9072-48e2-bde9-d4dccbda9bf7 (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/bc732eff-9072-48e2-bde9-d4dccbda9bf7', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 265s future.result() 265s ~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 265s yield maybe_future(km.shutdown_kernel(kernel_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 265s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 265s raise km.ready.exception() # type: ignore[misc] 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/bc732eff-9072-48e2-bde9-d4dccbda9bf7 (127.0.0.1) 16.910000ms referer=None 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.050000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 4aded73f-b802-497e-aed7-532e2cebc415 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 4aded73f-b802-497e-aed7-532e2cebc415 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/4aded73f-b802-497e-aed7-532e2cebc415 (127.0.0.1) 2.030000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for bc732eff-9072-48e2-bde9-d4dccbda9bf7 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: bc732eff-9072-48e2-bde9-d4dccbda9bf7 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/bc732eff-9072-48e2-bde9-d4dccbda9bf7 (127.0.0.1) 1.180000ms 265s _________________ AsyncKernelAPITest.test_main_kernel_handler __________________ 265s 265s self = 265s 265s def test_main_kernel_handler(self): 265s # POST request 265s r = self.kern_api.start() 265s kern1 = r.json() 265s self.assertEqual(r.headers['location'], url_path_join(self.url_prefix, 'api/kernels', kern1['id'])) 265s self.assertEqual(r.status_code, 201) 265s self.assertIsInstance(kern1, dict) 265s 265s report_uri = url_path_join(self.url_prefix, 'api/security/csp-report') 265s expected_csp = '; '.join([ 265s "frame-ancestors 'self'", 265s 'report-uri ' + report_uri, 265s "default-src 'none'" 265s ]) 265s self.assertEqual(r.headers['Content-Security-Policy'], expected_csp) 265s 265s # GET request 265s r = self.kern_api.list() 265s self.assertEqual(r.status_code, 200) 265s assert isinstance(r.json(), list) 265s self.assertEqual(r.json()[0]['id'], kern1['id']) 265s self.assertEqual(r.json()[0]['name'], kern1['name']) 265s 265s # create another kernel and check that they both are added to the 265s # list of kernels from a GET request 265s kern2 = self.kern_api.start().json() 265s assert isinstance(kern2, dict) 265s r = self.kern_api.list() 265s kernels = r.json() 265s self.assertEqual(r.status_code, 200) 265s assert isinstance(kernels, list) 265s self.assertEqual(len(kernels), 2) 265s 265s # Interrupt a kernel 265s r = self.kern_api.interrupt(kern2['id']) 265s self.assertEqual(r.status_code, 204) 265s 265s # Restart a kernel 265s > r = self.kern_api.restart(kern2['id']) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:147: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:63: in restart 265s return self._req('POST', url_path_join(id, 'restart')) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: http://localhost:12341/a%40b/api/kernels/d3a74d5c-10c6-4028-9fa1-1b0d1ea68774/restart 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 265s from pathlib import Path 265s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 265s from ._abc import * 265s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 265s from glob import _Globber, _no_recurse_symlinks 265s File "/usr/lib/python3.13/glob.py", line 5, in 265s import re 265s File "/usr/lib/python3.13/re/__init__.py", line 125, in 265s import enum 265s File "/usr/lib/python3.13/enum.py", line 23, in 265s class nonmember(object): 265s KeyboardInterrupt 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 265s from .connect import * # noqa: F403 265s ^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 12, in 265s import jupyter_client 265s File "/usr/lib/python3/dist-packages/jupyter_client/__init__.py", line 4, in 265s from .asynchronous import AsyncKernelClient 265s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/__init__.py", line 1, in 265s from .client import AsyncKernelClient # noqa 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/client.py", line 9, in 265s import zmq.asyncio 265s File "/usr/lib/python3/dist-packages/zmq/asyncio.py", line 10, in 265s import asyncio 265s File "/usr/lib/python3.13/asyncio/__init__.py", line 8, in 265s from .base_events import * 265s File "/usr/lib/python3.13/asyncio/base_events.py", line 23, in 265s import socket 265s File "/usr/lib/python3.13/socket.py", line 76, in 265s IntEnum._convert_( 265s ~~~~~~~~~~~~~~~~~^ 265s 'AddressFamily', 265s ^^^^^^^^^^^^^^^^ 265s __name__, 265s ^^^^^^^^^ 265s lambda C: C.isupper() and C.startswith('AF_')) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3.13/enum.py", line 928, in _convert_ 265s cls = _simple_enum(etype=cls, boundary=boundary or KEEP)(tmp_cls) 265s File "/usr/lib/python3.13/enum.py", line 1909, in convert_class 265s setattr(enum_class, name, member) 265s ~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3.13/enum.py", line 829, in __setattr__ 265s def __setattr__(cls, name, value): 265s 265s KeyboardInterrupt 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpscvvf8gi/runtime/kernel-bc5461eb-4847-40c5-8876-263090e68dea.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:37845 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:59371 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: bc5461eb-4847-40c5-8876-263090e68dea, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 20.840000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.060000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpscvvf8gi/runtime/kernel-d3a74d5c-10c6-4028-9fa1-1b0d1ea68774.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:42381 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:46991 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: d3a74d5c-10c6-4028-9fa1-1b0d1ea68774, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 20.060000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.090000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: d3a74d5c-10c6-4028-9fa1-1b0d1ea68774 265s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/d3a74d5c-10c6-4028-9fa1-1b0d1ea68774/interrupt (127.0.0.1) 1.460000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 265s yield maybe_future(km.restart_kernel(kernel_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 291, in __step_run_and_handle_result 265s result = coro.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 265s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 265s File "/usr/lib/python3.14/asyncio/futures.py", line 295, in __await__ 265s yield self # This tells Task to wait for completion. 265s ^^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 265s future.result() 265s ~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 265s await ensure_async(kernel.restart_kernel(now=now)) 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 265s await self._async_shutdown_kernel(now=now, restart=True) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/d3a74d5c-10c6-4028-9fa1-1b0d1ea68774/restart (127.0.0.1) 9.890000ms referer=None 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.160000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for bc5461eb-4847-40c5-8876-263090e68dea 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: bc5461eb-4847-40c5-8876-263090e68dea 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/bc5461eb-4847-40c5-8876-263090e68dea (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/bc5461eb-4847-40c5-8876-263090e68dea', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 265s future.result() 265s ~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 265s yield maybe_future(km.shutdown_kernel(kernel_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 265s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 265s raise km.ready.exception() # type: ignore[misc] 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/bc5461eb-4847-40c5-8876-263090e68dea (127.0.0.1) 11.750000ms referer=None 265s ______________________ AsyncKernelAPITest.test_no_kernels ______________________ 265s 265s self = 265s 265s def test_no_kernels(self): 265s """Make sure there are no kernels running at the start""" 265s kernels = self.kern_api.list().json() 265s > self.assertEqual(kernels, []) 265s E AssertionError: Lists differ: [{'id': 'bc5461eb-4847-40c5-8876-263090e68[281 chars]: 0}] != [] 265s E 265s E First list contains 2 additional elements. 265s E First extra element 0: 265s E {'id': 'bc5461eb-4847-40c5-8876-263090e68dea', 'name': 'python3', 'last_activity': '2026-02-06T04:18:55.704771Z', 'execution_state': 'starting', 'connections': 0} 265s E 265s E + [] 265s E - [{'connections': 0, 265s E - 'execution_state': 'starting', 265s E - 'id': 'bc5461eb-4847-40c5-8876-263090e68dea', 265s E - 'last_activity': '2026-02-06T04:18:55.704771Z', 265s E - 'name': 'python3'}, 265s E - {'connections': 0, 265s E - 'execution_state': 'starting', 265s E - 'id': 'd3a74d5c-10c6-4028-9fa1-1b0d1ea68774', 265s E - 'last_activity': '2026-02-06T04:18:55.737207Z', 265s E - 'name': 'python3'}] 265s 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:91: AssertionError 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.090000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.060000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for bc5461eb-4847-40c5-8876-263090e68dea 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: bc5461eb-4847-40c5-8876-263090e68dea 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/bc5461eb-4847-40c5-8876-263090e68dea (127.0.0.1) 1.230000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for d3a74d5c-10c6-4028-9fa1-1b0d1ea68774 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: d3a74d5c-10c6-4028-9fa1-1b0d1ea68774 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/d3a74d5c-10c6-4028-9fa1-1b0d1ea68774 (127.0.0.1) 1.330000ms 265s ---------------------------- Captured log teardown ----------------------------- 265s INFO NotebookApp:notebookapp.py:2164 Shutting down 0 kernels 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 147cf816-561e-4d7e-a6f4-ea58425d26ed 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 4aded73f-b802-497e-aed7-532e2cebc415 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: bc732eff-9072-48e2-bde9-d4dccbda9bf7 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: bc5461eb-4847-40c5-8876-263090e68dea 265s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 265s __________________________ SessionAPITest.test_create __________________________ 265s 265s @self.addCleanup 265s def cleanup_sessions(): 265s for session in self.sess_api.list().json(): 265s > self.sess_api.delete(session['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/4475106d-1091-4445-bbef-f610d3dd1389 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ------------------------------ Captured log setup ------------------------------ 265s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmpkt2qg12p/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmpkt2qg12p/etc/jupyter'] for config files 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpkt2qg12p/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpkt2qg12p/config 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpkt2qg12p/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpkt2qg12p/config 265s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmpkt2qg12p/notebooks 265s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 265s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 265s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 265s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 265s WARNING NotebookApp:handlers.py:612 Forbidden 265s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 0.760000ms referer=None 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 265s from .connect import * # noqa: F403 265s ^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 9, in 265s from subprocess import PIPE, Popen 265s File "", line 1360, in _find_and_load 265s File "", line 1331, in _find_and_load_unlocked 265s File "", line 935, in _load_unlocked 265s File "", line 1019, in exec_module 265s File "", line 1115, in get_code 265s File "", line 1215, in get_data 265s KeyboardInterrupt 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.380000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkt2qg12p/runtime/kernel-da600eed-5ab9-40e9-b582-f68c169a6bc2.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:37961 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:58797 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: da600eed-5ab9-40e9-b582-f68c169a6bc2, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpkt2qg12p/notebooks/foo'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 27.110000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.050000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions/4475106d-1091-4445-bbef-f610d3dd1389 (127.0.0.1) 1.350000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.030000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for da600eed-5ab9-40e9-b582-f68c169a6bc2 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: da600eed-5ab9-40e9-b582-f68c169a6bc2 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/4475106d-1091-4445-bbef-f610d3dd1389 (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/4475106d-1091-4445-bbef-f610d3dd1389', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 265s yielded = self.gen.send(value) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 265s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 265s stopper = ensure_async(km.shutdown_kernel(now, restart)) 265s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/4475106d-1091-4445-bbef-f610d3dd1389 (127.0.0.1) 9.580000ms referer=None 265s __________________ SessionAPITest.test_create_console_session __________________ 265s 265s @self.addCleanup 265s def cleanup_sessions(): 265s for session in self.sess_api.list().json(): 265s > self.sess_api.delete(session['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/f2df0bd8-32b3-47cc-931f-84d8e59780cd 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 265s from .connect import * # noqa: F403 265s ^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 10, in 265s from typing import TYPE_CHECKING, Any 265s File "", line 1360, in _find_and_load 265s File "", line 1331, in _find_and_load_unlocked 265s File "", line 935, in _load_unlocked 265s File "", line 1019, in exec_module 265s File "", line 1115, in get_code 265s File "", line 1215, in get_data 265s KeyboardInterrupt 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkt2qg12p/runtime/kernel-6c8c3592-b43b-4249-8831-bdd68abf55f0.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55525 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:52383 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: 6c8c3592-b43b-4249-8831-bdd68abf55f0, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpkt2qg12p/notebooks/foo'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 22.580000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.350000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for da600eed-5ab9-40e9-b582-f68c169a6bc2 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: da600eed-5ab9-40e9-b582-f68c169a6bc2 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/4475106d-1091-4445-bbef-f610d3dd1389 (127.0.0.1) 3.000000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 6c8c3592-b43b-4249-8831-bdd68abf55f0 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 6c8c3592-b43b-4249-8831-bdd68abf55f0 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/f2df0bd8-32b3-47cc-931f-84d8e59780cd (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/f2df0bd8-32b3-47cc-931f-84d8e59780cd', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 265s yielded = self.gen.send(value) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 265s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 265s stopper = ensure_async(km.shutdown_kernel(now, restart)) 265s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/f2df0bd8-32b3-47cc-931f-84d8e59780cd (127.0.0.1) 17.230000ms referer=None 265s ____________________ SessionAPITest.test_create_deprecated _____________________ 265s 265s @self.addCleanup 265s def cleanup_sessions(): 265s for session in self.sess_api.list().json(): 265s > self.sess_api.delete(session['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/3b296c17-3a01-4855-bab5-aec4ea0442b2 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 265s from .connect import * # noqa: F403 265s ^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 12, in 265s import jupyter_client 265s File "/usr/lib/python3/dist-packages/jupyter_client/__init__.py", line 4, in 265s from .asynchronous import AsyncKernelClient 265s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/__init__.py", line 1, in 265s from .client import AsyncKernelClient # noqa 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/client.py", line 9, in 265s import zmq.asyncio 265s File "/usr/lib/python3/dist-packages/zmq/__init__.py", line 52, in 265s from zmq import backend 265s File "/usr/lib/python3/dist-packages/zmq/backend/__init__.py", line 7, in 265s import platform 265s File "/usr/lib/python3.13/platform.py", line 572, in 265s AndroidVer = collections.namedtuple( 265s "AndroidVer", "release api_level manufacturer model device is_emulator") 265s File "/usr/lib/python3.13/collections/__init__.py", line 444, in namedtuple 265s __new__ = eval(code, namespace) 265s File "", line 0, in 265s KeyboardInterrupt 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s WARNING NotebookApp:handlers.py:46 Sessions API changed, see updated swagger docs 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkt2qg12p/runtime/kernel-39118713-bef3-4935-83ea-df4cbc7774ca.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:58329 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:46029 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: 39118713-bef3-4935-83ea-df4cbc7774ca, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpkt2qg12p/notebooks/foo'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 23.190000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.240000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 6c8c3592-b43b-4249-8831-bdd68abf55f0 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 6c8c3592-b43b-4249-8831-bdd68abf55f0 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/f2df0bd8-32b3-47cc-931f-84d8e59780cd (127.0.0.1) 3.530000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 39118713-bef3-4935-83ea-df4cbc7774ca 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 39118713-bef3-4935-83ea-df4cbc7774ca 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/3b296c17-3a01-4855-bab5-aec4ea0442b2 (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/3b296c17-3a01-4855-bab5-aec4ea0442b2', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 265s yielded = self.gen.send(value) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 265s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 265s stopper = ensure_async(km.shutdown_kernel(now, restart)) 265s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/3b296c17-3a01-4855-bab5-aec4ea0442b2 (127.0.0.1) 18.120000ms referer=None 265s ___________________ SessionAPITest.test_create_file_session ____________________ 265s 265s @self.addCleanup 265s def cleanup_sessions(): 265s for session in self.sess_api.list().json(): 265s > self.sess_api.delete(session['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/7c6250ea-254e-48aa-949f-e0bc743c0ce5 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 265s from .connect import * # noqa: F403 265s ^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 10, in 265s from typing import TYPE_CHECKING, Any 265s File "", line 1360, in _find_and_load 265s File "", line 1331, in _find_and_load_unlocked 265s File "", line 935, in _load_unlocked 265s File "", line 1019, in exec_module 265s File "", line 1152, in get_code 265s File "", line 781, in _compile_bytecode 265s KeyboardInterrupt 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkt2qg12p/runtime/kernel-85fa53da-3715-43d4-9257-4913a8fa0705.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:43105 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:38001 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: 85fa53da-3715-43d4-9257-4913a8fa0705, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpkt2qg12p/notebooks/foo'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 25.260000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.200000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 39118713-bef3-4935-83ea-df4cbc7774ca 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 39118713-bef3-4935-83ea-df4cbc7774ca 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/3b296c17-3a01-4855-bab5-aec4ea0442b2 (127.0.0.1) 6.510000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 85fa53da-3715-43d4-9257-4913a8fa0705 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 85fa53da-3715-43d4-9257-4913a8fa0705 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/7c6250ea-254e-48aa-949f-e0bc743c0ce5 (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/7c6250ea-254e-48aa-949f-e0bc743c0ce5', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 265s yielded = self.gen.send(value) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 265s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 265s stopper = ensure_async(km.shutdown_kernel(now, restart)) 265s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/7c6250ea-254e-48aa-949f-e0bc743c0ce5 (127.0.0.1) 12.390000ms referer=None 265s __________________ SessionAPITest.test_create_with_kernel_id ___________________ 265s 265s self = 265s 265s def test_create_with_kernel_id(self): 265s # create a new kernel 265s r = self.request('POST', 'api/kernels') 265s r.raise_for_status() 265s kernel = r.json() 265s 265s resp = self.sess_api.create('foo/nb1.ipynb', kernel_id=kernel['id']) 265s self.assertEqual(resp.status_code, 201) 265s newsession = resp.json() 265s self.assertIn('id', newsession) 265s self.assertEqual(newsession['path'], 'foo/nb1.ipynb') 265s self.assertEqual(newsession['kernel']['id'], kernel['id']) 265s self.assertEqual(resp.headers['Location'], f'{self.url_prefix}api/sessions/{newsession["id"]}') 265s 265s sessions = self.sess_api.list().json() 265s > self.assertEqual(sessions, [newsession]) 265s E AssertionError: Lists differ: [{'id': '7c6250ea-254e-48aa-949f-e0bc743c0ce5', 'p[553 chars]ne}}] != [{'id': '4666c052-1748-488f-8757-8c243d31895d', 'p[279 chars]ne}}] 265s E 265s E First differing element 0: 265s E {'id': '7c6250ea-254e-48aa-949f-e0bc743c0ce5', 'p[218 chars]: 0}} 265s E {'id': '4666c052-1748-488f-8757-8c243d31895d', 'p[278 chars]one}} 265s E 265s E First list contains 1 additional elements. 265s E First extra element 1: 265s E {'id': '4666c052-1748-488f-8757-8c243d31895d', 'path': 'foo/nb1.ipynb', 'name': None, 'type': 'notebook', 'kernel': {'id': 'da2f684e-a243-4573-805f-5e368fed74c9', 'name': 'python3', 'last_activity': '2026-02-06T04:18:56.433605Z', 'execution_state': 'starting', 'connections': 0}, 'notebook': {'path': 'foo/nb1.ipynb', 'name': None}} 265s E 265s E Diff is 830 characters long. Set self.maxDiff to None to see it. 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:178: AssertionError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkt2qg12p/runtime/kernel-da2f684e-a243-4573-805f-5e368fed74c9.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:35533 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:41407 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: da2f684e-a243-4573-805f-5e368fed74c9, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 20.630000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.310000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.050000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.010000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 85fa53da-3715-43d4-9257-4913a8fa0705 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 85fa53da-3715-43d4-9257-4913a8fa0705 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/7c6250ea-254e-48aa-949f-e0bc743c0ce5 (127.0.0.1) 1.810000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for da2f684e-a243-4573-805f-5e368fed74c9 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: da2f684e-a243-4573-805f-5e368fed74c9 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/4666c052-1748-488f-8757-8c243d31895d (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/4666c052-1748-488f-8757-8c243d31895d', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 265s yielded = self.gen.send(value) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 265s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 265s stopper = ensure_async(km.shutdown_kernel(now, restart)) 265s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/4666c052-1748-488f-8757-8c243d31895d (127.0.0.1) 10.040000ms referer=None 265s _____________________ SessionAPITest.test_modify_kernel_id _____________________ 265s 265s @self.addCleanup 265s def cleanup_sessions(): 265s for session in self.sess_api.list().json(): 265s > self.sess_api.delete(session['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/4666c052-1748-488f-8757-8c243d31895d 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 265s from .connect import * # noqa: F403 265s ^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 9, in 265s from subprocess import PIPE, Popen 265s File "/usr/lib/python3.13/subprocess.py", line 46, in 265s import locale 265s File "", line 1360, in _find_and_load 265s File "", line 1331, in _find_and_load_unlocked 265s File "", line 946, in _load_unlocked 265s KeyboardInterrupt 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.180000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkt2qg12p/runtime/kernel-e4c0768f-33c1-46e4-bf07-012c6fd290af.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55101 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:53681 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: e4c0768f-33c1-46e4-bf07-012c6fd290af, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 19.400000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for da2f684e-a243-4573-805f-5e368fed74c9 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: da2f684e-a243-4573-805f-5e368fed74c9 265s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/4666c052-1748-488f-8757-8c243d31895d (127.0.0.1) 2.030000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 2.840000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.100000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for e4c0768f-33c1-46e4-bf07-012c6fd290af 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: e4c0768f-33c1-46e4-bf07-012c6fd290af 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/4666c052-1748-488f-8757-8c243d31895d (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/4666c052-1748-488f-8757-8c243d31895d', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 265s yielded = self.gen.send(value) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 265s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 265s stopper = ensure_async(km.shutdown_kernel(now, restart)) 265s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/4666c052-1748-488f-8757-8c243d31895d (127.0.0.1) 13.360000ms referer=None 265s ____________________ SessionAPITest.test_modify_kernel_name ____________________ 265s 265s @self.addCleanup 265s def cleanup_sessions(): 265s for session in self.sess_api.list().json(): 265s > self.sess_api.delete(session['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/4666c052-1748-488f-8757-8c243d31895d 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 265s from .connect import * # noqa: F403 265s ^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 10, in 265s from typing import TYPE_CHECKING, Any 265s File "", line 1360, in _find_and_load 265s File "", line 1331, in _find_and_load_unlocked 265s File "", line 935, in _load_unlocked 265s File "", line 1019, in exec_module 265s File "", line 1115, in get_code 265s File "", line 1215, in get_data 265s KeyboardInterrupt 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.180000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkt2qg12p/runtime/kernel-6fe10b8e-622b-4ab2-a53a-fb5f101d0b9d.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:37221 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:50245 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: 6fe10b8e-622b-4ab2-a53a-fb5f101d0b9d, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3', 'cwd': '/tmp/tmpkt2qg12p/notebooks/foo'} 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for e4c0768f-33c1-46e4-bf07-012c6fd290af 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: e4c0768f-33c1-46e4-bf07-012c6fd290af 265s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/4666c052-1748-488f-8757-8c243d31895d (127.0.0.1) 25.500000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.040000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.130000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 6fe10b8e-622b-4ab2-a53a-fb5f101d0b9d 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 6fe10b8e-622b-4ab2-a53a-fb5f101d0b9d 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/4666c052-1748-488f-8757-8c243d31895d (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/4666c052-1748-488f-8757-8c243d31895d', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 265s yielded = self.gen.send(value) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 265s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 265s stopper = ensure_async(km.shutdown_kernel(now, restart)) 265s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/4666c052-1748-488f-8757-8c243d31895d (127.0.0.1) 16.810000ms referer=None 265s _______________________ SessionAPITest.test_modify_type ________________________ 265s 265s @self.addCleanup 265s def cleanup_sessions(): 265s for session in self.sess_api.list().json(): 265s > self.sess_api.delete(session['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/9beadc0c-f8bf-4125-8e78-97ec86904070 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 265s from .connect import * # noqa: F403 265s ^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 9, in 265s from subprocess import PIPE, Popen 265s File "/usr/lib/python3.13/subprocess.py", line 46, in 265s import locale 265s File "/usr/lib/python3.13/locale.py", line 1769, in 265s __all__.append("LC_MESSAGES") 265s ~~~~~~~~~~~~~~^^^^^^^^^^^^^^^ 265s KeyboardInterrupt 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpkt2qg12p/runtime/kernel-105f4681-2fc7-4437-8e61-2e97fe7e7d7a.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34365 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:59883 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: 105f4681-2fc7-4437-8e61-2e97fe7e7d7a, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpkt2qg12p/notebooks/foo'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 29.040000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/9beadc0c-f8bf-4125-8e78-97ec86904070 (127.0.0.1) 2.400000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.080000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 105f4681-2fc7-4437-8e61-2e97fe7e7d7a 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 105f4681-2fc7-4437-8e61-2e97fe7e7d7a 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/9beadc0c-f8bf-4125-8e78-97ec86904070 (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/9beadc0c-f8bf-4125-8e78-97ec86904070', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 265s yielded = self.gen.send(value) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 265s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 265s stopper = ensure_async(km.shutdown_kernel(now, restart)) 265s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 265s return _runner_map[name].run(inner) 265s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 265s return fut.result(None) 265s ~~~~~~~~~~^^^^^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 265s return self.__get_result() 265s ~~~~~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 265s raise self._exception 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/9beadc0c-f8bf-4125-8e78-97ec86904070 (127.0.0.1) 14.750000ms referer=None 265s ---------------------------- Captured log teardown ----------------------------- 265s INFO NotebookApp:notebookapp.py:2164 Shutting down 1 kernel 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 105f4681-2fc7-4437-8e61-2e97fe7e7d7a 265s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 265s _______________________ AsyncSessionAPITest.test_create ________________________ 265s 265s @self.addCleanup 265s def cleanup_sessions(): 265s for session in self.sess_api.list().json(): 265s > self.sess_api.delete(session['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/76e30fc9-65fd-4fd3-a3ab-a1577b875572 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ------------------------------ Captured log setup ------------------------------ 265s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmpalhrix9x/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmpalhrix9x/etc/jupyter'] for config files 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpalhrix9x/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpalhrix9x/config 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpalhrix9x/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 265s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpalhrix9x/config 265s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmpalhrix9x/notebooks 265s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 265s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 265s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 265s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 265s WARNING NotebookApp:handlers.py:612 Forbidden 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s ------------------------------ Captured log call ------------------------------- 265s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 3.200000ms referer=None 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.190000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpalhrix9x/runtime/kernel-1b7ec116-00a7-4cfc-bcf2-143cf812b057.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:60631 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:59387 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: 1b7ec116-00a7-4cfc-bcf2-143cf812b057, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpalhrix9x/notebooks/foo'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 22.000000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.010000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions/76e30fc9-65fd-4fd3-a3ab-a1577b875572 (127.0.0.1) 1.000000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 5.940000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 1b7ec116-00a7-4cfc-bcf2-143cf812b057 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 1b7ec116-00a7-4cfc-bcf2-143cf812b057 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/76e30fc9-65fd-4fd3-a3ab-a1577b875572 (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/76e30fc9-65fd-4fd3-a3ab-a1577b875572', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 265s future.result() 265s ~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 265s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 265s raise km.ready.exception() # type: ignore[misc] 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/76e30fc9-65fd-4fd3-a3ab-a1577b875572 (127.0.0.1) 7.630000ms referer=None 265s --------------------------- Captured stderr teardown --------------------------- 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 265s from .connect import * # noqa: F403 265s ^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 9, in 265s from subprocess import PIPE, Popen 265s File "/usr/lib/python3.13/subprocess.py", line 51, in 265s import threading 265s File "", line 1360, in _find_and_load 265s File "", line 1331, in _find_and_load_unlocked 265s File "", line 935, in _load_unlocked 265s File "", line 1019, in exec_module 265s File "", line 1115, in get_code 265s File "", line 1215, in get_data 265s KeyboardInterrupt 265s _______________ AsyncSessionAPITest.test_create_console_session ________________ 265s 265s @self.addCleanup 265s def cleanup_sessions(): 265s for session in self.sess_api.list().json(): 265s > self.sess_api.delete(session['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/6709ed99-3f79-44a3-8c28-e99fd63bf49c 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpalhrix9x/runtime/kernel-f7cfc71b-f900-4bf8-a691-d4798051e8a4.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:54205 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:44871 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: f7cfc71b-f900-4bf8-a691-d4798051e8a4, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpalhrix9x/notebooks/foo'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 21.360000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.160000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 1b7ec116-00a7-4cfc-bcf2-143cf812b057 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 1b7ec116-00a7-4cfc-bcf2-143cf812b057 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/76e30fc9-65fd-4fd3-a3ab-a1577b875572 (127.0.0.1) 7.390000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for f7cfc71b-f900-4bf8-a691-d4798051e8a4 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: f7cfc71b-f900-4bf8-a691-d4798051e8a4 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/6709ed99-3f79-44a3-8c28-e99fd63bf49c (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/6709ed99-3f79-44a3-8c28-e99fd63bf49c', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 265s future.result() 265s ~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 265s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 265s raise km.ready.exception() # type: ignore[misc] 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/6709ed99-3f79-44a3-8c28-e99fd63bf49c (127.0.0.1) 16.130000ms referer=None 265s --------------------------- Captured stderr teardown --------------------------- 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 265s from pathlib import Path 265s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 265s from ._abc import * 265s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 265s from glob import _Globber, _no_recurse_symlinks 265s File "/usr/lib/python3.13/glob.py", line 5, in 265s import re 265s File "/usr/lib/python3.13/re/__init__.py", line 126, in 265s from . import _compiler, _parser 265s File "/usr/lib/python3.13/re/_compiler.py", line 13, in 265s import _sre 265s KeyboardInterrupt 265s __________________ AsyncSessionAPITest.test_create_deprecated __________________ 265s 265s @self.addCleanup 265s def cleanup_sessions(): 265s for session in self.sess_api.list().json(): 265s > self.sess_api.delete(session['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/cbcbd91d-d60d-48fc-9a02-001dafac9a7c 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 265s from pathlib import Path 265s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 265s from ._local import * 265s File "/usr/lib/python3.13/pathlib/_local.py", line 473, in 265s class PureWindowsPath(PurePath): 265s ...<7 lines>... 265s __slots__ = () 265s File "/usr/lib/python3.13/pathlib/_local.py", line 479, in PureWindowsPath 265s import ntpath 265s File "", line 1360, in _find_and_load 265s File "", line 1331, in _find_and_load_unlocked 265s File "", line 935, in _load_unlocked 265s File "", line 1019, in exec_module 265s File "", line 1152, in get_code 265s File "", line 781, in _compile_bytecode 265s KeyboardInterrupt 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s WARNING NotebookApp:handlers.py:46 Sessions API changed, see updated swagger docs 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpalhrix9x/runtime/kernel-ff16349e-1aae-4ce9-92da-a22af84e2dc2.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55043 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:43027 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: ff16349e-1aae-4ce9-92da-a22af84e2dc2, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpalhrix9x/notebooks/foo'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 20.350000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.170000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for f7cfc71b-f900-4bf8-a691-d4798051e8a4 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: f7cfc71b-f900-4bf8-a691-d4798051e8a4 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/6709ed99-3f79-44a3-8c28-e99fd63bf49c (127.0.0.1) 1.370000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ff16349e-1aae-4ce9-92da-a22af84e2dc2 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ff16349e-1aae-4ce9-92da-a22af84e2dc2 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/cbcbd91d-d60d-48fc-9a02-001dafac9a7c (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/cbcbd91d-d60d-48fc-9a02-001dafac9a7c', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 265s future.result() 265s ~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 265s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 265s raise km.ready.exception() # type: ignore[misc] 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/cbcbd91d-d60d-48fc-9a02-001dafac9a7c (127.0.0.1) 14.530000ms referer=None 265s _________________ AsyncSessionAPITest.test_create_file_session _________________ 265s 265s @self.addCleanup 265s def cleanup_sessions(): 265s for session in self.sess_api.list().json(): 265s > self.sess_api.delete(session['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/9877c12e-f190-497f-a0b6-c718a4aaac5b 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 265s from .connect import * # noqa: F403 265s ^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 7, in 265s import json 265s File "", line 1360, in _find_and_load 265s File "", line 1331, in _find_and_load_unlocked 265s File "", line 935, in _load_unlocked 265s File "", line 1019, in exec_module 265s File "", line 1152, in get_code 265s File "", line 781, in _compile_bytecode 265s KeyboardInterrupt 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpalhrix9x/runtime/kernel-472f6dc8-c4ef-4e3e-9f10-aeb57e1cab99.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:48869 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:59199 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: 472f6dc8-c4ef-4e3e-9f10-aeb57e1cab99, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpalhrix9x/notebooks/foo'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 22.520000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.250000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ff16349e-1aae-4ce9-92da-a22af84e2dc2 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ff16349e-1aae-4ce9-92da-a22af84e2dc2 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/cbcbd91d-d60d-48fc-9a02-001dafac9a7c (127.0.0.1) 1.420000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 472f6dc8-c4ef-4e3e-9f10-aeb57e1cab99 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 472f6dc8-c4ef-4e3e-9f10-aeb57e1cab99 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/9877c12e-f190-497f-a0b6-c718a4aaac5b (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/9877c12e-f190-497f-a0b6-c718a4aaac5b', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 265s future.result() 265s ~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 265s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 265s raise km.ready.exception() # type: ignore[misc] 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/9877c12e-f190-497f-a0b6-c718a4aaac5b (127.0.0.1) 14.070000ms referer=None 265s ________________ AsyncSessionAPITest.test_create_with_kernel_id ________________ 265s 265s self = 265s 265s def test_create_with_kernel_id(self): 265s # create a new kernel 265s r = self.request('POST', 'api/kernels') 265s r.raise_for_status() 265s kernel = r.json() 265s 265s resp = self.sess_api.create('foo/nb1.ipynb', kernel_id=kernel['id']) 265s self.assertEqual(resp.status_code, 201) 265s newsession = resp.json() 265s self.assertIn('id', newsession) 265s self.assertEqual(newsession['path'], 'foo/nb1.ipynb') 265s self.assertEqual(newsession['kernel']['id'], kernel['id']) 265s self.assertEqual(resp.headers['Location'], f'{self.url_prefix}api/sessions/{newsession["id"]}') 265s 265s sessions = self.sess_api.list().json() 265s > self.assertEqual(sessions, [newsession]) 265s E AssertionError: Lists differ: [{'id': '9877c12e-f190-497f-a0b6-c718a4aaac5b', 'p[553 chars]ne}}] != [{'id': '345c243f-8560-420b-857b-80d119edb15f', 'p[279 chars]ne}}] 265s E 265s E First differing element 0: 265s E {'id': '9877c12e-f190-497f-a0b6-c718a4aaac5b', 'p[218 chars]: 0}} 265s E {'id': '345c243f-8560-420b-857b-80d119edb15f', 'p[278 chars]one}} 265s E 265s E First list contains 1 additional elements. 265s E First extra element 1: 265s E {'id': '345c243f-8560-420b-857b-80d119edb15f', 'path': 'foo/nb1.ipynb', 'name': None, 'type': 'notebook', 'kernel': {'id': '1d6da3da-53c2-49a1-927c-f961055c2814', 'name': 'python3', 'last_activity': '2026-02-06T04:18:57.403920Z', 'execution_state': 'starting', 'connections': 0}, 'notebook': {'path': 'foo/nb1.ipynb', 'name': None}} 265s E 265s E Diff is 830 characters long. Set self.maxDiff to None to see it. 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:178: AssertionError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpalhrix9x/runtime/kernel-1d6da3da-53c2-49a1-927c-f961055c2814.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:48395 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:59339 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: 1d6da3da-53c2-49a1-927c-f961055c2814, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.800000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.170000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.260000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.170000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 472f6dc8-c4ef-4e3e-9f10-aeb57e1cab99 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 472f6dc8-c4ef-4e3e-9f10-aeb57e1cab99 265s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/9877c12e-f190-497f-a0b6-c718a4aaac5b (127.0.0.1) 1.390000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 1d6da3da-53c2-49a1-927c-f961055c2814 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 1d6da3da-53c2-49a1-927c-f961055c2814 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/345c243f-8560-420b-857b-80d119edb15f (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/345c243f-8560-420b-857b-80d119edb15f', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 265s future.result() 265s ~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 265s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 265s raise km.ready.exception() # type: ignore[misc] 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/345c243f-8560-420b-857b-80d119edb15f (127.0.0.1) 8.090000ms referer=None 265s __________________ AsyncSessionAPITest.test_modify_kernel_id ___________________ 265s 265s @self.addCleanup 265s def cleanup_sessions(): 265s for session in self.sess_api.list().json(): 265s > self.sess_api.delete(session['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/345c243f-8560-420b-857b-80d119edb15f 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 1, in 265s from ._version import ( 265s ...<4 lines>... 265s ) 265s File "", line 1360, in _find_and_load 265s File "", line 1331, in _find_and_load_unlocked 265s File "", line 935, in _load_unlocked 265s File "", line 1019, in exec_module 265s File "", line 1115, in get_code 265s File "", line 1214, in get_data 265s KeyboardInterrupt 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.290000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpalhrix9x/runtime/kernel-c29b21c4-938d-4ff4-83fa-ae35e986dbf4.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:49543 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:42217 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: c29b21c4-938d-4ff4-83fa-ae35e986dbf4, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.490000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 1d6da3da-53c2-49a1-927c-f961055c2814 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 1d6da3da-53c2-49a1-927c-f961055c2814 265s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/345c243f-8560-420b-857b-80d119edb15f (127.0.0.1) 1.620000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 3.330000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.040000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for c29b21c4-938d-4ff4-83fa-ae35e986dbf4 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c29b21c4-938d-4ff4-83fa-ae35e986dbf4 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/345c243f-8560-420b-857b-80d119edb15f (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/345c243f-8560-420b-857b-80d119edb15f', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 265s future.result() 265s ~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 265s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 265s raise km.ready.exception() # type: ignore[misc] 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/345c243f-8560-420b-857b-80d119edb15f (127.0.0.1) 14.100000ms referer=None 265s _________________ AsyncSessionAPITest.test_modify_kernel_name __________________ 265s 265s @self.addCleanup 265s def cleanup_sessions(): 265s for session in self.sess_api.list().json(): 265s > self.sess_api.delete(session['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/345c243f-8560-420b-857b-80d119edb15f 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.250000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpalhrix9x/runtime/kernel-a7d33bdd-f07a-459c-b9cc-e50eaafb984c.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:52447 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:50425 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: a7d33bdd-f07a-459c-b9cc-e50eaafb984c, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3', 'cwd': '/tmp/tmpalhrix9x/notebooks/foo'} 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for c29b21c4-938d-4ff4-83fa-ae35e986dbf4 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c29b21c4-938d-4ff4-83fa-ae35e986dbf4 265s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/345c243f-8560-420b-857b-80d119edb15f (127.0.0.1) 20.340000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.000000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.060000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for a7d33bdd-f07a-459c-b9cc-e50eaafb984c 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a7d33bdd-f07a-459c-b9cc-e50eaafb984c 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/345c243f-8560-420b-857b-80d119edb15f (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/345c243f-8560-420b-857b-80d119edb15f', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 265s future.result() 265s ~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 265s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 265s raise km.ready.exception() # type: ignore[misc] 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/345c243f-8560-420b-857b-80d119edb15f (127.0.0.1) 13.240000ms referer=None 265s --------------------------- Captured stderr teardown --------------------------- 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 265s from .connect import * # noqa: F403 265s ^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 7, in 265s import json 265s File "/usr/lib/python3.13/json/__init__.py", line 106, in 265s from .decoder import JSONDecoder, JSONDecodeError 265s File "/usr/lib/python3.13/json/decoder.py", line 5, in 265s from json import scanner 265s File "/usr/lib/python3.13/json/scanner.py", line 11, in 265s NUMBER_RE = re.compile( 265s r'(-?(?:0|[1-9][0-9]*))(\.[0-9]+)?([eE][-+]?[0-9]+)?', 265s (re.VERBOSE | re.MULTILINE | re.DOTALL)) 265s File "/usr/lib/python3.13/re/__init__.py", line 289, in compile 265s return _compile(pattern, flags) 265s File "/usr/lib/python3.13/re/__init__.py", line 350, in _compile 265s p = _compiler.compile(pattern, flags) 265s File "/usr/lib/python3.13/re/_compiler.py", line 748, in compile 265s p = _parser.parse(p, flags) 265s File "/usr/lib/python3.13/re/_parser.py", line 980, in parse 265s p = _parse_sub(source, state, flags & SRE_FLAG_VERBOSE, 0) 265s File "/usr/lib/python3.13/re/_parser.py", line 459, in _parse_sub 265s itemsappend(_parse(source, state, verbose, nested + 1, 265s ~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s not nested and not items)) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3.13/re/_parser.py", line 513, in _parse 265s subpattern = SubPattern(state) 265s File "/usr/lib/python3.13/re/_parser.py", line 112, in __init__ 265s def __init__(self, state, data=None): 265s 265s KeyboardInterrupt 265s _____________________ AsyncSessionAPITest.test_modify_type _____________________ 265s 265s @self.addCleanup 265s def cleanup_sessions(): 265s for session in self.sess_api.list().json(): 265s > self.sess_api.delete(session['id']) 265s 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 265s return self._req('DELETE', id) 265s ^^^^^^^^^^^^^^^^^^^^^^^ 265s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 265s response.raise_for_status() 265s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 265s 265s self = 265s 265s def raise_for_status(self): 265s """Raises :class:`HTTPError`, if one occurred.""" 265s 265s http_error_msg = "" 265s if isinstance(self.reason, bytes): 265s # We attempt to decode utf-8 first because some servers 265s # choose to localize their reason strings. If the string 265s # isn't utf-8, we fall back to iso-8859-1 for all other 265s # encodings. (See PR #3538) 265s try: 265s reason = self.reason.decode("utf-8") 265s except UnicodeDecodeError: 265s reason = self.reason.decode("iso-8859-1") 265s else: 265s reason = self.reason 265s 265s if 400 <= self.status_code < 500: 265s http_error_msg = ( 265s f"{self.status_code} Client Error: {reason} for url: {self.url}" 265s ) 265s 265s elif 500 <= self.status_code < 600: 265s http_error_msg = ( 265s f"{self.status_code} Server Error: {reason} for url: {self.url}" 265s ) 265s 265s if http_error_msg: 265s > raise HTTPError(http_error_msg, response=self) 265s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/d6b34e35-61f9-4eaf-a934-917a00dd4899 265s 265s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 265s ----------------------------- Captured stderr call ----------------------------- 265s Traceback (most recent call last): 265s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 265s return _run_code(code, main_globals, None, 265s "__main__", mod_spec) 265s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 265s exec(code, run_globals) 265s ~~~~^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 265s from ipykernel import kernelapp as app 265s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 265s from .connect import * # noqa: F403 265s ^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 9, in 265s from subprocess import PIPE, Popen 265s File "", line 1360, in _find_and_load 265s File "", line 1331, in _find_and_load_unlocked 265s File "", line 935, in _load_unlocked 265s File "", line 1019, in exec_module 265s File "", line 1152, in get_code 265s File "", line 781, in _compile_bytecode 265s KeyboardInterrupt 265s ------------------------------ Captured log call ------------------------------- 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 265s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpalhrix9x/runtime/kernel-a462348b-963b-45c5-b5fd-4c6cc0a143ec.json'] 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:50665 265s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:58987 265s INFO NotebookApp:kernelmanager.py:179 Kernel started: a462348b-963b-45c5-b5fd-4c6cc0a143ec, name: python3 265s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpalhrix9x/notebooks/foo'} 265s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 20.690000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/d6b34e35-61f9-4eaf-a934-917a00dd4899 (127.0.0.1) 1.620000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.030000ms 265s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 265s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for a462348b-963b-45c5-b5fd-4c6cc0a143ec 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a462348b-963b-45c5-b5fd-4c6cc0a143ec 265s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/d6b34e35-61f9-4eaf-a934-917a00dd4899 (127.0.0.1) 265s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/d6b34e35-61f9-4eaf-a934-917a00dd4899', version='HTTP/1.1', remote_ip='127.0.0.1') 265s Traceback (most recent call last): 265s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 265s result = await result 265s ^^^^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 265s future.result() 265s ~~~~~~~~~~~~~^^ 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 265s yield maybe_future(sm.delete_session(session_id)) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 265s yielded = self.gen.throw(exc) 265s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 265s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 265s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 265s value = future.result() 265s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 265s raise self._exception.with_traceback(self._exception_tb) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 265s result = coro.send(None) 265s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 265s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 265s raise km.ready.exception() # type: ignore[misc] 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 265s await kernel_awaitable 265s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 265s result = await obj 265s ^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 265s raise e 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 265s out = await method(self, *args, **kwargs) 265s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 265s await self._async_finish_shutdown(restart=restart) 265s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 265s await asyncio.wait_for( 265s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 265s ) 265s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 265s async with timeouts.timeout(timeout): 265s ~~~~~~~~~~~~~~~~^^^^^^^^^ 265s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 265s raise RuntimeError("Timeout should be used inside a task") 265s RuntimeError: Timeout should be used inside a task 265s WARNING NotebookApp:handlers.py:612 Unhandled error 265s ERROR NotebookApp:log.py:55 { 265s "Host": "localhost:12341", 265s "Accept": "*/*", 265s "User-Agent": "python-requests/2.32.5" 265s } 265s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/d6b34e35-61f9-4eaf-a934-917a00dd4899 (127.0.0.1) 14.140000ms referer=None 265s ---------------------------- Captured log teardown ----------------------------- 265s INFO NotebookApp:notebookapp.py:2164 Shutting down 1 kernel 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c29b21c4-938d-4ff4-83fa-ae35e986dbf4 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 1b7ec116-00a7-4cfc-bcf2-143cf812b057 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 472f6dc8-c4ef-4e3e-9f10-aeb57e1cab99 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ff16349e-1aae-4ce9-92da-a22af84e2dc2 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: f7cfc71b-f900-4bf8-a691-d4798051e8a4 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a7d33bdd-f07a-459c-b9cc-e50eaafb984c 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a462348b-963b-45c5-b5fd-4c6cc0a143ec 265s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 1d6da3da-53c2-49a1-927c-f961055c2814 265s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 265s =============================== warnings summary =============================== 265s ../../../usr/lib/python3/dist-packages/notebook/utils.py:280 265s ../../../usr/lib/python3/dist-packages/notebook/utils.py:280 265s /usr/lib/python3/dist-packages/notebook/utils.py:280: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead. 265s return LooseVersion(v) >= LooseVersion(check) 265s 265s ../../../usr/lib/python3/dist-packages/notebook/_tz.py:29: 1 warning 265s services/kernels/tests/test_kernels_api.py: 72 warnings 265s services/sessions/tests/test_sessions_api.py: 106 warnings 265s /usr/lib/python3/dist-packages/notebook/_tz.py:29: DeprecationWarning: datetime.datetime.utcnow() is deprecated and scheduled for removal in a future version. Use timezone-aware objects to represent datetimes in UTC: datetime.datetime.now(datetime.UTC). 265s dt = unaware(*args, **kwargs) 265s 265s ../../../usr/lib/python3/dist-packages/notebook/tests/test_notebookapp_integration.py:14 265s /usr/lib/python3/dist-packages/notebook/tests/test_notebookapp_integration.py:14: PytestUnknownMarkWarning: Unknown pytest.mark.integration_tests - is this a typo? You can register custom marks to avoid this warning - for details, see https://docs.pytest.org/en/stable/how-to/mark.html 265s pytestmark = pytest.mark.integration_tests 265s 265s services/kernels/tests/test_kernels_api.py: 6 warnings 265s services/sessions/tests/test_sessions_api.py: 6 warnings 265s /usr/lib/python3/dist-packages/nest_asyncio.py:71: DeprecationWarning: 'asyncio.get_event_loop_policy' is deprecated and slated for removal in Python 3.16 265s policy = events.get_event_loop_policy() 265s 265s services/kernels/tests/test_kernels_api.py: 22 warnings 265s services/sessions/tests/test_sessions_api.py: 17 warnings 265s /usr/lib/python3/dist-packages/nest_asyncio.py:40: DeprecationWarning: 'asyncio.get_event_loop_policy' is deprecated and slated for removal in Python 3.16 265s loop = events.get_event_loop_policy().get_event_loop() 265s 265s services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_connections 265s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:67: DeprecationWarning: make_current is deprecated; start the event loop first 265s loop.make_current() 265s 265s -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html 265s =========================== short test summary info ============================ 265s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_default_kernel 265s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_kernel_handler 265s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_main_kernel_handler 265s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_no_kernels 265s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_connections 265s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_default_kernel 265s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_kernel_handler 265s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_main_kernel_handler 265s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_no_kernels 265s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create 265s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_console_session 265s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_deprecated 265s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_file_session 265s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_with_kernel_id 265s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_modify_kernel_id 265s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_modify_kernel_name 265s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_modify_type 265s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create 265s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_console_session 265s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_deprecated 265s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_file_session 265s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_with_kernel_id 265s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_modify_kernel_id 265s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_modify_kernel_name 265s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_modify_type 265s ERROR services/kernels/tests/test_kernels_api.py::KernelAPITest::test_main_kernel_handler 265s ERROR services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_main_kernel_handler 265s ERROR services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_with_kernel_id 265s ERROR services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_with_kernel_id 265s ===== 25 failed, 2 passed, 303 deselected, 234 warnings, 4 errors in 7.46s ===== 265s *** END OF RUN 2: NOT ALL TESTS HAVE YET PASSED/XFAILED *** 265s *** STARTING RUN 3: python3.14 -m pytest --pyargs notebook -rfE --last-failed --last-failed-no-failures none --ignore=/usr/lib/python3/dist-packages/notebook/tests/selenium --deselect=services/kernels/tests/test_kernels_api.py::KernelAPITest::test_connections 269s ============================= test session starts ============================== 269s platform linux -- Python 3.14.2, pytest-9.0.2, pluggy-1.6.0 269s rootdir: /tmp/autopkgtest.d1RsUl/autopkgtest_tmp 269s plugins: typeguard-4.4.4 269s collected 330 items / 305 deselected / 25 selected 269s run-last-failure: rerun previous 25 failures 269s 271s services/kernels/tests/test_kernels_api.py FFFEFFFFFEF [ 36%] 273s services/sessions/tests/test_sessions_api.py FFFFFEFF.FFFFFEFF. [100%] 273s 273s ==================================== ERRORS ==================================== 273s _________ ERROR at teardown of KernelAPITest.test_main_kernel_handler __________ 273s 273s self = 273s 273s def tearDown(self): 273s for k in self.kern_api.list().json(): 273s > self.kern_api.shutdown(k['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ----------------------------- Captured stderr call ----------------------------- 273s Traceback (most recent call last): 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 273s from pathlib import Path 273s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 273s from ._abc import * 273s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 273s from glob import _Globber, _no_recurse_symlinks 273s File "/usr/lib/python3.13/glob.py", line 5, in 273s import re 273s File "/usr/lib/python3.13/re/__init__.py", line 126, in 273s from . import _compiler, _parser 273s File "", line 1360, in _find_and_load 273s File "", line 1331, in _find_and_load_unlocked 273s File "", line 935, in _load_unlocked 273s File "", line 1019, in exec_module 273s File "", line 1109, in get_code 273s File "", line 1232, in path_stats 273s File "", line 152, in _path_stat 273s KeyboardInterrupt 273s Traceback (most recent call last): 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 273s from ipykernel import kernelapp as app 273s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 273s from .connect import * # noqa: F403 273s ^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 12, in 273s import jupyter_client 273s File "/usr/lib/python3/dist-packages/jupyter_client/__init__.py", line 4, in 273s from .asynchronous import AsyncKernelClient 273s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/__init__.py", line 1, in 273s from .client import AsyncKernelClient # noqa 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/client.py", line 9, in 273s import zmq.asyncio 273s File "/usr/lib/python3/dist-packages/zmq/asyncio.py", line 10, in 273s import asyncio 273s File "/usr/lib/python3.13/asyncio/__init__.py", line 8, in 273s from .base_events import * 273s File "/usr/lib/python3.13/asyncio/base_events.py", line 34, in 273s import ssl 273s File "/usr/lib/python3.13/ssl.py", line 100, in 273s import _ssl # if we can't import it, let the error propagate 273s ^^^^^^^^^^^ 273s File "", line 1360, in _find_and_load 273s File "", line 1322, in _find_and_load_unlocked 273s File "", line 1256, in _find_spec 273s File "", line 1226, in __exit__ 273s KeyboardInterrupt 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpz38mvfpl/runtime/kernel-ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:43793 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:41701 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 19.310000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 2.770000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpz38mvfpl/runtime/kernel-b3bc1cd8-438d-4cc6-a13e-6865c86c8b8b.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:44937 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:40203 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: b3bc1cd8-438d-4cc6-a13e-6865c86c8b8b, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 23.500000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.070000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: b3bc1cd8-438d-4cc6-a13e-6865c86c8b8b 273s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/b3bc1cd8-438d-4cc6-a13e-6865c86c8b8b/interrupt (127.0.0.1) 2.160000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 273s yield maybe_future(km.restart_kernel(kernel_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 273s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 273s await ensure_async(kernel.restart_kernel(now=now)) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 273s await self._async_shutdown_kernel(now=now, restart=True) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/b3bc1cd8-438d-4cc6-a13e-6865c86c8b8b/restart (127.0.0.1) 10.410000ms referer=None 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.030000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 273s yielded = ctx_run(next, result) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 273s yield maybe_future(km.shutdown_kernel(kernel_id)) 273s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 273s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 273s stopper = ensure_async(km.shutdown_kernel(now, restart)) 273s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d (127.0.0.1) 9.700000ms referer=None 273s _______ ERROR at teardown of AsyncKernelAPITest.test_main_kernel_handler _______ 273s 273s self = 273s 273s def tearDown(self): 273s for k in self.kern_api.list().json(): 273s > self.kern_api.shutdown(k['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/fa8e51ed-6907-4e5b-8e69-7e6b0a63d977 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ----------------------------- Captured stderr call ----------------------------- 273s Traceback (most recent call last): 273s Traceback (most recent call last): 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 273s from ipykernel import kernelapp as app 273s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 273s from .connect import * # noqa: F403 273s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 7, in 273s import json 273s File "/usr/lib/python3.13/json/__init__.py", line 107, in 273s from .encoder import JSONEncoder 273s File "", line 1360, in _find_and_load 273s File "", line 1322, in _find_and_load_unlocked 273s File "", line 1262, in _find_spec 273s File "", line 1556, in find_spec 273s File "", line 1530, in _get_spec 273s File "", line 1629, in find_spec 273s File "", line 152, in _path_stat 273s KeyboardInterrupt 273s Traceback (most recent call last): 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 273s from ipykernel import kernelapp as app 273s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 273s from .connect import * # noqa: F403 273s ^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 12, in 273s import jupyter_client 273s File "/usr/lib/python3/dist-packages/jupyter_client/__init__.py", line 4, in 273s from .asynchronous import AsyncKernelClient 273s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/__init__.py", line 1, in 273s from .client import AsyncKernelClient # noqa 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/client.py", line 9, in 273s import zmq.asyncio 273s File "/usr/lib/python3/dist-packages/zmq/asyncio.py", line 10, in 273s import asyncio 273s File "/usr/lib/python3.13/asyncio/__init__.py", line 8, in 273s from .base_events import * 273s File "/usr/lib/python3.13/asyncio/base_events.py", line 45, in 273s from . import staggered 273s File "/usr/lib/python3.13/asyncio/staggered.py", line 9, in 273s from . import locks 273s File "/usr/lib/python3.13/asyncio/locks.py", line 219, in 273s class Condition(_ContextManagerMixin, mixins._LoopBoundMixin): 273s ...<129 lines>... 273s self.notify(len(self._waiters)) 273s KeyboardInterrupt 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpqiz872bu/runtime/kernel-fa8e51ed-6907-4e5b-8e69-7e6b0a63d977.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:58267 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:46367 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: fa8e51ed-6907-4e5b-8e69-7e6b0a63d977, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 23.540000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 2.360000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpqiz872bu/runtime/kernel-e3918275-4b65-4353-8edd-15e506d0c040.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:60897 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34347 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: e3918275-4b65-4353-8edd-15e506d0c040, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 24.520000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 2.410000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: e3918275-4b65-4353-8edd-15e506d0c040 273s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/e3918275-4b65-4353-8edd-15e506d0c040/interrupt (127.0.0.1) 3.820000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 273s yield maybe_future(km.restart_kernel(kernel_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 291, in __step_run_and_handle_result 273s result = coro.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 273s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 273s File "/usr/lib/python3.14/asyncio/futures.py", line 295, in __await__ 273s yield self # This tells Task to wait for completion. 273s ^^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 273s future.result() 273s ~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 273s await ensure_async(kernel.restart_kernel(now=now)) 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 273s await self._async_shutdown_kernel(now=now, restart=True) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/e3918275-4b65-4353-8edd-15e506d0c040/restart (127.0.0.1) 8.190000ms referer=None 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 2.530000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for fa8e51ed-6907-4e5b-8e69-7e6b0a63d977 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: fa8e51ed-6907-4e5b-8e69-7e6b0a63d977 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/fa8e51ed-6907-4e5b-8e69-7e6b0a63d977 (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/fa8e51ed-6907-4e5b-8e69-7e6b0a63d977', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 273s future.result() 273s ~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 273s yield maybe_future(km.shutdown_kernel(kernel_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 273s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 273s raise km.ready.exception() # type: ignore[misc] 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/fa8e51ed-6907-4e5b-8e69-7e6b0a63d977 (127.0.0.1) 12.850000ms referer=None 273s ________ ERROR at teardown of SessionAPITest.test_create_with_kernel_id ________ 273s 273s @self.addCleanup 273s def cleanup_sessions(): 273s for session in self.sess_api.list().json(): 273s > self.sess_api.delete(session['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req/usr/lib/python3/dist-packages/_pytest/unraisableexception.py:33: RuntimeWarning: coroutine 'KernelManager._async_wait' was never awaited 273s gc.collect() 273s RuntimeWarning: Enable tracemalloc to get the object allocation traceback 273s 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/1d45022e-0df2-4610-9eed-05984c43104f 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpfpu_0lxf/runtime/kernel-030cb0a4-a91d-48df-a635-550401b6b1a7.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:41049 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:51025 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: 030cb0a4-a91d-48df-a635-550401b6b1a7, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 24.190000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.230000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.070000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.050000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 4af97127-5448-41d3-bb9f-c899b8566d5e 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 4af97127-5448-41d3-bb9f-c899b8566d5e 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/a8d8817c-4465-44d3-9d4f-ad14df5dcda5 (127.0.0.1) 1.590000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 030cb0a4-a91d-48df-a635-550401b6b1a7 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 030cb0a4-a91d-48df-a635-550401b6b1a7 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/1d45022e-0df2-4610-9eed-05984c43104f (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/1d45022e-0df2-4610-9eed-05984c43104f', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 273s yield maybe_future(sm.delete_session(session_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 273s yielded = self.gen.send(value) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 273s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 273s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 273s stopper = ensure_async(km.shutdown_kernel(now, restart)) 273s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/1d45022e-0df2-4610-9eed-05984c43104f (127.0.0.1) 11.410000ms referer=None 273s _____ ERROR at teardown of AsyncSessionAPITest.test_create_with_kernel_id ______ 273s 273s @self.addCleanup 273s def cleanup_sessions(): 273s for session in self.sess_api.list().json(): 273s > self.sess_api.delete(session['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/293a9aa4-d69e-4bd7-984b-4b19cf7f029c 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcbffyxzf/runtime/kernel-14446634-41cd-41a0-944f-ce1dcd4b30c8.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:38749 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:45985 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: 14446634-41cd-41a0-944f-ce1dcd4b30c8, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 17.860000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.240000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.190000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.220000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 7f066f0d-dd95-49d0-87a7-fa14c4fb6da5 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 7f066f0d-dd95-49d0-87a7-fa14c4fb6da5 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/48358f51-2240-49e1-a576-dff51a65cc6c (127.0.0.1) 1.870000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 14446634-41cd-41a0-944f-ce1dcd4b30c8 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 14446634-41cd-41a0-944f-ce1dcd4b30c8 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/293a9aa4-d69e-4bd7-984b-4b19cf7f029c (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/293a9aa4-d69e-4bd7-984b-4b19cf7f029c', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 273s future.result() 273s ~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 273s yield maybe_future(sm.delete_session(session_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 273s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 273s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 273s raise km.ready.exception() # type: ignore[misc] 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/293a9aa4-d69e-4bd7-984b-4b19cf7f029c (127.0.0.1) 8.480000ms referer=None 273s =================================== FAILURES =================================== 273s ______________________ KernelAPITest.test_default_kernel _______________________ 273s 273s self = 273s 273s def tearDown(self): 273s for k in self.kern_api.list().json(): 273s > self.kern_api.shutdown(k['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/129137a3-e20d-4698-853c-4a53f7cce926 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ------------------------------ Captured log setup ------------------------------ 273s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmpz38mvfpl/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmpz38mvfpl/etc/jupyter'] for config files 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpz38mvfpl/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpz38mvfpl/config 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpz38mvfpl/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpz38mvfpl/config 273s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmpz38mvfpl/notebooks 273s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 273s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 273s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 273s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 273s WARNING NotebookApp:handlers.py:612 Forbidden 273s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 1.340000ms referer=None 273s ----------------------------- Captured stderr call ----------------------------- 273s Could not import runpy module 273s Traceback (most recent call last): 273s File "/usr/lib/python3.13/runpy.py", line 15, in 273s import importlib.util 273s File "", line 1360, in _find_and_load 273s File "", line 1331, in _find_and_load_unlocked 273s File "", line 935, in _load_unlocked 273s File "", line 1019, in exec_module 273s File "", line 1115, in get_code 273s File "", line 1215, in get_data 273s KeyboardInterrupt 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpz38mvfpl/runtime/kernel-129137a3-e20d-4698-853c-4a53f7cce926.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:45281 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:39845 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: 129137a3-e20d-4698-853c-4a53f7cce926, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 78.310000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.500000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 129137a3-e20d-4698-853c-4a53f7cce926 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 129137a3-e20d-4698-853c-4a53f7cce926 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/129137a3-e20d-4698-853c-4a53f7cce926 (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/129137a3-e20d-4698-853c-4a53f7cce926', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 273s yielded = ctx_run(next, result) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 273s yield maybe_future(km.shutdown_kernel(kernel_id)) 273s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 273s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 273s stopper = ensure_async(km.shutdown_kernel(now, restart)) 273s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/129137a3-e20d-4698-853c-4a53f7cce926 (127.0.0.1) 16.570000ms referer=None 273s ______________________ KernelAPITest.test_kernel_handler _______________________ 273s 273s self = 273s 273s def test_kernel_handler(self): 273s # GET kernel with given id 273s kid = self.kern_api.start().json()['id'] 273s r = self.kern_api.get(kid) 273s kern1 = r.json() 273s self.assertEqual(r.status_code, 200) 273s assert isinstance(kern1, dict) 273s self.assertIn('id', kern1) 273s self.assertEqual(kern1['id'], kid) 273s 273s # Request a bad kernel id and check that a JSON 273s # message is returned! 273s bad_id = '111-111-111-111-111' 273s with assert_http_error(404, 'Kernel does not exist: ' + bad_id): 273s self.kern_api.get(bad_id) 273s 273s # DELETE kernel with id 273s > r = self.kern_api.shutdown(kid) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:169: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/72ebb88b-c0c2-4b01-bf06-8bad7435c296 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ----------------------------- Captured stderr call ----------------------------- 273s Traceback (most recent call last): 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 273s from ipykernel import kernelapp as app 273s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 273s from .connect import * # noqa: F403 273s ^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 7, in 273s import json 273s File "/usr/lib/python3.13/json/__init__.py", line 107, in 273s from .encoder import JSONEncoder 273s File "", line 1357, in _find_and_load 273s File "", line 421, in __exit__ 273s File "", line 378, in release 273s KeyboardInterrupt 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpz38mvfpl/runtime/kernel-72ebb88b-c0c2-4b01-bf06-8bad7435c296.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:53985 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:47237 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: 72ebb88b-c0c2-4b01-bf06-8bad7435c296, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 23.060000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/72ebb88b-c0c2-4b01-bf06-8bad7435c296 (127.0.0.1) 1.170000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s WARNING NotebookApp:web.py:1943 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1): Kernel does not exist: 111-111-111-111-111 273s WARNING NotebookApp:handlers.py:612 Kernel does not exist: 111-111-111-111-111 273s WARNING NotebookApp:log.py:59 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1) 2.050000ms referer=None 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 72ebb88b-c0c2-4b01-bf06-8bad7435c296 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 72ebb88b-c0c2-4b01-bf06-8bad7435c296 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/72ebb88b-c0c2-4b01-bf06-8bad7435c296 (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/72ebb88b-c0c2-4b01-bf06-8bad7435c296', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 273s yielded = ctx_run(next, result) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 273s yield maybe_future(km.shutdown_kernel(kernel_id)) 273s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 273s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 273s stopper = ensure_async(km.shutdown_kernel(now, restart)) 273s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/72ebb88b-c0c2-4b01-bf06-8bad7435c296 (127.0.0.1) 12.690000ms referer=None 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.960000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 129137a3-e20d-4698-853c-4a53f7cce926 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 129137a3-e20d-4698-853c-4a53f7cce926 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/129137a3-e20d-4698-853c-4a53f7cce926 (127.0.0.1) 1.710000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 72ebb88b-c0c2-4b01-bf06-8bad7435c296 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 72ebb88b-c0c2-4b01-bf06-8bad7435c296 273s ____________________ KernelAPITest.test_main_kernel_handler ____________________ 273s 273s self = 273s 273s def test_main_kernel_handler(self): 273s # POST request 273s r = self.kern_api.start() 273s kern1 = r.json() 273s self.assertEqual(r.headers['location'], url_path_join(self.url_prefix, 'api/kernels', kern1['id'])) 273s self.assertEqual(r.status_code, 201) 273s self.assertIsInstance(kern1, dict) 273s 273s report_uri = url_path_join(self.url_prefix, 'api/security/csp-report') 273s expected_csp = '; '.join([ 273s "frame-ancestors 'self'", 273s 'report-uri ' + report_uri, 273s "default-src 'none'" 273s ]) 273s self.assertEqual(r.headers['Content-Security-Policy'], expected_csp) 273s 273s # GET request 273s r = self.kern_api.list() 273s self.assertEqual(r.status_code, 200) 273s assert isinstance(r.json(), list) 273s self.assertEqual(r.json()[0]['id'], kern1['id']) 273s self.assertEqual(r.json()[0]['name'], kern1['name']) 273s 273s # create another kernel and check that they both are added to the 273s # list of kernels from a GET request 273s kern2 = self.kern_api.start().json() 273s assert isinstance(kern2, dict) 273s r = self.kern_api.list() 273s kernels = r.json() 273s self.assertEqual(r.status_code, 200) 273s assert isinstance(kernels, list) 273s self.assertEqual(len(kernels), 2) 273s 273s # Interrupt a kernel 273s r = self.kern_api.interrupt(kern2['id']) 273s self.assertEqual(r.status_code, 204) 273s 273s # Restart a kernel 273s > r = self.kern_api.restart(kern2['id']) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:147: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:63: in restart 273s return self._req('POST', url_path_join(id, 'restart')) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: http://localhost:12341/a%40b/api/kernels/b3bc1cd8-438d-4cc6-a13e-6865c86c8b8b/restart 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ----------------------------- Captured stderr call ----------------------------- 273s Traceback (most recent call last): 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 273s from pathlib import Path 273s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 273s from ._abc import * 273s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 273s from glob import _Globber, _no_recurse_symlinks 273s File "/usr/lib/python3.13/glob.py", line 5, in 273s import re 273s File "/usr/lib/python3.13/re/__init__.py", line 126, in 273s from . import _compiler, _parser 273s File "", line 1360, in _find_and_load 273s File "", line 1331, in _find_and_load_unlocked 273s File "", line 935, in _load_unlocked 273s File "", line 1019, in exec_module 273s File "", line 1109, in get_code 273s File "", line 1232, in path_stats 273s File "", line 152, in _path_stat 273s KeyboardInterrupt 273s Traceback (most recent call last): 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 273s from ipykernel import kernelapp as app 273s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 273s from .connect import * # noqa: F403 273s ^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 12, in 273s import jupyter_client 273s File "/usr/lib/python3/dist-packages/jupyter_client/__init__.py", line 4, in 273s from .asynchronous import AsyncKernelClient 273s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/__init__.py", line 1, in 273s from .client import AsyncKernelClient # noqa 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/client.py", line 9, in 273s import zmq.asyncio 273s File "/usr/lib/python3/dist-packages/zmq/asyncio.py", line 10, in 273s import asyncio 273s File "/usr/lib/python3.13/asyncio/__init__.py", line 8, in 273s from .base_events import * 273s File "/usr/lib/python3.13/asyncio/base_events.py", line 34, in 273s import ssl 273s File "/usr/lib/python3.13/ssl.py", line 100, in 273s import _ssl # if we can't import it, let the error propagate 273s ^^^^^^^^^^^ 273s File "", line 1360, in _find_and_load 273s File "", line 1322, in _find_and_load_unlocked 273s File "", line 1256, in _find_spec 273s File "", line 1226, in __exit__ 273s KeyboardInterrupt 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpz38mvfpl/runtime/kernel-ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:43793 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:41701 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 19.310000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 2.770000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpz38mvfpl/runtime/kernel-b3bc1cd8-438d-4cc6-a13e-6865c86c8b8b.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:44937 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:40203 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: b3bc1cd8-438d-4cc6-a13e-6865c86c8b8b, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 23.500000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.070000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: b3bc1cd8-438d-4cc6-a13e-6865c86c8b8b 273s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/b3bc1cd8-438d-4cc6-a13e-6865c86c8b8b/interrupt (127.0.0.1) 2.160000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 273s yield maybe_future(km.restart_kernel(kernel_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 273s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 273s await ensure_async(kernel.restart_kernel(now=now)) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 273s await self._async_shutdown_kernel(now=now, restart=True) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/b3bc1cd8-438d-4cc6-a13e-6865c86c8b8b/restart (127.0.0.1) 10.410000ms referer=None 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.030000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 273s yielded = ctx_run(next, result) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 273s yield maybe_future(km.shutdown_kernel(kernel_id)) 273s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 273s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 273s stopper = ensure_async(km.shutdown_kernel(now, restart)) 273s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d (127.0.0.1) 9.700000ms referer=None 273s ________________________ KernelAPITest.test_no_kernels _________________________ 273s 273s self = 273s 273s def test_no_kernels(self): 273s """Make sure there are no kernels running at the start""" 273s kernels = self.kern_api.list().json() 273s > self.assertEqual(kernels, []) 273s E AssertionError: Lists differ: [{'id': 'ee4f67b0-2b9a-4a71-bf02-af8292cc2[281 chars]: 0}] != [] 273s E 273s E First list contains 2 additional elements. 273s E First extra element 0: 273s E {'id': 'ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d', 'name': 'python3', 'last_activity': '2026-02-06T04:19:03.418418Z', 'execution_state': 'starting', 'connections': 0} 273s E 273s E + [] 273s E - [{'connections': 0, 273s E - 'execution_state': 'starting', 273s E - 'id': 'ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d', 273s E - 'last_activity': '2026-02-06T04:19:03.418418Z', 273s E - 'name': 'python3'}, 273s E - {'connections': 0, 273s E - 'execution_state': 'starting', 273s E - 'id': 'b3bc1cd8-438d-4cc6-a13e-6865c86c8b8b', 273s E - 'last_activity': '2026-02-06T04:19:03.448172Z', 273s E - 'name': 'python3'}] 273s 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:91: AssertionError 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 3.660000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.950000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/ee4f67b0-2b9a-4a71-bf02-af8292cc2e4d (127.0.0.1) 1.450000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for b3bc1cd8-438d-4cc6-a13e-6865c86c8b8b 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: b3bc1cd8-438d-4cc6-a13e-6865c86c8b8b 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/b3bc1cd8-438d-4cc6-a13e-6865c86c8b8b (127.0.0.1) 1.500000ms 273s ---------------------------- Captured log teardown ----------------------------- 273s INFO NotebookApp:notebookapp.py:2164 Shutting down 0 kernels 273s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 273s _____________________ AsyncKernelAPITest.test_connections ______________________ 273s 273s self = 273s 273s def tearDown(self): 273s for k in self.kern_api.list().json(): 273s > self.kern_api.shutdown(k['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ------------------------------ Captured log setup ------------------------------ 273s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmpqiz872bu/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmpqiz872bu/etc/jupyter'] for config files 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpqiz872bu/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpqiz872bu/config 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpqiz872bu/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpqiz872bu/config 273s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmpqiz872bu/notebooks 273s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 273s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 273s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 273s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 273s WARNING NotebookApp:handlers.py:612 Forbidden 273s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 0.790000ms referer=None 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpqiz872bu/runtime/kernel-c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:48977 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34213 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.960000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be (127.0.0.1) 3.770000ms 273s DEBUG NotebookApp:zmqhandlers.py:298 Initializing websocket connection /a%40b/api/kernels/c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be/channels 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s WARNING NotebookApp:zmqhandlers.py:286 No session ID specified 273s DEBUG NotebookApp:handlers.py:277 Requesting kernel info from c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:44983 273s DEBUG NotebookApp:kernelmanager.py:423 activity on c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be: status (starting) 273s DEBUG NotebookApp:kernelmanager.py:423 activity on c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be: status (busy) 273s DEBUG NotebookApp:handlers.py:306 Received kernel info: {'status': 'ok', 'protocol_version': '5.3', 'implementation': 'ipython', 'implementation_version': '8.35.0', 'language_info': {'name': 'python', 'version': '3.13.11', 'mimetype': 'text/x-python', 'codemirror_mode': {'name': 'ipython', 'version': 3}, 'pygments_lexer': 'ipython3', 'nbconvert_exporter': 'python', 'file_extension': '.py'}, 'banner': "Python 3.13.11 (main, Dec 6 2025, 13:15:20) [GCC 15.2.0]\nType 'copyright', 'credits' or 'license' for more information\nIPython 8.35.0 -- An enhanced Interactive Python. Type '?' for help.\n", 'help_links': [{'text': 'Python Reference', 'url': 'https://docs.python.org/3.13'}, {'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/'}]} 273s INFO NotebookApp:handlers.py:326 Adapting from protocol version 5.3 (kernel c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be) to 5.4 (client). 273s DEBUG NotebookApp:kernelmanager.py:423 activity on c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be: status (idle) 273s DEBUG NotebookApp:log.py:59 101 GET /a%40b/api/kernels/c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be/channels (127.0.0.1) 647.030000ms 273s DEBUG NotebookApp:zmqhandlers.py:159 Opening websocket /a%40b/api/kernels/c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be/channels 273s DEBUG NotebookApp:kernelmanager.py:252 Getting buffer for c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34213 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:44983 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:48977 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:46987 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:44983 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:48977 273s WARNING NotebookApp:websocket.py:1327 The websocket_ping_timeout (90000) cannot be longer than the websocket_ping_interval (30000). 273s Setting websocket_ping_timeout=30000 273s DEBUG NotebookApp:handlers.py:255 Nudge: attempt 1 on kernel c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be (127.0.0.1) 0.970000ms 273s DEBUG NotebookApp:kernelmanager.py:423 activity on c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be: status (busy) 273s DEBUG NotebookApp:handlers.py:207 Nudge: IOPub received: c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be 273s DEBUG NotebookApp:handlers.py:210 Nudge: resolving iopub future: c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be 273s DEBUG NotebookApp:kernelmanager.py:423 activity on c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be: status (busy) 273s DEBUG NotebookApp:handlers.py:195 Nudge: shell info reply received: c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be 273s DEBUG NotebookApp:handlers.py:197 Nudge: resolving shell future: c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be 273s DEBUG NotebookApp:handlers.py:201 Nudge: control info reply received: c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be 273s DEBUG NotebookApp:kernelmanager.py:423 activity on c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be: status (idle) 273s DEBUG NotebookApp:kernelmanager.py:423 activity on c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be: status (idle) 273s DEBUG NotebookApp:handlers.py:579 Websocket closed c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be:2487eff1-1b7293cb4f9f840dccb2a0c7 273s INFO NotebookApp:kernelmanager.py:222 Starting buffering for c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be:2487eff1-1b7293cb4f9f840dccb2a0c7 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be 273s DEBUG NotebookApp:kernelmanager.py:235 Buffering msg on c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be:iopub 273s DEBUG NotebookApp:kernelmanager.py:235 Buffering msg on c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be:iopub 273s DEBUG NotebookApp:kernelmanager.py:235 Buffering msg on c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be:iopub 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be (127.0.0.1) 0.980000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be (127.0.0.1) 0.930000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.960000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be 273s INFO NotebookApp:kernelmanager.py:286 Discarding 3 buffered messages for c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be:2487eff1-1b7293cb4f9f840dccb2a0c7 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 273s future.result() 273s ~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 273s yield maybe_future(km.shutdown_kernel(kernel_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 273s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 273s raise km.ready.exception() # type: ignore[misc] 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be (127.0.0.1) 8.130000ms referer=None 273s ____________________ AsyncKernelAPITest.test_default_kernel ____________________ 273s 273s self = 273s 273s def tearDown(self): 273s for k in self.kern_api.list().json(): 273s > self.kern_api.shutdown(k['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/4e21d1f6-2e30-4082-a1c2-d30e61dab447 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ----------------------------- Captured stderr call ----------------------------- 273s Traceback (most recent call last): 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpqiz872bu/runtime/kernel-4e21d1f6-2e30-4082-a1c2-d30e61dab447.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:57805 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:56813 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: 4e21d1f6-2e30-4082-a1c2-d30e61dab447, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.220000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.030000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be (127.0.0.1) 1.110000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 4e21d1f6-2e30-4082-a1c2-d30e61dab447 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 4e21d1f6-2e30-4082-a1c2-d30e61dab447 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/4e21d1f6-2e30-4082-a1c2-d30e61dab447 (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/4e21d1f6-2e30-4082-a1c2-d30e61dab447', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 273s future.result() 273s ~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 273s yield maybe_future(km.shutdown_kernel(kernel_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 273s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 273s raise km.ready.exception() # type: ignore[misc] 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/4e21d1f6-2e30-4082-a1c2-d30e61dab447 (127.0.0.1) 8.480000ms referer=None 273s --------------------------- Captured stderr teardown --------------------------- 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 273s from pathlib import Path 273s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 273s from ._local import * 273s File "/usr/lib/python3.13/pathlib/_local.py", line 58, in 273s class PurePath(PurePathBase): 273s ...<397 lines>... 273s return '' if path_str == '.' else path_str 273s File "/usr/lib/python3.13/pathlib/_local.py", line 174, in PurePath 273s @property 273s ^^^^^^^^ 273s KeyboardInterrupt 273s ____________________ AsyncKernelAPITest.test_kernel_handler ____________________ 273s 273s self = 273s 273s def test_kernel_handler(self): 273s # GET kernel with given id 273s kid = self.kern_api.start().json()['id'] 273s r = self.kern_api.get(kid) 273s kern1 = r.json() 273s self.assertEqual(r.status_code, 200) 273s assert isinstance(kern1, dict) 273s self.assertIn('id', kern1) 273s self.assertEqual(kern1['id'], kid) 273s 273s # Request a bad kernel id and check that a JSON 273s # message is returned! 273s bad_id = '111-111-111-111-111' 273s with assert_http_error(404, 'Kernel does not exist: ' + bad_id): 273s self.kern_api.get(bad_id) 273s 273s # DELETE kernel with id 273s > r = self.kern_api.shutdown(kid) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:169: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/5140eeb1-1391-4141-b056-970ac4aed4d9 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ----------------------------- Captured stderr call ----------------------------- 273s Traceback (most recent call last): 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpqiz872bu/runtime/kernel-5140eeb1-1391-4141-b056-970ac4aed4d9.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:38905 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:33379 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: 5140eeb1-1391-4141-b056-970ac4aed4d9, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 25.230000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/5140eeb1-1391-4141-b056-970ac4aed4d9 (127.0.0.1) 2.480000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s WARNING NotebookApp:web.py:1943 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1): Kernel does not exist: 111-111-111-111-111 273s WARNING NotebookApp:handlers.py:612 Kernel does not exist: 111-111-111-111-111 273s WARNING NotebookApp:log.py:59 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1) 2.790000ms referer=None 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 5140eeb1-1391-4141-b056-970ac4aed4d9 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 5140eeb1-1391-4141-b056-970ac4aed4d9 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/5140eeb1-1391-4141-b056-970ac4aed4d9 (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/5140eeb1-1391-4141-b056-970ac4aed4d9', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 273s future.result() 273s ~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 273s yield maybe_future(km.shutdown_kernel(kernel_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 273s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 273s raise km.ready.exception() # type: ignore[misc] 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/5140eeb1-1391-4141-b056-970ac4aed4d9 (127.0.0.1) 12.840000ms referer=None 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 2.660000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 4e21d1f6-2e30-4082-a1c2-d30e61dab447 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 4e21d1f6-2e30-4082-a1c2-d30e61dab447 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/4e21d1f6-2e30-4082-a1c2-d30e61dab447 (127.0.0.1) 2.760000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 5140eeb1-1391-4141-b056-970ac4aed4d9 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 5140eeb1-1391-4141-b056-970ac4aed4d9 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/5140eeb1-1391-4141-b056-970ac4aed4d9 (127.0.0.1) 2.620000ms 273s --------------------------- Captured stderr teardown --------------------------- 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 273s from pathlib import Path 273s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 273s from ._abc import * 273s File "/usr/lib/python3.13/pathlib/_abc.py", line 14, in 273s import functools 273s File "/usr/lib/python3.13/functools.py", line 18, in 273s from collections import namedtuple 273s File "/usr/lib/python3.13/collections/__init__.py", line 41, in 273s from reprlib import recursive_repr as _recursive_repr 273s File "", line 1360, in _find_and_load 273s File "", line 1331, in _find_and_load_unlocked 273s File "", line 935, in _load_unlocked 273s File "", line 1019, in exec_module 273s File "", line 1152, in get_code 273s File "", line 781, in _compile_bytecode 273s KeyboardInterrupt 273s _________________ AsyncKernelAPITest.test_main_kernel_handler __________________ 273s 273s self = 273s 273s def test_main_kernel_handler(self): 273s # POST request 273s r = self.kern_api.start() 273s kern1 = r.json() 273s self.assertEqual(r.headers['location'], url_path_join(self.url_prefix, 'api/kernels', kern1['id'])) 273s self.assertEqual(r.status_code, 201) 273s self.assertIsInstance(kern1, dict) 273s 273s report_uri = url_path_join(self.url_prefix, 'api/security/csp-report') 273s expected_csp = '; '.join([ 273s "frame-ancestors 'self'", 273s 'report-uri ' + report_uri, 273s "default-src 'none'" 273s ]) 273s self.assertEqual(r.headers['Content-Security-Policy'], expected_csp) 273s 273s # GET request 273s r = self.kern_api.list() 273s self.assertEqual(r.status_code, 200) 273s assert isinstance(r.json(), list) 273s self.assertEqual(r.json()[0]['id'], kern1['id']) 273s self.assertEqual(r.json()[0]['name'], kern1['name']) 273s 273s # create another kernel and check that they both are added to the 273s # list of kernels from a GET request 273s kern2 = self.kern_api.start().json() 273s assert isinstance(kern2, dict) 273s r = self.kern_api.list() 273s kernels = r.json() 273s self.assertEqual(r.status_code, 200) 273s assert isinstance(kernels, list) 273s self.assertEqual(len(kernels), 2) 273s 273s # Interrupt a kernel 273s r = self.kern_api.interrupt(kern2['id']) 273s self.assertEqual(r.status_code, 204) 273s 273s # Restart a kernel 273s > r = self.kern_api.restart(kern2['id']) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:147: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:63: in restart 273s return self._req('POST', url_path_join(id, 'restart')) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: http://localhost:12341/a%40b/api/kernels/e3918275-4b65-4353-8edd-15e506d0c040/restart 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ----------------------------- Captured stderr call ----------------------------- 273s Traceback (most recent call last): 273s Traceback (most recent call last): 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 273s from ipykernel import kernelapp as app 273s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 273s from .connect import * # noqa: F403 273s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 7, in 273s import json 273s File "/usr/lib/python3.13/json/__init__.py", line 107, in 273s from .encoder import JSONEncoder 273s File "", line 1360, in _find_and_load 273s File "", line 1322, in _find_and_load_unlocked 273s File "", line 1262, in _find_spec 273s File "", line 1556, in find_spec 273s File "", line 1530, in _get_spec 273s File "", line 1629, in find_spec 273s File "", line 152, in _path_stat 273s KeyboardInterrupt 273s Traceback (most recent call last): 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 273s from ipykernel import kernelapp as app 273s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 273s from .connect import * # noqa: F403 273s ^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 12, in 273s import jupyter_client 273s File "/usr/lib/python3/dist-packages/jupyter_client/__init__.py", line 4, in 273s from .asynchronous import AsyncKernelClient 273s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/__init__.py", line 1, in 273s from .client import AsyncKernelClient # noqa 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/client.py", line 9, in 273s import zmq.asyncio 273s File "/usr/lib/python3/dist-packages/zmq/asyncio.py", line 10, in 273s import asyncio 273s File "/usr/lib/python3.13/asyncio/__init__.py", line 8, in 273s from .base_events import * 273s File "/usr/lib/python3.13/asyncio/base_events.py", line 45, in 273s from . import staggered 273s File "/usr/lib/python3.13/asyncio/staggered.py", line 9, in 273s from . import locks 273s File "/usr/lib/python3.13/asyncio/locks.py", line 219, in 273s class Condition(_ContextManagerMixin, mixins._LoopBoundMixin): 273s ...<129 lines>... 273s self.notify(len(self._waiters)) 273s KeyboardInterrupt 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpqiz872bu/runtime/kernel-fa8e51ed-6907-4e5b-8e69-7e6b0a63d977.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:58267 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:46367 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: fa8e51ed-6907-4e5b-8e69-7e6b0a63d977, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 23.540000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 2.360000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpqiz872bu/runtime/kernel-e3918275-4b65-4353-8edd-15e506d0c040.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:60897 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34347 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: e3918275-4b65-4353-8edd-15e506d0c040, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 24.520000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 2.410000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: e3918275-4b65-4353-8edd-15e506d0c040 273s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/e3918275-4b65-4353-8edd-15e506d0c040/interrupt (127.0.0.1) 3.820000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 273s yield maybe_future(km.restart_kernel(kernel_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 291, in __step_run_and_handle_result 273s result = coro.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 273s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 273s File "/usr/lib/python3.14/asyncio/futures.py", line 295, in __await__ 273s yield self # This tells Task to wait for completion. 273s ^^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 273s future.result() 273s ~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 273s await ensure_async(kernel.restart_kernel(now=now)) 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 273s await self._async_shutdown_kernel(now=now, restart=True) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/e3918275-4b65-4353-8edd-15e506d0c040/restart (127.0.0.1) 8.190000ms referer=None 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 2.530000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for fa8e51ed-6907-4e5b-8e69-7e6b0a63d977 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: fa8e51ed-6907-4e5b-8e69-7e6b0a63d977 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/fa8e51ed-6907-4e5b-8e69-7e6b0a63d977 (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/fa8e51ed-6907-4e5b-8e69-7e6b0a63d977', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 273s future.result() 273s ~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 273s yield maybe_future(km.shutdown_kernel(kernel_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 273s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 273s raise km.ready.exception() # type: ignore[misc] 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/fa8e51ed-6907-4e5b-8e69-7e6b0a63d977 (127.0.0.1) 12.850000ms referer=None 273s ______________________ AsyncKernelAPITest.test_no_kernels ______________________ 273s 273s self = 273s 273s def test_no_kernels(self): 273s """Make sure there are no kernels running at the start""" 273s kernels = self.kern_api.list().json() 273s > self.assertEqual(kernels, []) 273s E AssertionError: Lists differ: [{'id': 'fa8e51ed-6907-4e5b-8e69-7e6b0a63d[281 chars]: 0}] != [] 273s E 273s E First list contains 2 additional elements. 273s E First extra element 0: 273s E {'id': 'fa8e51ed-6907-4e5b-8e69-7e6b0a63d977', 'name': 'python3', 'last_activity': '2026-02-06T04:19:04.576681Z', 'execution_state': 'starting', 'connections': 0} 273s E 273s E + [] 273s E - [{'connections': 0, 273s E - 'execution_state': 'starting', 273s E - 'id': 'fa8e51ed-6907-4e5b-8e69-7e6b0a63d977', 273s E - 'last_activity': '2026-02-06T04:19:04.576681Z', 273s E - 'name': 'python3'}, 273s E - {'connections': 0, 273s E - 'execution_state': 'starting', 273s E - 'id': 'e3918275-4b65-4353-8edd-15e506d0c040', 273s E - 'last_activity': '2026-02-06T04:19:04.612145Z', 273s E - 'name': 'python3'}] 273s 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:91: AssertionError 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 2.560000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 2.410000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for fa8e51ed-6907-4e5b-8e69-7e6b0a63d977 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: fa8e51ed-6907-4e5b-8e69-7e6b0a63d977 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/fa8e51ed-6907-4e5b-8e69-7e6b0a63d977 (127.0.0.1) 3.020000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for e3918275-4b65-4353-8edd-15e506d0c040 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: e3918275-4b65-4353-8edd-15e506d0c040 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/e3918275-4b65-4353-8edd-15e506d0c040 (127.0.0.1) 3.110000ms 273s ---------------------------- Captured log teardown ----------------------------- 273s INFO NotebookApp:notebookapp.py:2164 Shutting down 0 kernels 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: fa8e51ed-6907-4e5b-8e69-7e6b0a63d977 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c7d22b29-9cf6-4b01-9c28-fac2e1a0a9be 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 5140eeb1-1391-4141-b056-970ac4aed4d9 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 4e21d1f6-2e30-4082-a1c2-d30e61dab447 273s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 273s __________________________ SessionAPITest.test_create __________________________ 273s 273s @self.addCleanup 273s def cleanup_sessions(): 273s for session in self.sess_api.list().json(): 273s > self.sess_api.delete(session['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/252bdc50-78c6-4b40-b526-ee51fa04df93 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ------------------------------ Captured log setup ------------------------------ 273s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmpfpu_0lxf/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmpfpu_0lxf/etc/jupyter'] for config files 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpfpu_0lxf/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpfpu_0lxf/config 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpfpu_0lxf/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpfpu_0lxf/config 273s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmpfpu_0lxf/notebooks 273s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 273s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 273s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 273s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 273s WARNING NotebookApp:handlers.py:612 Forbidden 273s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 0.750000ms referer=None 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.510000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpfpu_0lxf/runtime/kernel-b07aff54-dc3e-4cf2-b71c-b4ffeed2b52a.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:49711 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55599 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: b07aff54-dc3e-4cf2-b71c-b4ffeed2b52a, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpfpu_0lxf/notebooks/foo'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 28.780000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.130000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions/252bdc50-78c6-4b40-b526-ee51fa04df93 (127.0.0.1) 1.090000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.170000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for b07aff54-dc3e-4cf2-b71c-b4ffeed2b52a 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: b07aff54-dc3e-4cf2-b71c-b4ffeed2b52a 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/252bdc50-78c6-4b40-b526-ee51fa04df93 (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/252bdc50-78c6-4b40-b526-ee51fa04df93', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 273s yield maybe_future(sm.delete_session(session_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 273s yielded = self.gen.send(value) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 273s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 273s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 273s stopper = ensure_async(km.shutdown_kernel(now, restart)) 273s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/252bdc50-78c6-4b40-b526-ee51fa04df93 (127.0.0.1) 12.510000ms referer=None 273s --------------------------- Captured stderr teardown --------------------------- 273s Traceback (most recent call last): 273s __________________ SessionAPITest.test_create_console_session __________________ 273s 273s @self.addCleanup 273s def cleanup_sessions(): 273s for session in self.sess_api.list().json(): 273s > self.sess_api.delete(session['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/759dfc9d-2506-4a11-93ec-3e231abe2a84 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ----------------------------- Captured stderr call ----------------------------- 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 273s from pathlib import Path 273s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 273s from ._abc import * 273s File "/usr/lib/python3.13/pathlib/_abc.py", line 14, in 273s import functools 273s File "/usr/lib/python3.13/functools.py", line 18, in 273s from collections import namedtuple 273s File "/usr/lib/python3.13/collections/__init__.py", line 35, in 273s from itertools import chain as _chain 273s File "", line 1357, in _find_and_load 273s File "", line 418, in __enter__ 273s File "", line 316, in acquire 273s KeyboardInterrupt 273s Traceback (most recent call last): 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 273s from ipykernel import kernelapp as app 273s File "", line 1360, in _find_and_load 273s File "", line 1331, in _find_and_load_unlocked 273s File "", line 921, in _load_unlocked 273s File "", line 818, in module_from_spec 273s File "", line 49, in _new_module 273s KeyboardInterrupt 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpfpu_0lxf/runtime/kernel-c9287b9a-bb91-4d20-b115-a5e917a3c4a4.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:58893 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:47743 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: c9287b9a-bb91-4d20-b115-a5e917a3c4a4, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpfpu_0lxf/notebooks/foo'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 26.190000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.280000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for b07aff54-dc3e-4cf2-b71c-b4ffeed2b52a 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: b07aff54-dc3e-4cf2-b71c-b4ffeed2b52a 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/252bdc50-78c6-4b40-b526-ee51fa04df93 (127.0.0.1) 1.810000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for c9287b9a-bb91-4d20-b115-a5e917a3c4a4 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c9287b9a-bb91-4d20-b115-a5e917a3c4a4 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/759dfc9d-2506-4a11-93ec-3e231abe2a84 (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/759dfc9d-2506-4a11-93ec-3e231abe2a84', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 273s yield maybe_future(sm.delete_session(session_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 273s yielded = self.gen.send(value) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 273s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 273s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 273s stopper = ensure_async(km.shutdown_kernel(now, restart)) 273s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/759dfc9d-2506-4a11-93ec-3e231abe2a84 (127.0.0.1) 13.490000ms referer=None 273s ____________________ SessionAPITest.test_create_deprecated _____________________ 273s 273s @self.addCleanup 273s def cleanup_sessions(): 273s for session in self.sess_api.list().json(): 273s > self.sess_api.delete(session['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/28900eab-ffbe-41a9-b641-069dbac207ed 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ----------------------------- Captured stderr call ----------------------------- 273s Traceback (most recent call last): 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 273s from ipykernel import kernelapp as app 273s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 273s from .connect import * # noqa: F403 273s ^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 9, in 273s from subprocess import PIPE, Popen 273s File "/usr/lib/python3.13/subprocess.py", line 46, in 273s import locale 273s File "", line 1360, in _find_and_load 273s File "", line 1331, in _find_and_load_unlocked 273s File "", line 935, in _load_unlocked 273s File "", line 1019, in exec_module 273s File "", line 1152, in get_code 273s File "", line 781, in _compile_bytecode 273s KeyboardInterrupt 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s WARNING NotebookApp:handlers.py:46 Sessions API changed, see updated swagger docs 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpfpu_0lxf/runtime/kernel-3bbfa3ce-06ed-4fa6-a78c-5675f4073a87.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:43349 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55519 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: 3bbfa3ce-06ed-4fa6-a78c-5675f4073a87, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpfpu_0lxf/notebooks/foo'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 27.010000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.180000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for c9287b9a-bb91-4d20-b115-a5e917a3c4a4 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c9287b9a-bb91-4d20-b115-a5e917a3c4a4 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/759dfc9d-2506-4a11-93ec-3e231abe2a84 (127.0.0.1) 4.460000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 3bbfa3ce-06ed-4fa6-a78c-5675f4073a87 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 3bbfa3ce-06ed-4fa6-a78c-5675f4073a87 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/28900eab-ffbe-41a9-b641-069dbac207ed (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/28900eab-ffbe-41a9-b641-069dbac207ed', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 273s yield maybe_future(sm.delete_session(session_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 273s yielded = self.gen.send(value) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 273s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 273s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 273s stopper = ensure_async(km.shutdown_kernel(now, restart)) 273s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/28900eab-ffbe-41a9-b641-069dbac207ed (127.0.0.1) 11.680000ms referer=None 273s ___________________ SessionAPITest.test_create_file_session ____________________ 273s 273s @self.addCleanup 273s def cleanup_sessions(): 273s for session in self.sess_api.list().json(): 273s > self.sess_api.delete(session['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/a8d8817c-4465-44d3-9d4f-ad14df5dcda5 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ----------------------------- Captured stderr call ----------------------------- 273s Fatal Python error: init_import_site: Failed to import the site module 273s Python runtime state: initialized 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpfpu_0lxf/runtime/kernel-4af97127-5448-41d3-bb9f-c899b8566d5e.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:42163 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55415 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: 4af97127-5448-41d3-bb9f-c899b8566d5e, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpfpu_0lxf/notebooks/foo'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 24.850000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.190000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 3bbfa3ce-06ed-4fa6-a78c-5675f4073a87 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 3bbfa3ce-06ed-4fa6-a78c-5675f4073a87 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/28900eab-ffbe-41a9-b641-069dbac207ed (127.0.0.1) 1.570000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 4af97127-5448-41d3-bb9f-c899b8566d5e 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 4af97127-5448-41d3-bb9f-c899b8566d5e 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/a8d8817c-4465-44d3-9d4f-ad14df5dcda5 (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/a8d8817c-4465-44d3-9d4f-ad14df5dcda5', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 273s yield maybe_future(sm.delete_session(session_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 273s yielded = self.gen.send(value) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 273s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 273s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 273s stopper = ensure_async(km.shutdown_kernel(now, restart)) 273s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/a8d8817c-4465-44d3-9d4f-ad14df5dcda5 (127.0.0.1) 11.070000ms referer=None 273s --------------------------- Captured stderr teardown --------------------------- 273s Traceback (most recent call last): 273s File "/usr/lib/python3.13/site.py", line 735, in 273s main() 273s ~~~~^^ 273s File "/usr/lib/python3.13/site.py", line 728, in main 273s execsitecustomize() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.13/site.py", line 667, in execsitecustomize 273s import sitecustomize 273s File "/usr/lib/python3.13/sitecustomize.py", line 3, in 273s import apport_python_hook 273s File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 14, in 273s import types 273s File "/usr/lib/python3.13/types.py", line 239, in 273s class _GeneratorWrapper: 273s ...<34 lines>... 273s __await__ = __iter__ 273s KeyboardInterrupt 273s __________________ SessionAPITest.test_create_with_kernel_id ___________________ 273s 273s self = 273s 273s def test_create_with_kernel_id(self): 273s # create a new kernel 273s r = self.request('POST', 'api/kernels') 273s r.raise_for_status() 273s kernel = r.json() 273s 273s resp = self.sess_api.create('foo/nb1.ipynb', kernel_id=kernel['id']) 273s self.assertEqual(resp.status_code, 201) 273s newsession = resp.json() 273s self.assertIn('id', newsession) 273s self.assertEqual(newsession['path'], 'foo/nb1.ipynb') 273s self.assertEqual(newsession['kernel']['id'], kernel['id']) 273s self.assertEqual(resp.headers['Location'], f'{self.url_prefix}api/sessions/{newsession["id"]}') 273s 273s sessions = self.sess_api.list().json() 273s > self.assertEqual(sessions, [newsession]) 273s E AssertionError: Lists differ: [{'id': 'a8d8817c-4465-44d3-9d4f-ad14df5dcda5', 'p[553 chars]ne}}] != [{'id': '1d45022e-0df2-4610-9eed-05984c43104f', 'p[279 chars]ne}}] 273s E 273s E First differing element 0: 273s E {'id': 'a8d8817c-4465-44d3-9d4f-ad14df5dcda5', 'p[218 chars]: 0}} 273s E {'id': '1d45022e-0df2-4610-9eed-05984c43104f', 'p[278 chars]one}} 273s E 273s E First list contains 1 additional elements. 273s E First extra element 1: 273s E {'id': '1d45022e-0df2-4610-9eed-05984c43104f', 'path': 'foo/nb1.ipynb', 'name': None, 'type': 'notebook', 'kernel': {'id': '030cb0a4-a91d-48df-a635-550401b6b1a7', 'name': 'python3', 'last_activity': '2026-02-06T04:19:05.245174Z', 'execution_state': 'starting', 'connections': 0}, 'notebook': {'path': 'foo/nb1.ipynb', 'name': None}} 273s E 273s E Diff is 830 characters long. Set self.maxDiff to None to see it. 273s 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:178: AssertionError 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpfpu_0lxf/runtime/kernel-030cb0a4-a91d-48df-a635-550401b6b1a7.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:41049 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:51025 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: 030cb0a4-a91d-48df-a635-550401b6b1a7, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 24.190000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.230000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.070000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.050000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 4af97127-5448-41d3-bb9f-c899b8566d5e 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 4af97127-5448-41d3-bb9f-c899b8566d5e 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/a8d8817c-4465-44d3-9d4f-ad14df5dcda5 (127.0.0.1) 1.590000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 030cb0a4-a91d-48df-a635-550401b6b1a7 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 030cb0a4-a91d-48df-a635-550401b6b1a7 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/1d45022e-0df2-4610-9eed-05984c43104f (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/1d45022e-0df2-4610-9eed-05984c43104f', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 273s yield maybe_future(sm.delete_session(session_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 273s yielded = self.gen.send(value) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 273s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 273s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 273s stopper = ensure_async(km.shutdown_kernel(now, restart)) 273s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/1d45022e-0df2-4610-9eed-05984c43104f (127.0.0.1) 11.410000ms referer=None 273s _____________________ SessionAPITest.test_modify_kernel_id _____________________ 273s 273s @self.addCleanup 273s def cleanup_sessions(): 273s for session in self.sess_api.list().json(): 273s > self.sess_api.delete(session['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/1d45022e-0df2-4610-9eed-05984c43104f 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ---------------------------- Captured stderr setup ----------------------------- 273s Traceback (most recent call last): 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 273s from pathlib import Path 273s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 273s from ._abc import * 273s File "/usr/lib/python3.13/pathlib/_abc.py", line 14, in 273s import functools 273s File "/usr/lib/python3.13/functools.py", line 18, in 273s from collections import namedtuple 273s File "", line 1360, in _find_and_load 273s File "", line 1331, in _find_and_load_unlocked 273s File "", line 935, in _load_unlocked 273s File "", line 1019, in exec_module 273s File "", line 1152, in get_code 273s File "", line 781, in _compile_bytecode 273s KeyboardInterrupt 273s ----------------------------- Captured stderr call ----------------------------- 273s Could not import runpy module 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 2.790000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpfpu_0lxf/runtime/kernel-cd935b01-78d7-4897-b38f-a3aa5011699e.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:45695 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:40565 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: cd935b01-78d7-4897-b38f-a3aa5011699e, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 24.210000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 030cb0a4-a91d-48df-a635-550401b6b1a7 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 030cb0a4-a91d-48df-a635-550401b6b1a7 273s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/1d45022e-0df2-4610-9eed-05984c43104f (127.0.0.1) 2.150000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.100000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.080000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for cd935b01-78d7-4897-b38f-a3aa5011699e 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: cd935b01-78d7-4897-b38f-a3aa5011699e 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/1d45022e-0df2-4610-9eed-05984c43104f (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/1d45022e-0df2-4610-9eed-05984c43104f', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 273s yield maybe_future(sm.delete_session(session_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 273s yielded = self.gen.send(value) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 273s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 273s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 273s stopper = ensure_async(km.shutdown_kernel(now, restart)) 273s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/1d45022e-0df2-4610-9eed-05984c43104f (127.0.0.1) 11.920000ms referer=None 273s --------------------------- Captured stderr teardown --------------------------- 273s Traceback (most recent call last): 273s File "/usr/lib/python3.13/runpy.py", line 15, in 273s import importlib.util 273s File "", line 1360, in _find_and_load 273s File "", line 1339, in _find_and_load_unlocked 273s KeyboardInterrupt 273s ____________________ SessionAPITest.test_modify_kernel_name ____________________ 273s 273s @self.addCleanup 273s def cleanup_sessions(): 273s for session in self.sess_api.list().json(): 273s > self.sess_api.delete(session['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/1d45022e-0df2-4610-9eed-05984c43104f 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ----------------------------- Captured stderr call ----------------------------- 273s Traceback (most recent call last): 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 273s from pathlib import Path 273s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 273s from ._local import * 273s File "/usr/lib/python3.13/pathlib/_local.py", line 463, in 273s class PurePosixPath(PurePath): 273s ...<6 lines>... 273s __slots__ = () 273s File "/usr/lib/python3.13/pathlib/_local.py", line 463, in PurePosixPath 273s class PurePosixPath(PurePath): 273s 273s KeyboardInterrupt 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.250000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpfpu_0lxf/runtime/kernel-b1bb088c-be6f-4c48-81e4-890899178eca.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:44445 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:47107 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: b1bb088c-be6f-4c48-81e4-890899178eca, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3', 'cwd': '/tmp/tmpfpu_0lxf/notebooks/foo'} 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for cd935b01-78d7-4897-b38f-a3aa5011699e 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: cd935b01-78d7-4897-b38f-a3aa5011699e 273s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/1d45022e-0df2-4610-9eed-05984c43104f (127.0.0.1) 25.920000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.060000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.130000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for b1bb088c-be6f-4c48-81e4-890899178eca 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: b1bb088c-be6f-4c48-81e4-890899178eca 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/1d45022e-0df2-4610-9eed-05984c43104f (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/1d45022e-0df2-4610-9eed-05984c43104f', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 273s yield maybe_future(sm.delete_session(session_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 273s yielded = self.gen.send(value) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 273s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 273s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 273s stopper = ensure_async(km.shutdown_kernel(now, restart)) 273s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 273s return _runner_map[name].run(inner) 273s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 273s return fut.result(None) 273s ~~~~~~~~~~^^^^^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 273s return self.__get_result() 273s ~~~~~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 273s raise self._exception 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/1d45022e-0df2-4610-9eed-05984c43104f (127.0.0.1) 13.860000ms referer=None 273s _______________________ AsyncSessionAPITest.test_create ________________________ 273s 273s @self.addCleanup 273s def cleanup_sessions(): 273s for session in self.sess_api.list().json(): 273s > self.sess_api.delete(session['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/300f7370-dca2-4101-97d3-32a5744689f9 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ------------------------------ Captured log setup ------------------------------ 273s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmpcbffyxzf/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmpcbffyxzf/etc/jupyter'] for config files 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpcbffyxzf/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpcbffyxzf/config 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpcbffyxzf/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 273s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpcbffyxzf/config 273s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmpcbffyxzf/notebooks 273s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 273s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 273s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 273s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 273s WARNING NotebookApp:handlers.py:612 Forbidden 273s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 0.810000ms referer=None 273s ----------------------------- Captured stderr call ----------------------------- 273s Traceback (most recent call last): 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.360000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcbffyxzf/runtime/kernel-2943f5eb-f5bf-42a3-b596-76a5936f352b.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:35815 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:47473 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: 2943f5eb-f5bf-42a3-b596-76a5936f352b, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpcbffyxzf/notebooks/foo'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 18.000000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.120000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions/300f7370-dca2-4101-97d3-32a5744689f9 (127.0.0.1) 1.120000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.070000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 2943f5eb-f5bf-42a3-b596-76a5936f352b 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 2943f5eb-f5bf-42a3-b596-76a5936f352b 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/300f7370-dca2-4101-97d3-32a5744689f9 (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/300f7370-dca2-4101-97d3-32a5744689f9', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 273s future.result() 273s ~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 273s yield maybe_future(sm.delete_session(session_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 273s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 273s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 273s raise km.ready.exception() # type: ignore[misc] 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/300f7370-dca2-4101-97d3-32a5744689f9 (127.0.0.1) 8.270000ms referer=None 273s --------------------------- Captured stderr teardown --------------------------- 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 273s from ipykernel import kernelapp as app 273s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 273s from .connect import * # noqa: F403 273s ^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 5, in 273s from __future__ import annotations 273s File "", line 1357, in _find_and_load 273s File "", line 421, in __exit__ 273s File "", line 378, in release 273s KeyboardInterrupt 273s _______________ AsyncSessionAPITest.test_create_console_session ________________ 273s 273s @self.addCleanup 273s def cleanup_sessions(): 273s for session in self.sess_api.list().json(): 273s > self.sess_api.delete(session['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/1d0f9eb6-3115-4223-a1f6-c6126a8c085b 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ----------------------------- Captured stderr call ----------------------------- 273s Traceback (most recent call last): 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcbffyxzf/runtime/kernel-e3fb3e08-fa61-4c5b-a76e-72f8ab5d03f1.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:33587 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:45927 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: e3fb3e08-fa61-4c5b-a76e-72f8ab5d03f1, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpcbffyxzf/notebooks/foo'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 17.650000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.530000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 2943f5eb-f5bf-42a3-b596-76a5936f352b 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 2943f5eb-f5bf-42a3-b596-76a5936f352b 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/300f7370-dca2-4101-97d3-32a5744689f9 (127.0.0.1) 1.440000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for e3fb3e08-fa61-4c5b-a76e-72f8ab5d03f1 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: e3fb3e08-fa61-4c5b-a76e-72f8ab5d03f1 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/1d0f9eb6-3115-4223-a1f6-c6126a8c085b (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/1d0f9eb6-3115-4223-a1f6-c6126a8c085b', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 273s future.result() 273s ~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 273s yield maybe_future(sm.delete_session(session_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 273s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 273s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 273s raise km.ready.exception() # type: ignore[misc] 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/1d0f9eb6-3115-4223-a1f6-c6126a8c085b (127.0.0.1) 8.020000ms referer=None 273s --------------------------- Captured stderr teardown --------------------------- 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 273s from pathlib import Path 273s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 273s from ._local import * 273s File "/usr/lib/python3.13/pathlib/_local.py", line 473, in 273s class PureWindowsPath(PurePath): 273s ...<7 lines>... 273s __slots__ = () 273s File "/usr/lib/python3.13/pathlib/_local.py", line 479, in PureWindowsPath 273s import ntpath 273s File "", line 1360, in _find_and_load 273s File "", line 1331, in _find_and_load_unlocked 273s File "", line 935, in _load_unlocked 273s File "", line 1019, in exec_module 273s File "", line 1152, in get_code 273s File "", line 781, in _compile_bytecode 273s KeyboardInterrupt 273s __________________ AsyncSessionAPITest.test_create_deprecated __________________ 273s 273s @self.addCleanup 273s def cleanup_sessions(): 273s for session in self.sess_api.list().json(): 273s > self.sess_api.delete(session['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/68e8a6f4-e627-4c29-b10f-055e45cceabc 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ----------------------------- Captured stderr call ----------------------------- 273s Traceback (most recent call last): 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s WARNING NotebookApp:handlers.py:46 Sessions API changed, see updated swagger docs 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcbffyxzf/runtime/kernel-0c7bfe02-2b9f-4356-9228-33f4115f66ec.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:60235 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:58783 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: 0c7bfe02-2b9f-4356-9228-33f4115f66ec, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpcbffyxzf/notebooks/foo'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 17.570000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.230000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for e3fb3e08-fa61-4c5b-a76e-72f8ab5d03f1 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: e3fb3e08-fa61-4c5b-a76e-72f8ab5d03f1 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/1d0f9eb6-3115-4223-a1f6-c6126a8c085b (127.0.0.1) 1.550000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 0c7bfe02-2b9f-4356-9228-33f4115f66ec 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0c7bfe02-2b9f-4356-9228-33f4115f66ec 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/68e8a6f4-e627-4c29-b10f-055e45cceabc (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/68e8a6f4-e627-4c29-b10f-055e45cceabc', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 273s future.result() 273s ~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 273s yield maybe_future(sm.delete_session(session_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 273s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 273s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 273s raise km.ready.exception() # type: ignore[misc] 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/68e8a6f4-e627-4c29-b10f-055e45cceabc (127.0.0.1) 8.260000ms referer=None 273s --------------------------- Captured stderr teardown --------------------------- 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 273s from pathlib import Path 273s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 273s from ._local import * 273s File "", line 1360, in _find_and_load 273s File "", line 1331, in _find_and_load_unlocked 273s File "", line 935, in _load_unlocked 273s File "", line 1019, in exec_module 273s File "", line 1152, in get_code 273s File "", line 781, in _compile_bytecode 273s KeyboardInterrupt 273s _________________ AsyncSessionAPITest.test_create_file_session _________________ 273s 273s @self.addCleanup 273s def cleanup_sessions(): 273s for session in self.sess_api.list().json(): 273s > self.sess_api.delete(session['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/48358f51-2240-49e1-a576-dff51a65cc6c 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ----------------------------- Captured stderr call ----------------------------- 273s Traceback (most recent call last): 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcbffyxzf/runtime/kernel-7f066f0d-dd95-49d0-87a7-fa14c4fb6da5.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:58295 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:51173 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: 7f066f0d-dd95-49d0-87a7-fa14c4fb6da5, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpcbffyxzf/notebooks/foo'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 17.450000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.180000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 0c7bfe02-2b9f-4356-9228-33f4115f66ec 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0c7bfe02-2b9f-4356-9228-33f4115f66ec 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/68e8a6f4-e627-4c29-b10f-055e45cceabc (127.0.0.1) 1.490000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 7f066f0d-dd95-49d0-87a7-fa14c4fb6da5 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 7f066f0d-dd95-49d0-87a7-fa14c4fb6da5 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/48358f51-2240-49e1-a576-dff51a65cc6c (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/48358f51-2240-49e1-a576-dff51a65cc6c', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 273s future.result() 273s ~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 273s yield maybe_future(sm.delete_session(session_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 273s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 273s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 273s raise km.ready.exception() # type: ignore[misc] 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/48358f51-2240-49e1-a576-dff51a65cc6c (127.0.0.1) 9.830000ms referer=None 273s --------------------------- Captured stderr teardown --------------------------- 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 273s from pathlib import Path 273s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 273s from ._abc import * 273s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 273s from glob import _Globber, _no_recurse_symlinks 273s File "/usr/lib/python3.13/glob.py", line 6, in 273s import fnmatch 273s File "", line 1360, in _find_and_load 273s File "", line 1322, in _find_and_load_unlocked 273s File "", line 1262, in _find_spec 273s File "", line 1556, in find_spec 273s File "", line 1530, in _get_spec 273s File "", line 1629, in find_spec 273s File "", line 152, in _path_stat 273s KeyboardInterrupt 273s ________________ AsyncSessionAPITest.test_create_with_kernel_id ________________ 273s 273s self = 273s 273s def test_create_with_kernel_id(self): 273s # create a new kernel 273s r = self.request('POST', 'api/kernels') 273s r.raise_for_status() 273s kernel = r.json() 273s 273s resp = self.sess_api.create('foo/nb1.ipynb', kernel_id=kernel['id']) 273s self.assertEqual(resp.status_code, 201) 273s newsession = resp.json() 273s self.assertIn('id', newsession) 273s self.assertEqual(newsession['path'], 'foo/nb1.ipynb') 273s self.assertEqual(newsession['kernel']['id'], kernel['id']) 273s self.assertEqual(resp.headers['Location'], f'{self.url_prefix}api/sessions/{newsession["id"]}') 273s 273s sessions = self.sess_api.list().json() 273s > self.assertEqual(sessions, [newsession]) 273s E AssertionError: Lists differ: [{'id': '48358f51-2240-49e1-a576-dff51a65cc6c', 'p[553 chars]ne}}] != [{'id': '293a9aa4-d69e-4bd7-984b-4b19cf7f029c', 'p[279 chars]ne}}] 273s E 273s E First differing element 0: 273s E {'id': '48358f51-2240-49e1-a576-dff51a65cc6c', 'p[218 chars]: 0}} 273s E {'id': '293a9aa4-d69e-4bd7-984b-4b19cf7f029c', 'p[278 chars]one}} 273s E 273s E First list contains 1 additional elements. 273s E First extra element 1: 273s E {'id': '293a9aa4-d69e-4bd7-984b-4b19cf7f029c', 'path': 'foo/nb1.ipynb', 'name': None, 'type': 'notebook', 'kernel': {'id': '14446634-41cd-41a0-944f-ce1dcd4b30c8', 'name': 'python3', 'last_activity': '2026-02-06T04:19:05.947652Z', 'execution_state': 'starting', 'connections': 0}, 'notebook': {'path': 'foo/nb1.ipynb', 'name': None}} 273s E 273s E Diff is 830 characters long. Set self.maxDiff to None to see it. 273s 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:178: AssertionError 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcbffyxzf/runtime/kernel-14446634-41cd-41a0-944f-ce1dcd4b30c8.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:38749 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:45985 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: 14446634-41cd-41a0-944f-ce1dcd4b30c8, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 17.860000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.240000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.190000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.220000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 7f066f0d-dd95-49d0-87a7-fa14c4fb6da5 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 7f066f0d-dd95-49d0-87a7-fa14c4fb6da5 273s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/48358f51-2240-49e1-a576-dff51a65cc6c (127.0.0.1) 1.870000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 14446634-41cd-41a0-944f-ce1dcd4b30c8 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 14446634-41cd-41a0-944f-ce1dcd4b30c8 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/293a9aa4-d69e-4bd7-984b-4b19cf7f029c (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/293a9aa4-d69e-4bd7-984b-4b19cf7f029c', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 273s future.result() 273s ~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 273s yield maybe_future(sm.delete_session(session_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 273s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 273s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 273s raise km.ready.exception() # type: ignore[misc] 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/293a9aa4-d69e-4bd7-984b-4b19cf7f029c (127.0.0.1) 8.480000ms referer=None 273s __________________ AsyncSessionAPITest.test_modify_kernel_id ___________________ 273s 273s @self.addCleanup 273s def cleanup_sessions(): 273s for session in self.sess_api.list().json(): 273s > self.sess_api.delete(session['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/293a9aa4-d69e-4bd7-984b-4b19cf7f029c 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ---------------------------- Captured stderr setup ----------------------------- 273s Traceback (most recent call last): 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 273s from pathlib import Path 273s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 273s from ._abc import * 273s File "", line 1360, in _find_and_load 273s File "", line 1322, in _find_and_load_unlocked 273s File "", line 1262, in _find_spec 273s File "", line 1556, in find_spec 273s File "", line 1530, in _get_spec 273s File "", line 1633, in find_spec 273s File "", line 1676, in _fill_cache 273s KeyboardInterrupt 273s ----------------------------- Captured stderr call ----------------------------- 273s Traceback (most recent call last): 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.350000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcbffyxzf/runtime/kernel-7f2fbbcc-566c-4bdb-863e-ec15fd829294.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:48055 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:58473 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: 7f2fbbcc-566c-4bdb-863e-ec15fd829294, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 17.140000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 14446634-41cd-41a0-944f-ce1dcd4b30c8 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 14446634-41cd-41a0-944f-ce1dcd4b30c8 273s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/293a9aa4-d69e-4bd7-984b-4b19cf7f029c (127.0.0.1) 1.690000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.040000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.220000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 7f2fbbcc-566c-4bdb-863e-ec15fd829294 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 7f2fbbcc-566c-4bdb-863e-ec15fd829294 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/293a9aa4-d69e-4bd7-984b-4b19cf7f029c (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/293a9aa4-d69e-4bd7-984b-4b19cf7f029c', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 273s future.result() 273s ~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 273s yield maybe_future(sm.delete_session(session_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 273s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 273s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 273s raise km.ready.exception() # type: ignore[misc] 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/293a9aa4-d69e-4bd7-984b-4b19cf7f029c (127.0.0.1) 8.550000ms referer=None 273s --------------------------- Captured stderr teardown --------------------------- 273s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 273s return _run_code(code, main_globals, None, 273s "__main__", mod_spec) 273s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 273s exec(code, run_globals) 273s ~~~~^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 273s from ipykernel import kernelapp as app 273s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 273s from .connect import * # noqa: F403 273s ^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 7, in 273s import json 273s File "/usr/lib/python3.13/json/__init__.py", line 106, in 273s from .decoder import JSONDecoder, JSONDecodeError 273s File "", line 1357, in _find_and_load 273s File "", line 418, in __enter__ 273s File "", line 316, in acquire 273s KeyboardInterrupt 273s _________________ AsyncSessionAPITest.test_modify_kernel_name __________________ 273s 273s @self.addCleanup 273s def cleanup_sessions(): 273s for session in self.sess_api.list().json(): 273s > self.sess_api.delete(session['id']) 273s 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 273s return self._req('DELETE', id) 273s ^^^^^^^^^^^^^^^^^^^^^^^ 273s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 273s response.raise_for_status() 273s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 273s 273s self = 273s 273s def raise_for_status(self): 273s """Raises :class:`HTTPError`, if one occurred.""" 273s 273s http_error_msg = "" 273s if isinstance(self.reason, bytes): 273s # We attempt to decode utf-8 first because some servers 273s # choose to localize their reason strings. If the string 273s # isn't utf-8, we fall back to iso-8859-1 for all other 273s # encodings. (See PR #3538) 273s try: 273s reason = self.reason.decode("utf-8") 273s except UnicodeDecodeError: 273s reason = self.reason.decode("iso-8859-1") 273s else: 273s reason = self.reason 273s 273s if 400 <= self.status_code < 500: 273s http_error_msg = ( 273s f"{self.status_code} Client Error: {reason} for url: {self.url}" 273s ) 273s 273s elif 500 <= self.status_code < 600: 273s http_error_msg = ( 273s f"{self.status_code} Server Error: {reason} for url: {self.url}" 273s ) 273s 273s if http_error_msg: 273s > raise HTTPError(http_error_msg, response=self) 273s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/293a9aa4-d69e-4bd7-984b-4b19cf7f029c 273s 273s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 273s ----------------------------- Captured stderr call ----------------------------- 273s Fatal Python error: init_import_site: Failed to import the site module 273s Python runtime state: initialized 273s ------------------------------ Captured log call ------------------------------- 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.230000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 273s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpcbffyxzf/runtime/kernel-08021db2-9ad8-43b2-aff3-932787942916.json'] 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:44745 273s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:35923 273s INFO NotebookApp:kernelmanager.py:179 Kernel started: 08021db2-9ad8-43b2-aff3-932787942916, name: python3 273s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3', 'cwd': '/tmp/tmpcbffyxzf/notebooks/foo'} 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 7f2fbbcc-566c-4bdb-863e-ec15fd829294 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 7f2fbbcc-566c-4bdb-863e-ec15fd829294 273s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/293a9aa4-d69e-4bd7-984b-4b19cf7f029c (127.0.0.1) 17.890000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.060000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.090000ms 273s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 273s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 08021db2-9ad8-43b2-aff3-932787942916 273s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 08021db2-9ad8-43b2-aff3-932787942916 273s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/293a9aa4-d69e-4bd7-984b-4b19cf7f029c (127.0.0.1) 273s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/293a9aa4-d69e-4bd7-984b-4b19cf7f029c', version='HTTP/1.1', remote_ip='127.0.0.1') 273s Traceback (most recent call last): 273s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 273s result = await result 273s ^^^^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 273s future.result() 273s ~~~~~~~~~~~~~^^ 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 273s yield maybe_future(sm.delete_session(session_id)) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 273s yielded = self.gen.throw(exc) 273s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 273s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 273s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 273s value = future.result() 273s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 273s raise self._exception.with_traceback(self._exception_tb) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 273s result = coro.send(None) 273s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 273s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 273s raise km.ready.exception() # type: ignore[misc] 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 273s await kernel_awaitable 273s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 273s result = await obj 273s ^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 273s raise e 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 273s out = await method(self, *args, **kwargs) 273s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 273s await self._async_finish_shutdown(restart=restart) 273s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 273s await asyncio.wait_for( 273s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 273s ) 273s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 273s async with timeouts.timeout(timeout): 273s ~~~~~~~~~~~~~~~~^^^^^^^^^ 273s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 273s raise RuntimeError("Timeout should be used inside a task") 273s RuntimeError: Timeout should be used inside a task 273s WARNING NotebookApp:handlers.py:612 Unhandled error 273s ERROR NotebookApp:log.py:55 { 273s "Host": "localhost:12341", 273s "Accept": "*/*", 273s "User-Agent": "python-requests/2.32.5" 273s } 273s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/293a9aa4-d69e-4bd7-984b-4b19cf7f029c (127.0.0.1) 7.970000ms referer=None 273s --------------------------- Captured stderr teardown --------------------------- 273s Traceback (most recent call last): 273s =============================== warnings summary =============================== 273s ../../../usr/lib/python3/dist-packages/notebook/utils.py:280 273s ../../../usr/lib/python3/dist-packages/notebook/utils.py:280 273s /usr/lib/python3/dist-packages/notebook/utils.py:280: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead. 273s return LooseVersion(v) >= LooseVersion(check) 273s 273s ../../../usr/lib/python3/dist-packages/notebook/_tz.py:29: 1 warning 273s services/kernels/tests/test_kernels_api.py: 72 warnings 273s services/sessions/tests/test_sessions_api.py: 96 warnings 273s /usr/lib/python3/dist-packages/notebook/_tz.py:29: DeprecationWarning: datetime.datetime.utcnow() is deprecated and scheduled for removal in a future version. Use timezone-aware objects to represent datetimes in UTC: datetime.datetime.now(datetime.UTC). 273s dt = unaware(*args, **kwargs) 273s 273s ../../../usr/lib/python3/dist-packages/notebook/tests/test_notebookapp_integration.py:14 273s /usr/lib/python3/dist-packages/notebook/tests/test_notebookapp_integration.py:14: PytestUnknownMarkWarning: Unknown pytest.mark.integration_tests - is this a typo? You can register custom marks to avoid this warning - for details, see https://docs.pytest.org/en/stable/how-to/mark.html 273s pytestmark = pytest.mark.integration_tests 273s 273s services/kernels/tests/test_kernels_api.py: 6 warnings 273s services/sessions/tests/test_sessions_api.py: 6 warnings 273s /usr/lib/python3/dist-packages/nest_asyncio.py:71: DeprecationWarning: 'asyncio.get_event_loop_policy' is deprecated and slated for removal in Python 3.16 273s policy = events.get_event_loop_policy() 273s 273s services/kernels/tests/test_kernels_api.py: 22 warnings 273s services/sessions/tests/test_sessions_api.py: 17 warnings 273s /usr/lib/python3/dist-packages/nest_asyncio.py:40: DeprecationWarning: 'asyncio.get_event_loop_policy' is deprecated and slated for removal in Python 3.16 273s loop = events.get_event_loop_policy().get_event_loop() 273s 273s services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_connections 273s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:67: DeprecationWarning: make_current is deprecated; start the event loop first 273s loop.make_current() 273s 273s -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html 273s =========================== short test summary info ============================ 273s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_default_kernel 273s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_kernel_handler 273s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_main_kernel_handler 273s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_no_kernels 273s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_connections 273s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_default_kernel 273s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_kernel_handler 273s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_main_kernel_handler 273s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_no_kernels 273s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create 273s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_console_session 273s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_deprecated 273s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_file_session 273s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_with_kernel_id 273s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_modify_kernel_id 273s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_modify_kernel_name 273s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create 273s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_console_session 273s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_deprecated 273s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_file_session 273s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_with_kernel_id 273s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_modify_kernel_id 273s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_modify_kernel_name 273s ERROR services/kernels/tests/test_kernels_api.py::KernelAPITest::test_main_kernel_handler 273s ERROR services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_main_kernel_handler 273s ERROR services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_with_kernel_id 273s ERROR services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_with_kernel_id 273s ===== 23 failed, 2 passed, 305 deselected, 224 warnings, 4 errors in 6.91s ===== 274s *** END OF RUN 3: NOT ALL TESTS HAVE YET PASSED/XFAILED *** 274s *** STARTING RUN 4: python3.14 -m pytest --pyargs notebook -rfE --last-failed --last-failed-no-failures none --ignore=/usr/lib/python3/dist-packages/notebook/tests/selenium --deselect=services/kernels/tests/test_kernels_api.py::KernelAPITest::test_connections 278s ============================= test session starts ============================== 278s platform linux -- Python 3.14.2, pytest-9.0.2, pluggy-1.6.0 278s rootdir: /tmp/autopkgtest.d1RsUl/autopkgtest_tmp 278s plugins: typeguard-4.4.4 278s collected 330 items / 307 deselected / 23 selected 278s run-last-failure: rerun previous 23 failures 278s 280s services/kernels/tests/test_kernels_api.py FFFEFFFFFEF [ 39%] 281s services/sessions/tests/test_sessions_api.py FFFFFEFFFFFFFEFF [100%] 281s 281s ==================================== ERRORS ==================================== 281s _________ ERROR at teardown of KernelAPITest.test_main_kernel_handler __________ 281s 281s self = 281s 281s def tearDown(self): 281s for k in self.kern_api.list().json(): 281s > self.kern_api.shutdown(k['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/90714d6b-cc3d-4d27-afca-4c573b378d0c 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 281s from pathlib import Path 281s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 281s from ._abc import * 281s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 281s from glob import _Globber, _no_recurse_symlinks 281s File "/usr/lib/python3.13/glob.py", line 3, in 281s import contextlib 281s File "", line 1360, in _find_and_load 281s File "", line 1331, in _find_and_load_unlocked 281s File "", line 935, in _load_unlocked 281s File "", line 1019, in exec_module 281s File "", line 1152, in get_code 281s File "", line 781, in _compile_bytecode 281s KeyboardInterrupt 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp14k7eq56/runtime/kernel-90714d6b-cc3d-4d27-afca-4c573b378d0c.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:53457 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:47743 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 90714d6b-cc3d-4d27-afca-4c573b378d0c, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.700000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.890000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp14k7eq56/runtime/kernel-0b7c03bb-2ff3-45c7-8a00-75403573d69d.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:50955 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:38397 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 0b7c03bb-2ff3-45c7-8a00-75403573d69d, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.680000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.920000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: 0b7c03bb-2ff3-45c7-8a00-75403573d69d 281s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/0b7c03bb-2ff3-45c7-8a00-75403573d69d/interrupt (127.0.0.1) 1.390000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 281s yield maybe_future(km.restart_kernel(kernel_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 281s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 281s await ensure_async(kernel.restart_kernel(now=now)) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 281s await self._async_shutdown_kernel(now=now, restart=True) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/0b7c03bb-2ff3-45c7-8a00-75403573d69d/restart (127.0.0.1) 5.320000ms referer=None 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.910000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 90714d6b-cc3d-4d27-afca-4c573b378d0c 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 90714d6b-cc3d-4d27-afca-4c573b378d0c 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/90714d6b-cc3d-4d27-afca-4c573b378d0c (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/90714d6b-cc3d-4d27-afca-4c573b378d0c', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 281s yielded = ctx_run(next, result) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 281s yield maybe_future(km.shutdown_kernel(kernel_id)) 281s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 281s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 281s stopper = ensure_async(km.shutdown_kernel(now, restart)) 281s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/90714d6b-cc3d-4d27-afca-4c573b378d0c (127.0.0.1) 7.230000ms referer=None 281s --------------------------- Captured stderr teardown --------------------------- 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 281s from ipykernel import kernelapp as app 281s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 281s from .connect import * # noqa: F403 281s ^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 12, in 281s import jupyter_client 281s File "/usr/lib/python3/dist-packages/jupyter_client/__init__.py", line 4, in 281s from .asynchronous import AsyncKernelClient 281s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/__init__.py", line 1, in 281s from .client import AsyncKernelClient # noqa 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/client.py", line 9, in 281s import zmq.asyncio 281s File "/usr/lib/python3/dist-packages/zmq/__init__.py", line 57, in 281s from zmq import sugar 281s File "/usr/lib/python3/dist-packages/zmq/sugar/__init__.py", line 11, in 281s from zmq.sugar import context, frame, poll, socket, tracker, version 281s File "", line 1360, in _find_and_load 281s File "", line 1331, in _find_and_load_unlocked 281s File "", line 935, in _load_unlocked 281s File "", line 1019, in exec_module 281s File "", line 1115, in get_code 281s File "", line 1215, in get_data 281s KeyboardInterrupt 281s _______ ERROR at teardown of AsyncKernelAPITest.test_main_kernel_handler _______ 281s 281s self = 281s 281s def tearDown(self): 281s for k in self.kern_api.list().json(): 281s > self.kern_api.shutdown(k['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/5ddb028f-bfd0-4b44-9692-ac9522b88113 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 281s from pathlib import Path 281s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 281s from ._abc import * 281s File "/usr/lib/python3.13/pathlib/_abc.py", line 14, in 281s import functools 281s File "/usr/lib/python3.13/functools.py", line 455, in 281s _CacheInfo = namedtuple("CacheInfo", ["hits", "misses", "maxsize", "currsize"]) 281s File "/usr/lib/python3.13/collections/__init__.py", line 444, in namedtuple 281s __new__ = eval(code, namespace) 281s File "", line 0, in 281s KeyboardInterrupt 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpang8hqta/runtime/kernel-5ddb028f-bfd0-4b44-9692-ac9522b88113.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:56065 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:39891 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 5ddb028f-bfd0-4b44-9692-ac9522b88113, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 17.570000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.000000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpang8hqta/runtime/kernel-5e61bdda-5e90-4fb1-bc44-f011684cf504.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:43135 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:40365 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 5e61bdda-5e90-4fb1-bc44-f011684cf504, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.860000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.210000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: 5e61bdda-5e90-4fb1-bc44-f011684cf504 281s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/5e61bdda-5e90-4fb1-bc44-f011684cf504/interrupt (127.0.0.1) 1.070000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 281s yield maybe_future(km.restart_kernel(kernel_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 291, in __step_run_and_handle_result 281s result = coro.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 281s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 281s File "/usr/lib/python3.14/asyncio/futures.py", line 295, in __await__ 281s yield self # This tells Task to wait for completion. 281s ^^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 281s future.result() 281s ~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 281s await ensure_async(kernel.restart_kernel(now=now)) 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 281s await self._async_shutdown_kernel(now=now, restart=True) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/5e61bdda-5e90-4fb1-bc44-f011684cf504/restart (127.0.0.1) 3.980000ms referer=None 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.660000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 5ddb028f-bfd0-4b44-9692-ac9522b88113 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 5ddb028f-bfd0-4b44-9692-ac9522b88113 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/5ddb028f-bfd0-4b44-9692-ac9522b88113 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/5ddb028f-bfd0-4b44-9692-ac9522b88113', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 281s future.result() 281s ~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 281s yield maybe_future(km.shutdown_kernel(kernel_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 281s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 281s raise km.ready.exception() # type: ignore[misc] 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/5ddb028f-bfd0-4b44-9692-ac9522b88113 (127.0.0.1) 6.900000ms referer=None 281s --------------------------- Captured stderr teardown --------------------------- 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 281s from ipykernel import kernelapp as app 281s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 281s from .connect import * # noqa: F403 281s ^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 12, in 281s import jupyter_client 281s File "/usr/lib/python3/dist-packages/jupyter_client/__init__.py", line 4, in 281s from .asynchronous import AsyncKernelClient 281s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/__init__.py", line 1, in 281s from .client import AsyncKernelClient # noqa 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/client.py", line 9, in 281s import zmq.asyncio 281s File "/usr/lib/python3/dist-packages/zmq/__init__.py", line 57, in 281s from zmq import sugar 281s File "/usr/lib/python3/dist-packages/zmq/sugar/__init__.py", line 11, in 281s from zmq.sugar import context, frame, poll, socket, tracker, version 281s File "/usr/lib/python3/dist-packages/zmq/sugar/context.py", line 23, in 281s from .socket import Socket, SyncSocket 281s File "/usr/lib/python3/dist-packages/zmq/sugar/socket.py", line 42, in 281s _SocketType = TypeVar("_SocketType", bound="Socket") 281s File "/usr/lib/python3.13/typing.py", line 191, in _type_check 281s arg = _type_convert(arg, module=module, allow_special_forms=allow_special_forms) 281s File "/usr/lib/python3.13/typing.py", line 169, in _type_convert 281s return ForwardRef(arg, module=module, is_class=allow_special_forms) 281s File "/usr/lib/python3.13/typing.py", line 1035, in __init__ 281s code = compile(arg_to_compile, '', 'eval') 281s KeyboardInterrupt 281s ________ ERROR at teardown of SessionAPITest.test_create_with_kernel_id ________ 281s 281s @self.addCleanup 281s def cleanup_sessions(): 281s for session in self.sess_api.list().json(): 281s > self.sess_api.delete(session['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _/usr/lib/python3/dist-packages/_pytest/unraisableexception.py:33: RuntimeWarning: coroutine 'KernelManager._async_wait' was never awaited 281s gc.collect() 281s RuntimeWarning: Enable tracemalloc to get the object allocation traceback 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/97a34239-751e-468c-b0f3-81abd8151ca1 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpl25yw5qh/runtime/kernel-ab8b76e6-4722-4cb6-8e3b-0fbe390e6541.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:48067 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:60855 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: ab8b76e6-4722-4cb6-8e3b-0fbe390e6541, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.950000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.160000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.210000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.070000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 8bd50dfa-4589-46fe-94e1-3f3433ecf6bb 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 8bd50dfa-4589-46fe-94e1-3f3433ecf6bb 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/cd313de2-8c1e-4449-bc68-33dd02ee0cc2 (127.0.0.1) 2.240000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ab8b76e6-4722-4cb6-8e3b-0fbe390e6541 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ab8b76e6-4722-4cb6-8e3b-0fbe390e6541 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/97a34239-751e-468c-b0f3-81abd8151ca1 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/97a34239-751e-468c-b0f3-81abd8151ca1', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 281s yield maybe_future(sm.delete_session(session_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 281s yielded = self.gen.send(value) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 281s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 281s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 281s stopper = ensure_async(km.shutdown_kernel(now, restart)) 281s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/97a34239-751e-468c-b0f3-81abd8151ca1 (127.0.0.1) 8.470000ms referer=None 281s --------------------------- Captured stderr teardown --------------------------- 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 281s from ipykernel import kernelapp as app 281s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 281s from .connect import * # noqa: F403 281s ^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 9, in 281s from subprocess import PIPE, Popen 281s File "/usr/lib/python3.13/subprocess.py", line 51, in 281s import threading 281s File "/usr/lib/python3.13/threading.py", line 9, in 281s from _weakrefset import WeakSet 281s File "", line 1360, in _find_and_load 281s File "", line 1331, in _find_and_load_unlocked 281s File "", line 935, in _load_unlocked 281s File "", line 1019, in exec_module 281s File "", line 1152, in get_code 281s File "", line 781, in _compile_bytecode 281s KeyboardInterrupt 281s _____ ERROR at teardown of AsyncSessionAPITest.test_create_with_kernel_id ______ 281s 281s @self.addCleanup 281s def cleanup_sessions(): 281s for session in self.sess_api.list().json(): 281s > self.sess_api.delete(session['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp00uereyg/runtime/kernel-c2da70f4-ba91-4096-ae7d-13fc94e40f07.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:54729 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:59069 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: c2da70f4-ba91-4096-ae7d-13fc94e40f07, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.000000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.190000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.040000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.050000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 08d93347-6789-4cad-813d-fb5e0c3d1e45 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 08d93347-6789-4cad-813d-fb5e0c3d1e45 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/81209eaf-5cf5-4a40-9278-01a0265a9c38 (127.0.0.1) 1.240000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for c2da70f4-ba91-4096-ae7d-13fc94e40f07 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c2da70f4-ba91-4096-ae7d-13fc94e40f07 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 281s future.result() 281s ~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 281s yield maybe_future(sm.delete_session(session_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 281s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 281s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 281s raise km.ready.exception() # type: ignore[misc] 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2 (127.0.0.1) 7.590000ms referer=None 281s --------------------------- Captured stderr teardown --------------------------- 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 281s from ipykernel import kernelapp as app 281s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 281s from .connect import * # noqa: F403 281s ^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 9, in 281s from subprocess import PIPE, Popen 281s File "/usr/lib/python3.13/subprocess.py", line 46, in 281s import locale 281s File "/usr/lib/python3.13/locale.py", line 180, in 281s _percent_re = re.compile(r'%(?:\((?P.*?)\))?' 281s r'(?P[-#0-9 +*.hlL]*?)[eEfFgGdiouxXcrs%]') 281s File "/usr/lib/python3.13/re/__init__.py", line 289, in compile 281s return _compile(pattern, flags) 281s File "/usr/lib/python3.13/re/__init__.py", line 350, in _compile 281s p = _compiler.compile(pattern, flags) 281s File "/usr/lib/python3.13/re/_compiler.py", line 748, in compile 281s p = _parser.parse(p, flags) 281s File "/usr/lib/python3.13/re/_parser.py", line 980, in parse 281s p = _parse_sub(source, state, flags & SRE_FLAG_VERBOSE, 0) 281s File "/usr/lib/python3.13/re/_parser.py", line 459, in _parse_sub 281s itemsappend(_parse(source, state, verbose, nested + 1, 281s ~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s not nested and not items)) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3.13/re/_parser.py", line 863, in _parse 281s p = _parse_sub(source, state, sub_verbose, nested + 1) 281s File "/usr/lib/python3.13/re/_parser.py", line 459, in _parse_sub 281s itemsappend(_parse(source, state, verbose, nested + 1, 281s ~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s not nested and not items)) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3.13/re/_parser.py", line 856, in _parse 281s group = state.opengroup(name) 281s File "/usr/lib/python3.13/re/_parser.py", line 85, in opengroup 281s def opengroup(self, name=None): 281s 281s KeyboardInterrupt 281s =================================== FAILURES =================================== 281s ______________________ KernelAPITest.test_default_kernel _______________________ 281s 281s self = 281s 281s def tearDown(self): 281s for k in self.kern_api.list().json(): 281s > self.kern_api.shutdown(k['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/c1f4987a-b9bb-43f0-9146-f0c91492380b 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ------------------------------ Captured log setup ------------------------------ 281s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmp14k7eq56/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmp14k7eq56/etc/jupyter'] for config files 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmp14k7eq56/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmp14k7eq56/config 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmp14k7eq56/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmp14k7eq56/config 281s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmp14k7eq56/notebooks 281s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 281s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 281s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 281s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 281s WARNING NotebookApp:handlers.py:612 Forbidden 281s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 1.370000ms referer=None 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp14k7eq56/runtime/kernel-c1f4987a-b9bb-43f0-9146-f0c91492380b.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:56007 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:42737 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: c1f4987a-b9bb-43f0-9146-f0c91492380b, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 64.140000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.250000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for c1f4987a-b9bb-43f0-9146-f0c91492380b 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c1f4987a-b9bb-43f0-9146-f0c91492380b 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/c1f4987a-b9bb-43f0-9146-f0c91492380b (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/c1f4987a-b9bb-43f0-9146-f0c91492380b', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 281s yielded = ctx_run(next, result) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 281s yield maybe_future(km.shutdown_kernel(kernel_id)) 281s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 281s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 281s stopper = ensure_async(km.shutdown_kernel(now, restart)) 281s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/c1f4987a-b9bb-43f0-9146-f0c91492380b (127.0.0.1) 10.950000ms referer=None 281s --------------------------- Captured stderr teardown --------------------------- 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 281s from pathlib import Path 281s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 281s from ._abc import * 281s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 281s from glob import _Globber, _no_recurse_symlinks 281s File "/usr/lib/python3.13/glob.py", line 5, in 281s import re 281s File "/usr/lib/python3.13/re/__init__.py", line 126, in 281s from . import _compiler, _parser 281s File "", line 1357, in _find_and_load 281s File "", line 418, in __enter__ 281s File "", line 316, in acquire 281s KeyboardInterrupt 281s ______________________ KernelAPITest.test_kernel_handler _______________________ 281s 281s self = 281s 281s def test_kernel_handler(self): 281s # GET kernel with given id 281s kid = self.kern_api.start().json()['id'] 281s r = self.kern_api.get(kid) 281s kern1 = r.json() 281s self.assertEqual(r.status_code, 200) 281s assert isinstance(kern1, dict) 281s self.assertIn('id', kern1) 281s self.assertEqual(kern1['id'], kid) 281s 281s # Request a bad kernel id and check that a JSON 281s # message is returned! 281s bad_id = '111-111-111-111-111' 281s with assert_http_error(404, 'Kernel does not exist: ' + bad_id): 281s self.kern_api.get(bad_id) 281s 281s # DELETE kernel with id 281s > r = self.kern_api.shutdown(kid) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:169: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/14b5f040-6a27-416a-8da5-f40a136c07d6 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 281s from pathlib import Path 281s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 281s from ._abc import * 281s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 281s from glob import _Globber, _no_recurse_symlinks 281s File "/usr/lib/python3.13/glob.py", line 533, in 281s class _StringGlobber(_Globber): 281s ...<17 lines>... 281s return f'{pathname}/' 281s KeyboardInterrupt 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp14k7eq56/runtime/kernel-14b5f040-6a27-416a-8da5-f40a136c07d6.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:57773 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:45753 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 14b5f040-6a27-416a-8da5-f40a136c07d6, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 17.480000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/14b5f040-6a27-416a-8da5-f40a136c07d6 (127.0.0.1) 0.980000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s WARNING NotebookApp:web.py:1943 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1): Kernel does not exist: 111-111-111-111-111 281s WARNING NotebookApp:handlers.py:612 Kernel does not exist: 111-111-111-111-111 281s WARNING NotebookApp:log.py:59 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1) 1.040000ms referer=None 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 14b5f040-6a27-416a-8da5-f40a136c07d6 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 14b5f040-6a27-416a-8da5-f40a136c07d6 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/14b5f040-6a27-416a-8da5-f40a136c07d6 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/14b5f040-6a27-416a-8da5-f40a136c07d6', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 281s yielded = ctx_run(next, result) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 281s yield maybe_future(km.shutdown_kernel(kernel_id)) 281s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 281s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 281s stopper = ensure_async(km.shutdown_kernel(now, restart)) 281s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/14b5f040-6a27-416a-8da5-f40a136c07d6 (127.0.0.1) 7.790000ms referer=None 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.180000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for c1f4987a-b9bb-43f0-9146-f0c91492380b 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c1f4987a-b9bb-43f0-9146-f0c91492380b 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/c1f4987a-b9bb-43f0-9146-f0c91492380b (127.0.0.1) 1.480000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 14b5f040-6a27-416a-8da5-f40a136c07d6 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 14b5f040-6a27-416a-8da5-f40a136c07d6 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/14b5f040-6a27-416a-8da5-f40a136c07d6 (127.0.0.1) 1.380000ms 281s ____________________ KernelAPITest.test_main_kernel_handler ____________________ 281s 281s self = 281s 281s def test_main_kernel_handler(self): 281s # POST request 281s r = self.kern_api.start() 281s kern1 = r.json() 281s self.assertEqual(r.headers['location'], url_path_join(self.url_prefix, 'api/kernels', kern1['id'])) 281s self.assertEqual(r.status_code, 201) 281s self.assertIsInstance(kern1, dict) 281s 281s report_uri = url_path_join(self.url_prefix, 'api/security/csp-report') 281s expected_csp = '; '.join([ 281s "frame-ancestors 'self'", 281s 'report-uri ' + report_uri, 281s "default-src 'none'" 281s ]) 281s self.assertEqual(r.headers['Content-Security-Policy'], expected_csp) 281s 281s # GET request 281s r = self.kern_api.list() 281s self.assertEqual(r.status_code, 200) 281s assert isinstance(r.json(), list) 281s self.assertEqual(r.json()[0]['id'], kern1['id']) 281s self.assertEqual(r.json()[0]['name'], kern1['name']) 281s 281s # create another kernel and check that they both are added to the 281s # list of kernels from a GET request 281s kern2 = self.kern_api.start().json() 281s assert isinstance(kern2, dict) 281s r = self.kern_api.list() 281s kernels = r.json() 281s self.assertEqual(r.status_code, 200) 281s assert isinstance(kernels, list) 281s self.assertEqual(len(kernels), 2) 281s 281s # Interrupt a kernel 281s r = self.kern_api.interrupt(kern2['id']) 281s self.assertEqual(r.status_code, 204) 281s 281s # Restart a kernel 281s > r = self.kern_api.restart(kern2['id']) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:147: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:63: in restart 281s return self._req('POST', url_path_join(id, 'restart')) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: http://localhost:12341/a%40b/api/kernels/0b7c03bb-2ff3-45c7-8a00-75403573d69d/restart 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 281s from pathlib import Path 281s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 281s from ._abc import * 281s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 281s from glob import _Globber, _no_recurse_symlinks 281s File "/usr/lib/python3.13/glob.py", line 3, in 281s import contextlib 281s File "", line 1360, in _find_and_load 281s File "", line 1331, in _find_and_load_unlocked 281s File "", line 935, in _load_unlocked 281s File "", line 1019, in exec_module 281s File "", line 1152, in get_code 281s File "", line 781, in _compile_bytecode 281s KeyboardInterrupt 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp14k7eq56/runtime/kernel-90714d6b-cc3d-4d27-afca-4c573b378d0c.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:53457 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:47743 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 90714d6b-cc3d-4d27-afca-4c573b378d0c, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.700000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.890000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp14k7eq56/runtime/kernel-0b7c03bb-2ff3-45c7-8a00-75403573d69d.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:50955 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:38397 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 0b7c03bb-2ff3-45c7-8a00-75403573d69d, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.680000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.920000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: 0b7c03bb-2ff3-45c7-8a00-75403573d69d 281s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/0b7c03bb-2ff3-45c7-8a00-75403573d69d/interrupt (127.0.0.1) 1.390000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 281s yield maybe_future(km.restart_kernel(kernel_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 281s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 281s await ensure_async(kernel.restart_kernel(now=now)) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 281s await self._async_shutdown_kernel(now=now, restart=True) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/0b7c03bb-2ff3-45c7-8a00-75403573d69d/restart (127.0.0.1) 5.320000ms referer=None 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.910000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 90714d6b-cc3d-4d27-afca-4c573b378d0c 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 90714d6b-cc3d-4d27-afca-4c573b378d0c 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/90714d6b-cc3d-4d27-afca-4c573b378d0c (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/90714d6b-cc3d-4d27-afca-4c573b378d0c', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 281s yielded = ctx_run(next, result) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 281s yield maybe_future(km.shutdown_kernel(kernel_id)) 281s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 281s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 281s stopper = ensure_async(km.shutdown_kernel(now, restart)) 281s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/90714d6b-cc3d-4d27-afca-4c573b378d0c (127.0.0.1) 7.230000ms referer=None 281s ________________________ KernelAPITest.test_no_kernels _________________________ 281s 281s self = 281s 281s def test_no_kernels(self): 281s """Make sure there are no kernels running at the start""" 281s kernels = self.kern_api.list().json() 281s > self.assertEqual(kernels, []) 281s E AssertionError: Lists differ: [{'id': '90714d6b-cc3d-4d27-afca-4c573b378[281 chars]: 0}] != [] 281s E 281s E First list contains 2 additional elements. 281s E First extra element 0: 281s E {'id': '90714d6b-cc3d-4d27-afca-4c573b378d0c', 'name': 'python3', 'last_activity': '2026-02-06T04:19:11.826248Z', 'execution_state': 'starting', 'connections': 0} 281s E 281s E + [] 281s E - [{'connections': 0, 281s E - 'execution_state': 'starting', 281s E - 'id': '90714d6b-cc3d-4d27-afca-4c573b378d0c', 281s E - 'last_activity': '2026-02-06T04:19:11.826248Z', 281s E - 'name': 'python3'}, 281s E - {'connections': 0, 281s E - 'execution_state': 'starting', 281s E - 'id': '0b7c03bb-2ff3-45c7-8a00-75403573d69d', 281s E - 'last_activity': '2026-02-06T04:19:11.849201Z', 281s E - 'name': 'python3'}] 281s 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:91: AssertionError 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.130000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.920000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 90714d6b-cc3d-4d27-afca-4c573b378d0c 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 90714d6b-cc3d-4d27-afca-4c573b378d0c 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/90714d6b-cc3d-4d27-afca-4c573b378d0c (127.0.0.1) 1.430000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 0b7c03bb-2ff3-45c7-8a00-75403573d69d 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0b7c03bb-2ff3-45c7-8a00-75403573d69d 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/0b7c03bb-2ff3-45c7-8a00-75403573d69d (127.0.0.1) 1.570000ms 281s ---------------------------- Captured log teardown ----------------------------- 281s INFO NotebookApp:notebookapp.py:2164 Shutting down 0 kernels 281s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 281s _____________________ AsyncKernelAPITest.test_connections ______________________ 281s 281s self = 281s 281s def tearDown(self): 281s for k in self.kern_api.list().json(): 281s > self.kern_api.shutdown(k['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/0366e71a-5593-45fc-96f8-5fb318c21ff6 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ------------------------------ Captured log setup ------------------------------ 281s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmpang8hqta/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmpang8hqta/etc/jupyter'] for config files 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpang8hqta/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpang8hqta/config 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpang8hqta/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpang8hqta/config 281s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmpang8hqta/notebooks 281s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 281s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 281s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 281s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 281s WARNING NotebookApp:handlers.py:612 Forbidden 281s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 0.730000ms referer=None 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpang8hqta/runtime/kernel-0366e71a-5593-45fc-96f8-5fb318c21ff6.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:44991 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:56501 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 0366e71a-5593-45fc-96f8-5fb318c21ff6, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.840000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/0366e71a-5593-45fc-96f8-5fb318c21ff6 (127.0.0.1) 0.920000ms 281s DEBUG NotebookApp:zmqhandlers.py:298 Initializing websocket connection /a%40b/api/kernels/0366e71a-5593-45fc-96f8-5fb318c21ff6/channels 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s WARNING NotebookApp:zmqhandlers.py:286 No session ID specified 281s DEBUG NotebookApp:handlers.py:277 Requesting kernel info from 0366e71a-5593-45fc-96f8-5fb318c21ff6 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55885 281s DEBUG NotebookApp:kernelmanager.py:423 activity on 0366e71a-5593-45fc-96f8-5fb318c21ff6: status (starting) 281s DEBUG NotebookApp:kernelmanager.py:423 activity on 0366e71a-5593-45fc-96f8-5fb318c21ff6: status (busy) 281s DEBUG NotebookApp:handlers.py:306 Received kernel info: {'status': 'ok', 'protocol_version': '5.3', 'implementation': 'ipython', 'implementation_version': '8.35.0', 'language_info': {'name': 'python', 'version': '3.13.11', 'mimetype': 'text/x-python', 'codemirror_mode': {'name': 'ipython', 'version': 3}, 'pygments_lexer': 'ipython3', 'nbconvert_exporter': 'python', 'file_extension': '.py'}, 'banner': "Python 3.13.11 (main, Dec 6 2025, 13:15:20) [GCC 15.2.0]\nType 'copyright', 'credits' or 'license' for more information\nIPython 8.35.0 -- An enhanced Interactive Python. Type '?' for help.\n", 'help_links': [{'text': 'Python Reference', 'url': 'https://docs.python.org/3.13'}, {'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/'}]} 281s INFO NotebookApp:handlers.py:326 Adapting from protocol version 5.3 (kernel 0366e71a-5593-45fc-96f8-5fb318c21ff6) to 5.4 (client). 281s DEBUG NotebookApp:log.py:59 101 GET /a%40b/api/kernels/0366e71a-5593-45fc-96f8-5fb318c21ff6/channels (127.0.0.1) 690.590000ms 281s DEBUG NotebookApp:zmqhandlers.py:159 Opening websocket /a%40b/api/kernels/0366e71a-5593-45fc-96f8-5fb318c21ff6/channels 281s DEBUG NotebookApp:kernelmanager.py:252 Getting buffer for 0366e71a-5593-45fc-96f8-5fb318c21ff6 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:56501 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55885 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:44991 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:33369 281s DEBUG NotebookApp:handlers.py:156 Nudge: not nudging busy kernel 0366e71a-5593-45fc-96f8-5fb318c21ff6 281s WARNING NotebookApp:websocket.py:1327 The websocket_ping_timeout (90000) cannot be longer than the websocket_ping_interval (30000). 281s Setting websocket_ping_timeout=30000 281s DEBUG NotebookApp:kernelmanager.py:423 activity on 0366e71a-5593-45fc-96f8-5fb318c21ff6: status (idle) 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/0366e71a-5593-45fc-96f8-5fb318c21ff6 (127.0.0.1) 1.230000ms 281s DEBUG NotebookApp:handlers.py:579 Websocket closed 0366e71a-5593-45fc-96f8-5fb318c21ff6:99a6ecfd-f962492ac87dd0157e58f0ce 281s INFO NotebookApp:kernelmanager.py:222 Starting buffering for 0366e71a-5593-45fc-96f8-5fb318c21ff6:99a6ecfd-f962492ac87dd0157e58f0ce 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 0366e71a-5593-45fc-96f8-5fb318c21ff6 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/0366e71a-5593-45fc-96f8-5fb318c21ff6 (127.0.0.1) 1.170000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/0366e71a-5593-45fc-96f8-5fb318c21ff6 (127.0.0.1) 1.000000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.900000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 0366e71a-5593-45fc-96f8-5fb318c21ff6 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0366e71a-5593-45fc-96f8-5fb318c21ff6 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/0366e71a-5593-45fc-96f8-5fb318c21ff6 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/0366e71a-5593-45fc-96f8-5fb318c21ff6', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 281s future.result() 281s ~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 281s yield maybe_future(km.shutdown_kernel(kernel_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 281s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 281s raise km.ready.exception() # type: ignore[misc] 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/0366e71a-5593-45fc-96f8-5fb318c21ff6 (127.0.0.1) 9.080000ms referer=None 281s ____________________ AsyncKernelAPITest.test_default_kernel ____________________ 281s 281s self = 281s 281s def tearDown(self): 281s for k in self.kern_api.list().json(): 281s > self.kern_api.shutdown(k['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/0724917d-02c0-4331-90c1-54bfe0670247 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpang8hqta/runtime/kernel-0724917d-02c0-4331-90c1-54bfe0670247.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:33331 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:40035 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 0724917d-02c0-4331-90c1-54bfe0670247, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.740000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.020000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 0366e71a-5593-45fc-96f8-5fb318c21ff6 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0366e71a-5593-45fc-96f8-5fb318c21ff6 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/0366e71a-5593-45fc-96f8-5fb318c21ff6 (127.0.0.1) 1.190000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 0724917d-02c0-4331-90c1-54bfe0670247 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0724917d-02c0-4331-90c1-54bfe0670247 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/0724917d-02c0-4331-90c1-54bfe0670247 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/0724917d-02c0-4331-90c1-54bfe0670247', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 281s future.result() 281s ~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 281s yield maybe_future(km.shutdown_kernel(kernel_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 281s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 281s raise km.ready.exception() # type: ignore[misc] 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/0724917d-02c0-4331-90c1-54bfe0670247 (127.0.0.1) 7.370000ms referer=None 281s --------------------------- Captured stderr teardown --------------------------- 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 281s from pathlib import Path 281s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 281s from ._local import * 281s File "", line 1360, in _find_and_load 281s File "", line 1331, in _find_and_load_unlocked 281s File "", line 935, in _load_unlocked 281s File "", line 1019, in exec_module 281s File "", line 1115, in get_code 281s File "", line 1214, in get_data 281s KeyboardInterrupt 281s ____________________ AsyncKernelAPITest.test_kernel_handler ____________________ 281s 281s self = 281s 281s def test_kernel_handler(self): 281s # GET kernel with given id 281s kid = self.kern_api.start().json()['id'] 281s r = self.kern_api.get(kid) 281s kern1 = r.json() 281s self.assertEqual(r.status_code, 200) 281s assert isinstance(kern1, dict) 281s self.assertIn('id', kern1) 281s self.assertEqual(kern1['id'], kid) 281s 281s # Request a bad kernel id and check that a JSON 281s # message is returned! 281s bad_id = '111-111-111-111-111' 281s with assert_http_error(404, 'Kernel does not exist: ' + bad_id): 281s self.kern_api.get(bad_id) 281s 281s # DELETE kernel with id 281s > r = self.kern_api.shutdown(kid) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:169: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/dc29c82c-fcd2-4591-8e1e-f2a7fba1d802 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 281s from pathlib import Path 281s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 281s from ._abc import * 281s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 281s from glob import _Globber, _no_recurse_symlinks 281s File "/usr/lib/python3.13/glob.py", line 5, in 281s import re 281s File "/usr/lib/python3.13/re/__init__.py", line 126, in 281s from . import _compiler, _parser 281s File "/usr/lib/python3.13/re/_compiler.py", line 14, in 281s from . import _parser 281s File "/usr/lib/python3.13/re/_parser.py", line 15, in 281s from ._constants import * 281s File "/usr/lib/python3.13/re/_constants.py", line 130, in 281s ATCODES = _makecodes( 281s 'AT_BEGINNING', 'AT_BEGINNING_LINE', 'AT_BEGINNING_STRING', 281s ...<5 lines>... 281s 'AT_UNI_BOUNDARY', 'AT_UNI_NON_BOUNDARY', 281s ) 281s File "/usr/lib/python3.13/re/_constants.py", line 73, in _makecodes 281s items = [_NamedIntConstant(i, name) for i, name in enumerate(names)] 281s ~~~~~~~~~~~~~~~~~^^^^^^^^^ 281s KeyboardInterrupt 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpang8hqta/runtime/kernel-dc29c82c-fcd2-4591-8e1e-f2a7fba1d802.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:42493 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:51881 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: dc29c82c-fcd2-4591-8e1e-f2a7fba1d802, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.660000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/dc29c82c-fcd2-4591-8e1e-f2a7fba1d802 (127.0.0.1) 0.970000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s WARNING NotebookApp:web.py:1943 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1): Kernel does not exist: 111-111-111-111-111 281s WARNING NotebookApp:handlers.py:612 Kernel does not exist: 111-111-111-111-111 281s WARNING NotebookApp:log.py:59 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1) 1.090000ms referer=None 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for dc29c82c-fcd2-4591-8e1e-f2a7fba1d802 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: dc29c82c-fcd2-4591-8e1e-f2a7fba1d802 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/dc29c82c-fcd2-4591-8e1e-f2a7fba1d802 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/dc29c82c-fcd2-4591-8e1e-f2a7fba1d802', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 281s future.result() 281s ~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 281s yield maybe_future(km.shutdown_kernel(kernel_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 281s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 281s raise km.ready.exception() # type: ignore[misc] 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/dc29c82c-fcd2-4591-8e1e-f2a7fba1d802 (127.0.0.1) 7.210000ms referer=None 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.990000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 0724917d-02c0-4331-90c1-54bfe0670247 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0724917d-02c0-4331-90c1-54bfe0670247 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/0724917d-02c0-4331-90c1-54bfe0670247 (127.0.0.1) 1.140000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for dc29c82c-fcd2-4591-8e1e-f2a7fba1d802 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: dc29c82c-fcd2-4591-8e1e-f2a7fba1d802 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/dc29c82c-fcd2-4591-8e1e-f2a7fba1d802 (127.0.0.1) 1.080000ms 281s _________________ AsyncKernelAPITest.test_main_kernel_handler __________________ 281s 281s self = 281s 281s def test_main_kernel_handler(self): 281s # POST request 281s r = self.kern_api.start() 281s kern1 = r.json() 281s self.assertEqual(r.headers['location'], url_path_join(self.url_prefix, 'api/kernels', kern1['id'])) 281s self.assertEqual(r.status_code, 201) 281s self.assertIsInstance(kern1, dict) 281s 281s report_uri = url_path_join(self.url_prefix, 'api/security/csp-report') 281s expected_csp = '; '.join([ 281s "frame-ancestors 'self'", 281s 'report-uri ' + report_uri, 281s "default-src 'none'" 281s ]) 281s self.assertEqual(r.headers['Content-Security-Policy'], expected_csp) 281s 281s # GET request 281s r = self.kern_api.list() 281s self.assertEqual(r.status_code, 200) 281s assert isinstance(r.json(), list) 281s self.assertEqual(r.json()[0]['id'], kern1['id']) 281s self.assertEqual(r.json()[0]['name'], kern1['name']) 281s 281s # create another kernel and check that they both are added to the 281s # list of kernels from a GET request 281s kern2 = self.kern_api.start().json() 281s assert isinstance(kern2, dict) 281s r = self.kern_api.list() 281s kernels = r.json() 281s self.assertEqual(r.status_code, 200) 281s assert isinstance(kernels, list) 281s self.assertEqual(len(kernels), 2) 281s 281s # Interrupt a kernel 281s r = self.kern_api.interrupt(kern2['id']) 281s self.assertEqual(r.status_code, 204) 281s 281s # Restart a kernel 281s > r = self.kern_api.restart(kern2['id']) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:147: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:63: in restart 281s return self._req('POST', url_path_join(id, 'restart')) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: http://localhost:12341/a%40b/api/kernels/5e61bdda-5e90-4fb1-bc44-f011684cf504/restart 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 281s from pathlib import Path 281s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 281s from ._abc import * 281s File "/usr/lib/python3.13/pathlib/_abc.py", line 14, in 281s import functools 281s File "/usr/lib/python3.13/functools.py", line 455, in 281s _CacheInfo = namedtuple("CacheInfo", ["hits", "misses", "maxsize", "currsize"]) 281s File "/usr/lib/python3.13/collections/__init__.py", line 444, in namedtuple 281s __new__ = eval(code, namespace) 281s File "", line 0, in 281s KeyboardInterrupt 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpang8hqta/runtime/kernel-5ddb028f-bfd0-4b44-9692-ac9522b88113.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:56065 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:39891 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 5ddb028f-bfd0-4b44-9692-ac9522b88113, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 17.570000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.000000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpang8hqta/runtime/kernel-5e61bdda-5e90-4fb1-bc44-f011684cf504.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:43135 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:40365 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 5e61bdda-5e90-4fb1-bc44-f011684cf504, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.860000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.210000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: 5e61bdda-5e90-4fb1-bc44-f011684cf504 281s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/5e61bdda-5e90-4fb1-bc44-f011684cf504/interrupt (127.0.0.1) 1.070000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 281s yield maybe_future(km.restart_kernel(kernel_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 291, in __step_run_and_handle_result 281s result = coro.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 281s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 281s File "/usr/lib/python3.14/asyncio/futures.py", line 295, in __await__ 281s yield self # This tells Task to wait for completion. 281s ^^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 281s future.result() 281s ~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 281s await ensure_async(kernel.restart_kernel(now=now)) 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 281s await self._async_shutdown_kernel(now=now, restart=True) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/5e61bdda-5e90-4fb1-bc44-f011684cf504/restart (127.0.0.1) 3.980000ms referer=None 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.660000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 5ddb028f-bfd0-4b44-9692-ac9522b88113 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 5ddb028f-bfd0-4b44-9692-ac9522b88113 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/5ddb028f-bfd0-4b44-9692-ac9522b88113 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/5ddb028f-bfd0-4b44-9692-ac9522b88113', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 281s future.result() 281s ~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 281s yield maybe_future(km.shutdown_kernel(kernel_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 281s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 281s raise km.ready.exception() # type: ignore[misc] 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/5ddb028f-bfd0-4b44-9692-ac9522b88113 (127.0.0.1) 6.900000ms referer=None 281s ______________________ AsyncKernelAPITest.test_no_kernels ______________________ 281s 281s self = 281s 281s def test_no_kernels(self): 281s """Make sure there are no kernels running at the start""" 281s kernels = self.kern_api.list().json() 281s > self.assertEqual(kernels, []) 281s E AssertionError: Lists differ: [{'id': '5ddb028f-bfd0-4b44-9692-ac9522b88[281 chars]: 0}] != [] 281s E 281s E First list contains 2 additional elements. 281s E First extra element 0: 281s E {'id': '5ddb028f-bfd0-4b44-9692-ac9522b88113', 'name': 'python3', 'last_activity': '2026-02-06T04:19:12.953491Z', 'execution_state': 'starting', 'connections': 0} 281s E 281s E + [] 281s E - [{'connections': 0, 281s E - 'execution_state': 'starting', 281s E - 'id': '5ddb028f-bfd0-4b44-9692-ac9522b88113', 281s E - 'last_activity': '2026-02-06T04:19:12.953491Z', 281s E - 'name': 'python3'}, 281s E - {'connections': 0, 281s E - 'execution_state': 'starting', 281s E - 'id': '5e61bdda-5e90-4fb1-bc44-f011684cf504', 281s E - 'last_activity': '2026-02-06T04:19:12.977807Z', 281s E - 'name': 'python3'}] 281s 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:91: AssertionError 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.010000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.910000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 5ddb028f-bfd0-4b44-9692-ac9522b88113 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 5ddb028f-bfd0-4b44-9692-ac9522b88113 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/5ddb028f-bfd0-4b44-9692-ac9522b88113 (127.0.0.1) 1.090000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 5e61bdda-5e90-4fb1-bc44-f011684cf504 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 5e61bdda-5e90-4fb1-bc44-f011684cf504 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/5e61bdda-5e90-4fb1-bc44-f011684cf504 (127.0.0.1) 1.190000ms 281s ---------------------------- Captured log teardown ----------------------------- 281s INFO NotebookApp:notebookapp.py:2164 Shutting down 0 kernels 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0724917d-02c0-4331-90c1-54bfe0670247 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 5ddb028f-bfd0-4b44-9692-ac9522b88113 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0366e71a-5593-45fc-96f8-5fb318c21ff6 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: dc29c82c-fcd2-4591-8e1e-f2a7fba1d802 281s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 281s __________________________ SessionAPITest.test_create __________________________ 281s 281s @self.addCleanup 281s def cleanup_sessions(): 281s for session in self.sess_api.list().json(): 281s > self.sess_api.delete(session['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/9602443d-c32a-4df9-82fe-8d156416d99b 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ------------------------------ Captured log setup ------------------------------ 281s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmpl25yw5qh/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmpl25yw5qh/etc/jupyter'] for config files 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpl25yw5qh/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpl25yw5qh/config 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpl25yw5qh/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpl25yw5qh/config 281s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmpl25yw5qh/notebooks 281s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 281s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 281s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 281s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 281s WARNING NotebookApp:handlers.py:612 Forbidden 281s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 0.700000ms referer=None 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 281s from ipykernel import kernelapp as app 281s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 281s from .connect import * # noqa: F403 281s ^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 9, in 281s from subprocess import PIPE, Popen 281s File "", line 1360, in _find_and_load 281s File "", line 1331, in _find_and_load_unlocked 281s File "", line 935, in _load_unlocked 281s File "", line 1019, in exec_module 281s File "", line 1152, in get_code 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.430000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpl25yw5qh/runtime/kernel-2346e923-a75e-46e5-8cd9-cc1165febf84.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:35701 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:45625 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 2346e923-a75e-46e5-8cd9-cc1165febf84, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpl25yw5qh/notebooks/foo'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 22.410000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.060000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions/9602443d-c32a-4df9-82fe-8d156416d99b (127.0.0.1) 1.110000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.040000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 2346e923-a75e-46e5-8cd9-cc1165febf84 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 2346e923-a75e-46e5-8cd9-cc1165febf84 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/9602443d-c32a-4df9-82fe-8d156416d99b (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/9602443d-c32a-4df9-82fe-8d156416d99b', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 281s yield maybe_future(sm.delete_session(session_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 281s yielded = self.gen.send(value) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 281s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 281s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 281s stopper = ensure_async(km.shutdown_kernel(now, restart)) 281s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/9602443d-c32a-4df9-82fe-8d156416d99b (127.0.0.1) 9.030000ms referer=None 281s --------------------------- Captured stderr teardown --------------------------- 281s KeyboardInterrupt 281s __________________ SessionAPITest.test_create_console_session __________________ 281s 281s @self.addCleanup 281s def cleanup_sessions(): 281s for session in self.sess_api.list().json(): 281s > self.sess_api.delete(session['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/cb537be8-b106-484b-a1af-9d4e1f7f0626 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpl25yw5qh/runtime/kernel-b20d75cf-7fc9-46ae-9dbc-fa820fc18f4d.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:49579 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:54571 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: b20d75cf-7fc9-46ae-9dbc-fa820fc18f4d, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpl25yw5qh/notebooks/foo'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 17.580000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.070000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 2346e923-a75e-46e5-8cd9-cc1165febf84 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 2346e923-a75e-46e5-8cd9-cc1165febf84 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/9602443d-c32a-4df9-82fe-8d156416d99b (127.0.0.1) 1.610000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for b20d75cf-7fc9-46ae-9dbc-fa820fc18f4d 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: b20d75cf-7fc9-46ae-9dbc-fa820fc18f4d 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/cb537be8-b106-484b-a1af-9d4e1f7f0626 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/cb537be8-b106-484b-a1af-9d4e1f7f0626', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 281s yield maybe_future(sm.delete_session(session_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 281s yielded = self.gen.send(value) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 281s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 281s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 281s stopper = ensure_async(km.shutdown_kernel(now, restart)) 281s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/cb537be8-b106-484b-a1af-9d4e1f7f0626 (127.0.0.1) 8.820000ms referer=None 281s --------------------------- Captured stderr teardown --------------------------- 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 281s from pathlib import Path 281s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 281s from ._local import * 281s File "", line 1357, in _find_and_load 281s File "", line 418, in __enter__ 281s File "", line 311, in acquire 281s File "", line 170, in __enter__ 281s File "", line 132, in setdefault 281s File "", line 74, in __new__ 281s KeyboardInterrupt 281s ____________________ SessionAPITest.test_create_deprecated _____________________ 281s 281s @self.addCleanup 281s def cleanup_sessions(): 281s for session in self.sess_api.list().json(): 281s > self.sess_api.delete(session['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/1f08af18-55da-41e7-85d1-826ffdd5b8fc 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s WARNING NotebookApp:handlers.py:46 Sessions API changed, see updated swagger docs 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpl25yw5qh/runtime/kernel-efe5e807-148d-43a5-b634-ac5d32ec23c0.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:53019 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34873 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: efe5e807-148d-43a5-b634-ac5d32ec23c0, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpl25yw5qh/notebooks/foo'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 18.290000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.120000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for b20d75cf-7fc9-46ae-9dbc-fa820fc18f4d 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: b20d75cf-7fc9-46ae-9dbc-fa820fc18f4d 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/cb537be8-b106-484b-a1af-9d4e1f7f0626 (127.0.0.1) 1.590000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for efe5e807-148d-43a5-b634-ac5d32ec23c0 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: efe5e807-148d-43a5-b634-ac5d32ec23c0 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/1f08af18-55da-41e7-85d1-826ffdd5b8fc (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/1f08af18-55da-41e7-85d1-826ffdd5b8fc', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 281s yield maybe_future(sm.delete_session(session_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 281s yielded = self.gen.send(value) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 281s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 281s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 281s stopper = ensure_async(km.shutdown_kernel(now, restart)) 281s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/1f08af18-55da-41e7-85d1-826ffdd5b8fc (127.0.0.1) 8.480000ms referer=None 281s --------------------------- Captured stderr teardown --------------------------- 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 281s from pathlib import Path 281s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 281s from ._local import * 281s File "/usr/lib/python3.13/pathlib/_local.py", line 6, in 281s import warnings 281s File "/usr/lib/python3.13/warnings.py", line 420, in 281s class WarningMessage(object): 281s ...<18 lines>... 281s self.filename, self.lineno, self.line)) 281s KeyboardInterrupt 281s ___________________ SessionAPITest.test_create_file_session ____________________ 281s 281s @self.addCleanup 281s def cleanup_sessions(): 281s for session in self.sess_api.list().json(): 281s > self.sess_api.delete(session['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/cd313de2-8c1e-4449-bc68-33dd02ee0cc2 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpl25yw5qh/runtime/kernel-8bd50dfa-4589-46fe-94e1-3f3433ecf6bb.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:60465 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:44697 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 8bd50dfa-4589-46fe-94e1-3f3433ecf6bb, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpl25yw5qh/notebooks/foo'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 17.920000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.050000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for efe5e807-148d-43a5-b634-ac5d32ec23c0 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: efe5e807-148d-43a5-b634-ac5d32ec23c0 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/1f08af18-55da-41e7-85d1-826ffdd5b8fc (127.0.0.1) 1.730000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 8bd50dfa-4589-46fe-94e1-3f3433ecf6bb 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 8bd50dfa-4589-46fe-94e1-3f3433ecf6bb 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/cd313de2-8c1e-4449-bc68-33dd02ee0cc2 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/cd313de2-8c1e-4449-bc68-33dd02ee0cc2', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 281s yield maybe_future(sm.delete_session(session_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 281s yielded = self.gen.send(value) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 281s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 281s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 281s stopper = ensure_async(km.shutdown_kernel(now, restart)) 281s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/cd313de2-8c1e-4449-bc68-33dd02ee0cc2 (127.0.0.1) 8.960000ms referer=None 281s --------------------------- Captured stderr teardown --------------------------- 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 281s from pathlib import Path 281s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 281s from ._local import * 281s File "", line 1357, in _find_and_load 281s File "", line 418, in __enter__ 281s File "", line 311, in acquire 281s File "", line 170, in __enter__ 281s File "", line 132, in setdefault 281s File "", line 74, in __new__ 281s KeyboardInterrupt 281s __________________ SessionAPITest.test_create_with_kernel_id ___________________ 281s 281s self = 281s 281s def test_create_with_kernel_id(self): 281s # create a new kernel 281s r = self.request('POST', 'api/kernels') 281s r.raise_for_status() 281s kernel = r.json() 281s 281s resp = self.sess_api.create('foo/nb1.ipynb', kernel_id=kernel['id']) 281s self.assertEqual(resp.status_code, 201) 281s newsession = resp.json() 281s self.assertIn('id', newsession) 281s self.assertEqual(newsession['path'], 'foo/nb1.ipynb') 281s self.assertEqual(newsession['kernel']['id'], kernel['id']) 281s self.assertEqual(resp.headers['Location'], f'{self.url_prefix}api/sessions/{newsession["id"]}') 281s 281s sessions = self.sess_api.list().json() 281s > self.assertEqual(sessions, [newsession]) 281s E AssertionError: Lists differ: [{'id': 'cd313de2-8c1e-4449-bc68-33dd02ee0cc2', 'p[553 chars]ne}}] != [{'id': '97a34239-751e-468c-b0f3-81abd8151ca1', 'p[279 chars]ne}}] 281s E 281s E First differing element 0: 281s E {'id': 'cd313de2-8c1e-4449-bc68-33dd02ee0cc2', 'p[218 chars]: 0}} 281s E {'id': '97a34239-751e-468c-b0f3-81abd8151ca1', 'p[278 chars]one}} 281s E 281s E First list contains 1 additional elements. 281s E First extra element 1: 281s E {'id': '97a34239-751e-468c-b0f3-81abd8151ca1', 'path': 'foo/nb1.ipynb', 'name': None, 'type': 'notebook', 'kernel': {'id': 'ab8b76e6-4722-4cb6-8e3b-0fbe390e6541', 'name': 'python3', 'last_activity': '2026-02-06T04:19:13.494090Z', 'execution_state': 'starting', 'connections': 0}, 'notebook': {'path': 'foo/nb1.ipynb', 'name': None}} 281s E 281s E Diff is 830 characters long. Set self.maxDiff to None to see it. 281s 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:178: AssertionError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpl25yw5qh/runtime/kernel-ab8b76e6-4722-4cb6-8e3b-0fbe390e6541.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:48067 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:60855 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: ab8b76e6-4722-4cb6-8e3b-0fbe390e6541, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.950000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.160000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.210000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.070000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 8bd50dfa-4589-46fe-94e1-3f3433ecf6bb 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 8bd50dfa-4589-46fe-94e1-3f3433ecf6bb 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/cd313de2-8c1e-4449-bc68-33dd02ee0cc2 (127.0.0.1) 2.240000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ab8b76e6-4722-4cb6-8e3b-0fbe390e6541 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ab8b76e6-4722-4cb6-8e3b-0fbe390e6541 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/97a34239-751e-468c-b0f3-81abd8151ca1 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/97a34239-751e-468c-b0f3-81abd8151ca1', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 281s yield maybe_future(sm.delete_session(session_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 281s yielded = self.gen.send(value) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 281s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 281s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 281s stopper = ensure_async(km.shutdown_kernel(now, restart)) 281s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/97a34239-751e-468c-b0f3-81abd8151ca1 (127.0.0.1) 8.470000ms referer=None 281s _____________________ SessionAPITest.test_modify_kernel_id _____________________ 281s 281s @self.addCleanup 281s def cleanup_sessions(): 281s for session in self.sess_api.list().json(): 281s > self.sess_api.delete(session['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/97a34239-751e-468c-b0f3-81abd8151ca1 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.220000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpl25yw5qh/runtime/kernel-ca4649eb-339b-4ea9-87ad-a4df394f76e9.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55649 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:56061 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: ca4649eb-339b-4ea9-87ad-a4df394f76e9, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 21.470000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ab8b76e6-4722-4cb6-8e3b-0fbe390e6541 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ab8b76e6-4722-4cb6-8e3b-0fbe390e6541 281s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/97a34239-751e-468c-b0f3-81abd8151ca1 (127.0.0.1) 2.120000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.000000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.010000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ca4649eb-339b-4ea9-87ad-a4df394f76e9 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ca4649eb-339b-4ea9-87ad-a4df394f76e9 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/97a34239-751e-468c-b0f3-81abd8151ca1 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/97a34239-751e-468c-b0f3-81abd8151ca1', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 281s yield maybe_future(sm.delete_session(session_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 281s yielded = self.gen.send(value) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 281s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 281s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 281s stopper = ensure_async(km.shutdown_kernel(now, restart)) 281s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/97a34239-751e-468c-b0f3-81abd8151ca1 (127.0.0.1) 10.410000ms referer=None 281s --------------------------- Captured stderr teardown --------------------------- 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 281s from ipykernel import kernelapp as app 281s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 281s from .connect import * # noqa: F403 281s ^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 9, in 281s from subprocess import PIPE, Popen 281s File "", line 1360, in _find_and_load 281s File "", line 1331, in _find_and_load_unlocked 281s File "", line 935, in _load_unlocked 281s File "", line 1019, in exec_module 281s File "", line 1152, in get_code 281s File "", line 781, in _compile_bytecode 281s KeyboardInterrupt 281s ____________________ SessionAPITest.test_modify_kernel_name ____________________ 281s 281s @self.addCleanup 281s def cleanup_sessions(): 281s for session in self.sess_api.list().json(): 281s > self.sess_api.delete(session['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/97a34239-751e-468c-b0f3-81abd8151ca1 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Exception ignored in: .KeyedRef.remove at 0xf3ea2578> 281s Traceback (most recent call last): 281s File "", line 91, in remove 281s KeyboardInterrupt: 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 2.800000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpl25yw5qh/runtime/kernel-0237409d-fef9-4d99-9558-587b1d5bd1d0.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:41005 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:45765 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 0237409d-fef9-4d99-9558-587b1d5bd1d0, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3', 'cwd': '/tmp/tmpl25yw5qh/notebooks/foo'} 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ca4649eb-339b-4ea9-87ad-a4df394f76e9 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ca4649eb-339b-4ea9-87ad-a4df394f76e9 281s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/97a34239-751e-468c-b0f3-81abd8151ca1 (127.0.0.1) 17.890000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.920000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 0.980000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 0237409d-fef9-4d99-9558-587b1d5bd1d0 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0237409d-fef9-4d99-9558-587b1d5bd1d0 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/97a34239-751e-468c-b0f3-81abd8151ca1 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/97a34239-751e-468c-b0f3-81abd8151ca1', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 281s yield maybe_future(sm.delete_session(session_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 281s yielded = self.gen.send(value) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 281s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 281s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 281s stopper = ensure_async(km.shutdown_kernel(now, restart)) 281s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 281s return _runner_map[name].run(inner) 281s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 281s return fut.result(None) 281s ~~~~~~~~~~^^^^^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 281s return self.__get_result() 281s ~~~~~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 281s raise self._exception 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/97a34239-751e-468c-b0f3-81abd8151ca1 (127.0.0.1) 11.000000ms referer=None 281s ---------------------------- Captured log teardown ----------------------------- 281s INFO NotebookApp:notebookapp.py:2164 Shutting down 1 kernel 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0237409d-fef9-4d99-9558-587b1d5bd1d0 281s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 281s _______________________ AsyncSessionAPITest.test_create ________________________ 281s 281s @self.addCleanup 281s def cleanup_sessions(): 281s for session in self.sess_api.list().json(): 281s > self.sess_api.delete(session['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/b445a6c0-5f49-4e27-9cd3-6c67b030c502 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ------------------------------ Captured log setup ------------------------------ 281s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmp00uereyg/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmp00uereyg/etc/jupyter'] for config files 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmp00uereyg/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmp00uereyg/config 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmp00uereyg/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 281s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmp00uereyg/config 281s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmp00uereyg/notebooks 281s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 281s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 281s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 281s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 281s WARNING NotebookApp:handlers.py:612 Forbidden 281s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 0.710000ms referer=None 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.190000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp00uereyg/runtime/kernel-f997a254-37e5-4f50-8909-04fc5ecb53b5.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:33131 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:42311 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: f997a254-37e5-4f50-8909-04fc5ecb53b5, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmp00uereyg/notebooks/foo'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 16.820000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.030000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions/b445a6c0-5f49-4e27-9cd3-6c67b030c502 (127.0.0.1) 1.060000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.020000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for f997a254-37e5-4f50-8909-04fc5ecb53b5 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: f997a254-37e5-4f50-8909-04fc5ecb53b5 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/b445a6c0-5f49-4e27-9cd3-6c67b030c502 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/b445a6c0-5f49-4e27-9cd3-6c67b030c502', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 281s future.result() 281s ~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 281s yield maybe_future(sm.delete_session(session_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 281s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 281s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 281s raise km.ready.exception() # type: ignore[misc] 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/b445a6c0-5f49-4e27-9cd3-6c67b030c502 (127.0.0.1) 7.730000ms referer=None 281s --------------------------- Captured stderr teardown --------------------------- 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 281s from pathlib import Path 281s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 281s from ._local import * 281s File "", line 1360, in _find_and_load 281s File "", line 1339, in _find_and_load_unlocked 281s KeyboardInterrupt 281s _______________ AsyncSessionAPITest.test_create_console_session ________________ 281s 281s @self.addCleanup 281s def cleanup_sessions(): 281s for session in self.sess_api.list().json(): 281s > self.sess_api.delete(session['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/594d586e-b4d9-40cb-84fc-ffdbb3b022f0 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 281s from pathlib import Path 281s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 281s from ._local import * 281s File "/usr/lib/python3.13/pathlib/_local.py", line 473, in 281s class PureWindowsPath(PurePath): 281s ...<7 lines>... 281s __slots__ = () 281s File "/usr/lib/python3.13/pathlib/_local.py", line 479, in PureWindowsPath 281s import ntpath 281s File "", line 1360, in _find_and_load 281s File "", line 1322, in _find_and_load_unlocked 281s File "", line 1262, in _find_spec 281s File "", line 1556, in find_spec 281s File "", line 1530, in _get_spec 281s File "", line 1629, in find_spec 281s File "", line 152, in _path_stat 281s KeyboardInterrupt 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp00uereyg/runtime/kernel-9c527106-f0c4-4e09-862d-0a775e0f4c72.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:56915 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:39591 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 9c527106-f0c4-4e09-862d-0a775e0f4c72, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmp00uereyg/notebooks/foo'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 17.840000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.100000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for f997a254-37e5-4f50-8909-04fc5ecb53b5 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: f997a254-37e5-4f50-8909-04fc5ecb53b5 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/b445a6c0-5f49-4e27-9cd3-6c67b030c502 (127.0.0.1) 1.350000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 9c527106-f0c4-4e09-862d-0a775e0f4c72 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 9c527106-f0c4-4e09-862d-0a775e0f4c72 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/594d586e-b4d9-40cb-84fc-ffdbb3b022f0 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/594d586e-b4d9-40cb-84fc-ffdbb3b022f0', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 281s future.result() 281s ~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 281s yield maybe_future(sm.delete_session(session_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 281s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 281s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 281s raise km.ready.exception() # type: ignore[misc] 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/594d586e-b4d9-40cb-84fc-ffdbb3b022f0 (127.0.0.1) 15.540000ms referer=None 281s __________________ AsyncSessionAPITest.test_create_deprecated __________________ 281s 281s @self.addCleanup 281s def cleanup_sessions(): 281s for session in self.sess_api.list().json(): 281s > self.sess_api.delete(session['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/c1eef9fe-07a7-4644-aa2b-b6247d90a31c 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s WARNING NotebookApp:handlers.py:46 Sessions API changed, see updated swagger docs 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp00uereyg/runtime/kernel-3302691d-15d3-4de2-ae5a-62df9e140711.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:56151 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34137 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 3302691d-15d3-4de2-ae5a-62df9e140711, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmp00uereyg/notebooks/foo'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 17.610000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.100000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 9c527106-f0c4-4e09-862d-0a775e0f4c72 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 9c527106-f0c4-4e09-862d-0a775e0f4c72 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/594d586e-b4d9-40cb-84fc-ffdbb3b022f0 (127.0.0.1) 1.330000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 3302691d-15d3-4de2-ae5a-62df9e140711 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 3302691d-15d3-4de2-ae5a-62df9e140711 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/c1eef9fe-07a7-4644-aa2b-b6247d90a31c (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/c1eef9fe-07a7-4644-aa2b-b6247d90a31c', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 281s future.result() 281s ~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 281s yield maybe_future(sm.delete_session(session_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 281s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 281s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 281s raise km.ready.exception() # type: ignore[misc] 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/c1eef9fe-07a7-4644-aa2b-b6247d90a31c (127.0.0.1) 8.040000ms referer=None 281s --------------------------- Captured stderr teardown --------------------------- 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 281s from pathlib import Path 281s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 281s from ._abc import * 281s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 281s from glob import _Globber, _no_recurse_symlinks 281s File "/usr/lib/python3.13/glob.py", line 5, in 281s import re 281s File "/usr/lib/python3.13/re/__init__.py", line 381, in 281s import copyreg 281s File "", line 1360, in _find_and_load 281s File "", line 1322, in _find_and_load_unlocked 281s File "", line 1262, in _find_spec 281s File "", line 1556, in find_spec 281s File "", line 1530, in _get_spec 281s File "", line 1629, in find_spec 281s File "", line 152, in _path_stat 281s KeyboardInterrupt 281s _________________ AsyncSessionAPITest.test_create_file_session _________________ 281s 281s @self.addCleanup 281s def cleanup_sessions(): 281s for session in self.sess_api.list().json(): 281s > self.sess_api.delete(session['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/81209eaf-5cf5-4a40-9278-01a0265a9c38 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp00uereyg/runtime/kernel-08d93347-6789-4cad-813d-fb5e0c3d1e45.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:37461 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:58637 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 08d93347-6789-4cad-813d-fb5e0c3d1e45, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmp00uereyg/notebooks/foo'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 16.280000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.010000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 3302691d-15d3-4de2-ae5a-62df9e140711 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 3302691d-15d3-4de2-ae5a-62df9e140711 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/c1eef9fe-07a7-4644-aa2b-b6247d90a31c (127.0.0.1) 1.210000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 08d93347-6789-4cad-813d-fb5e0c3d1e45 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 08d93347-6789-4cad-813d-fb5e0c3d1e45 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/81209eaf-5cf5-4a40-9278-01a0265a9c38 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/81209eaf-5cf5-4a40-9278-01a0265a9c38', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 281s future.result() 281s ~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 281s yield maybe_future(sm.delete_session(session_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 281s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 281s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 281s raise km.ready.exception() # type: ignore[misc] 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/81209eaf-5cf5-4a40-9278-01a0265a9c38 (127.0.0.1) 7.600000ms referer=None 281s --------------------------- Captured stderr teardown --------------------------- 281s Traceback (most recent call last): 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 281s from pathlib import Path 281s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 281s from ._abc import * 281s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 281s from glob import _Globber, _no_recurse_symlinks 281s File "/usr/lib/python3.13/glob.py", line 5, in 281s import re 281s File "/usr/lib/python3.13/re/__init__.py", line 126, in 281s from . import _compiler, _parser 281s File "/usr/lib/python3.13/re/_compiler.py", line 14, in 281s from . import _parser 281s File "/usr/lib/python3.13/re/_parser.py", line 15, in 281s from ._constants import * 281s File "", line 1360, in _find_and_load 281s File "", line 1331, in _find_and_load_unlocked 281s File "", line 935, in _load_unlocked 281s File "", line 1019, in exec_module 281s File "", line 1152, in get_code 281s File "", line 781, in _compile_bytecode 281s KeyboardInterrupt 281s ________________ AsyncSessionAPITest.test_create_with_kernel_id ________________ 281s 281s self = 281s 281s def test_create_with_kernel_id(self): 281s # create a new kernel 281s r = self.request('POST', 'api/kernels') 281s r.raise_for_status() 281s kernel = r.json() 281s 281s resp = self.sess_api.create('foo/nb1.ipynb', kernel_id=kernel['id']) 281s self.assertEqual(resp.status_code, 201) 281s newsession = resp.json() 281s self.assertIn('id', newsession) 281s self.assertEqual(newsession['path'], 'foo/nb1.ipynb') 281s self.assertEqual(newsession['kernel']['id'], kernel['id']) 281s self.assertEqual(resp.headers['Location'], f'{self.url_prefix}api/sessions/{newsession["id"]}') 281s 281s sessions = self.sess_api.list().json() 281s > self.assertEqual(sessions, [newsession]) 281s E AssertionError: Lists differ: [{'id': '81209eaf-5cf5-4a40-9278-01a0265a9c38', 'p[553 chars]ne}}] != [{'id': 'aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2', 'p[279 chars]ne}}] 281s E 281s E First differing element 0: 281s E {'id': '81209eaf-5cf5-4a40-9278-01a0265a9c38', 'p[218 chars]: 0}} 281s E {'id': 'aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2', 'p[278 chars]one}} 281s E 281s E First list contains 1 additional elements. 281s E First extra element 1: 281s E {'id': 'aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2', 'path': 'foo/nb1.ipynb', 'name': None, 'type': 'notebook', 'kernel': {'id': 'c2da70f4-ba91-4096-ae7d-13fc94e40f07', 'name': 'python3', 'last_activity': '2026-02-06T04:19:14.044417Z', 'execution_state': 'starting', 'connections': 0}, 'notebook': {'path': 'foo/nb1.ipynb', 'name': None}} 281s E 281s E Diff is 830 characters long. Set self.maxDiff to None to see it. 281s 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:178: AssertionError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp00uereyg/runtime/kernel-c2da70f4-ba91-4096-ae7d-13fc94e40f07.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:54729 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:59069 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: c2da70f4-ba91-4096-ae7d-13fc94e40f07, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.000000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.190000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.040000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.050000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 08d93347-6789-4cad-813d-fb5e0c3d1e45 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 08d93347-6789-4cad-813d-fb5e0c3d1e45 281s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/81209eaf-5cf5-4a40-9278-01a0265a9c38 (127.0.0.1) 1.240000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for c2da70f4-ba91-4096-ae7d-13fc94e40f07 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c2da70f4-ba91-4096-ae7d-13fc94e40f07 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 281s future.result() 281s ~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 281s yield maybe_future(sm.delete_session(session_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 281s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 281s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 281s raise km.ready.exception() # type: ignore[misc] 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2 (127.0.0.1) 7.590000ms referer=None 281s __________________ AsyncSessionAPITest.test_modify_kernel_id ___________________ 281s 281s @self.addCleanup 281s def cleanup_sessions(): 281s for session in self.sess_api.list().json(): 281s > self.sess_api.delete(session['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.260000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp00uereyg/runtime/kernel-83f11c37-6105-4d1a-b6a7-37f16f350fcc.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:54623 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:36303 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: 83f11c37-6105-4d1a-b6a7-37f16f350fcc, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.150000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for c2da70f4-ba91-4096-ae7d-13fc94e40f07 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c2da70f4-ba91-4096-ae7d-13fc94e40f07 281s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2 (127.0.0.1) 1.450000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.000000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.030000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 83f11c37-6105-4d1a-b6a7-37f16f350fcc 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 83f11c37-6105-4d1a-b6a7-37f16f350fcc 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 281s future.result() 281s ~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 281s yield maybe_future(sm.delete_session(session_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 281s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 281s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 281s raise km.ready.exception() # type: ignore[misc] 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2 (127.0.0.1) 8.300000ms referer=None 281s --------------------------- Captured stderr teardown --------------------------- 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 281s from ipykernel import kernelapp as app 281s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 281s from .connect import * # noqa: F403 281s ^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 7, in 281s import json 281s File "/usr/lib/python3.13/json/__init__.py", line 106, in 281s from .decoder import JSONDecoder, JSONDecodeError 281s File "/usr/lib/python3.13/json/decoder.py", line 5, in 281s from json import scanner 281s File "", line 1357, in _find_and_load 281s File "", line 420, in __exit__ 281s KeyboardInterrupt 281s [IPKernelApp] ERROR | Current working directory doesn't exist. 281s _________________ AsyncSessionAPITest.test_modify_kernel_name __________________ 281s 281s @self.addCleanup 281s def cleanup_sessions(): 281s for session in self.sess_api.list().json(): 281s > self.sess_api.delete(session['id']) 281s 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 281s return self._req('DELETE', id) 281s ^^^^^^^^^^^^^^^^^^^^^^^ 281s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 281s response.raise_for_status() 281s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 281s 281s self = 281s 281s def raise_for_status(self): 281s """Raises :class:`HTTPError`, if one occurred.""" 281s 281s http_error_msg = "" 281s if isinstance(self.reason, bytes): 281s # We attempt to decode utf-8 first because some servers 281s # choose to localize their reason strings. If the string 281s # isn't utf-8, we fall back to iso-8859-1 for all other 281s # encodings. (See PR #3538) 281s try: 281s reason = self.reason.decode("utf-8") 281s except UnicodeDecodeError: 281s reason = self.reason.decode("iso-8859-1") 281s else: 281s reason = self.reason 281s 281s if 400 <= self.status_code < 500: 281s http_error_msg = ( 281s f"{self.status_code} Client Error: {reason} for url: {self.url}" 281s ) 281s 281s elif 500 <= self.status_code < 600: 281s http_error_msg = ( 281s f"{self.status_code} Server Error: {reason} for url: {self.url}" 281s ) 281s 281s if http_error_msg: 281s > raise HTTPError(http_error_msg, response=self) 281s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2 281s 281s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 281s ----------------------------- Captured stderr call ----------------------------- 281s Traceback (most recent call last): 281s ------------------------------ Captured log call ------------------------------- 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.180000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 281s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp00uereyg/runtime/kernel-d2fd4f7c-2cd9-4571-bf34-7a8bad99f1de.json'] 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:39511 281s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:48943 281s INFO NotebookApp:kernelmanager.py:179 Kernel started: d2fd4f7c-2cd9-4571-bf34-7a8bad99f1de, name: python3 281s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3', 'cwd': '/tmp/tmp00uereyg/notebooks/foo'} 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 83f11c37-6105-4d1a-b6a7-37f16f350fcc 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 83f11c37-6105-4d1a-b6a7-37f16f350fcc 281s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2 (127.0.0.1) 17.000000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.990000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.080000ms 281s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 281s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for d2fd4f7c-2cd9-4571-bf34-7a8bad99f1de 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: d2fd4f7c-2cd9-4571-bf34-7a8bad99f1de 281s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2 (127.0.0.1) 281s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2', version='HTTP/1.1', remote_ip='127.0.0.1') 281s Traceback (most recent call last): 281s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 281s result = await result 281s ^^^^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 281s future.result() 281s ~~~~~~~~~~~~~^^ 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 281s yield maybe_future(sm.delete_session(session_id)) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 281s yielded = self.gen.throw(exc) 281s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 281s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 281s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 281s value = future.result() 281s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 281s raise self._exception.with_traceback(self._exception_tb) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 281s result = coro.send(None) 281s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 281s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 281s raise km.ready.exception() # type: ignore[misc] 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 281s await kernel_awaitable 281s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 281s result = await obj 281s ^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 281s raise e 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 281s out = await method(self, *args, **kwargs) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 281s await self._async_finish_shutdown(restart=restart) 281s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 281s await asyncio.wait_for( 281s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 281s ) 281s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 281s async with timeouts.timeout(timeout): 281s ~~~~~~~~~~~~~~~~^^^^^^^^^ 281s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 281s raise RuntimeError("Timeout should be used inside a task") 281s RuntimeError: Timeout should be used inside a task 281s WARNING NotebookApp:handlers.py:612 Unhandled error 281s ERROR NotebookApp:log.py:55 { 281s "Host": "localhost:12341", 281s "Accept": "*/*", 281s "User-Agent": "python-requests/2.32.5" 281s } 281s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/aa5f8bfc-e257-4d4a-b01e-62b4b471e8c2 (127.0.0.1) 7.640000ms referer=None 281s --------------------------- Captured stderr teardown --------------------------- 281s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 281s return _run_code(code, main_globals, None, 281s "__main__", mod_spec) 281s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 281s exec(code, run_globals) 281s ~~~~^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 281s from pathlib import Path 281s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 281s from ._abc import * 281s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 281s from glob import _Globber, _no_recurse_symlinks 281s File "/usr/lib/python3.13/glob.py", line 5, in 281s import re 281s File "/usr/lib/python3.13/re/__init__.py", line 315, in 281s Pattern = type(_compiler.compile('', 0)) 281s ~~~~~~~~~~~~~~~~~^^^^^^^ 281s File "/usr/lib/python3.13/re/_compiler.py", line 748, in compile 281s p = _parser.parse(p, flags) 281s File "/usr/lib/python3.13/re/_parser.py", line 980, in parse 281s p = _parse_sub(source, state, flags & SRE_FLAG_VERBOSE, 0) 281s File "/usr/lib/python3.13/re/_parser.py", line 459, in _parse_sub 281s itemsappend(_parse(source, state, verbose, nested + 1, 281s ~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 281s not nested and not items)) 281s ^^^^^^^^^^^^^^^^^^^^^^^^^ 281s File "/usr/lib/python3.13/re/_parser.py", line 513, in _parse 281s subpattern = SubPattern(state) 281s KeyboardInterrupt 281s ---------------------------- Captured log teardown ----------------------------- 281s INFO NotebookApp:notebookapp.py:2164 Shutting down 1 kernel 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 3302691d-15d3-4de2-ae5a-62df9e140711 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: c2da70f4-ba91-4096-ae7d-13fc94e40f07 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: f997a254-37e5-4f50-8909-04fc5ecb53b5 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 83f11c37-6105-4d1a-b6a7-37f16f350fcc 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 08d93347-6789-4cad-813d-fb5e0c3d1e45 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: d2fd4f7c-2cd9-4571-bf34-7a8bad99f1de 281s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 9c527106-f0c4-4e09-862d-0a775e0f4c72 281s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 281s =============================== warnings summary =============================== 281s ../../../usr/lib/python3/dist-packages/notebook/utils.py:280 281s ../../../usr/lib/python3/dist-packages/notebook/utils.py:280 281s /usr/lib/python3/dist-packages/notebook/utils.py:280: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead. 281s return LooseVersion(v) >= LooseVersion(check) 281s 281s ../../../usr/lib/python3/dist-packages/notebook/_tz.py:29: 1 warning 281s services/kernels/tests/test_kernels_api.py: 68 warnings 281s services/sessions/tests/test_sessions_api.py: 88 warnings 281s /usr/lib/python3/dist-packages/notebook/_tz.py:29: DeprecationWarning: datetime.datetime.utcnow() is deprecated and scheduled for removal in a future version. Use timezone-aware objects to represent datetimes in UTC: datetime.datetime.now(datetime.UTC). 281s dt = unaware(*args, **kwargs) 281s 281s ../../../usr/lib/python3/dist-packages/notebook/tests/test_notebookapp_integration.py:14 281s /usr/lib/python3/dist-packages/notebook/tests/test_notebookapp_integration.py:14: PytestUnknownMarkWarning: Unknown pytest.mark.integration_tests - is this a typo? You can register custom marks to avoid this warning - for details, see https://docs.pytest.org/en/stable/how-to/mark.html 281s pytestmark = pytest.mark.integration_tests 281s 281s services/kernels/tests/test_kernels_api.py: 6 warnings 281s services/sessions/tests/test_sessions_api.py: 6 warnings 281s /usr/lib/python3/dist-packages/nest_asyncio.py:71: DeprecationWarning: 'asyncio.get_event_loop_policy' is deprecated and slated for removal in Python 3.16 281s policy = events.get_event_loop_policy() 281s 281s services/kernels/tests/test_kernels_api.py: 22 warnings 281s services/sessions/tests/test_sessions_api.py: 17 warnings 281s /usr/lib/python3/dist-packages/nest_asyncio.py:40: DeprecationWarning: 'asyncio.get_event_loop_policy' is deprecated and slated for removal in Python 3.16 281s loop = events.get_event_loop_policy().get_event_loop() 281s 281s services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_connections 281s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:67: DeprecationWarning: make_current is deprecated; start the event loop first 281s loop.make_current() 281s 281s services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create 281s /usr/lib/python3.14/asyncio/events.py:94: RuntimeWarning: coroutine 'KernelManager._async_wait' was never awaited 281s self._context.run(self._callback, *self._args) 281s Enable tracemalloc to get traceback where the object was allocated. 281s See https://docs.pytest.org/en/stable/how-to/capture-warnings.html#resource-warnings for more info. 281s 281s -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html 281s =========================== short test summary info ============================ 281s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_default_kernel 281s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_kernel_handler 281s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_main_kernel_handler 281s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_no_kernels 281s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_connections 281s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_default_kernel 281s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_kernel_handler 281s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_main_kernel_handler 281s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_no_kernels 281s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create 281s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_console_session 281s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_deprecated 281s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_file_session 281s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_with_kernel_id 281s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_modify_kernel_id 281s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_modify_kernel_name 281s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create 281s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_console_session 281s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_deprecated 281s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_file_session 281s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_with_kernel_id 281s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_modify_kernel_id 281s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_modify_kernel_name 281s ERROR services/kernels/tests/test_kernels_api.py::KernelAPITest::test_main_kernel_handler 281s ERROR services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_main_kernel_handler 281s ERROR services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_with_kernel_id 281s ERROR services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_with_kernel_id 281s ========== 23 failed, 307 deselected, 213 warnings, 4 errors in 6.53s ========== 282s *** END OF RUN 4: NOT ALL TESTS HAVE YET PASSED/XFAILED *** 282s *** STARTING RUN 5: python3.14 -m pytest --pyargs notebook -rfE --last-failed --last-failed-no-failures none --ignore=/usr/lib/python3/dist-packages/notebook/tests/selenium --deselect=services/kernels/tests/test_kernels_api.py::KernelAPITest::test_connections 285s ============================= test session starts ============================== 285s platform linux -- Python 3.14.2, pytest-9.0.2, pluggy-1.6.0 285s rootdir: /tmp/autopkgtest.d1RsUl/autopkgtest_tmp 285s plugins: typeguard-4.4.4 285s collected 330 items / 307 deselected / 23 selected 285s run-last-failure: rerun previous 23 failures 285s 287s services/kernels/tests/test_kernels_api.py FFFEFFFFFEF [ 39%] 289s services/sessions/tests/test_sessions_api.py FFFFFEFFFFFFFEFF [100%] 289s 289s ==================================== ERRORS ==================================== 289s _________ ERROR at teardown of KernelAPITest.test_main_kernel_handler __________ 289s 289s self = 289s 289s def tearDown(self): 289s for k in self.kern_api.list().json(): 289s > self.kern_api.shutdown(k['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/42c3c86a-374d-4e65-a416-295da1480d2f 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ----------------------------- Captured stderr call ----------------------------- 289s Traceback (most recent call last): 289s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 289s return _run_code(code, main_globals, None, 289s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 289s exec(code, run_globals) 289s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 289s from pathlib import Path 289s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 289s from ._abc import * 289s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 289s from glob import _Globber, _no_recurse_symlinks 289s File "/usr/lib/python3.13/glob.py", line 5, in 289s import re 289s File "/usr/lib/python3.13/re/__init__.py", line 125, in 289s import enum 289s File "/usr/lib/python3.13/enum.py", line 339, in 289s class EnumDict(dict): 289s File "/usr/lib/python3.13/enum.py", line 238, in __set_name__ 289s def __set_name__(self, ownerclass, name): 289s KeyboardInterrupt 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp2xntu6k7/runtime/kernel-42c3c86a-374d-4e65-a416-295da1480d2f.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:39935 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:38153 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: 42c3c86a-374d-4e65-a416-295da1480d2f, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 19.800000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.990000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp2xntu6k7/runtime/kernel-1fb7a04c-8c2a-44ab-91a2-cbd43084e43e.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:40671 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:47643 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: 1fb7a04c-8c2a-44ab-91a2-cbd43084e43e, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 20.990000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.990000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: 1fb7a04c-8c2a-44ab-91a2-cbd43084e43e 289s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/1fb7a04c-8c2a-44ab-91a2-cbd43084e43e/interrupt (127.0.0.1) 1.440000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 289s yield maybe_future(km.restart_kernel(kernel_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 289s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 289s await ensure_async(kernel.restart_kernel(now=now)) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 289s await self._async_shutdown_kernel(now=now, restart=True) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/1fb7a04c-8c2a-44ab-91a2-cbd43084e43e/restart (127.0.0.1) 5.470000ms referer=None 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.960000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 42c3c86a-374d-4e65-a416-295da1480d2f 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 42c3c86a-374d-4e65-a416-295da1480d2f 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/42c3c86a-374d-4e65-a416-295da1480d2f (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/42c3c86a-374d-4e65-a416-295da1480d2f', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 289s yielded = ctx_run(next, result) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 289s yield maybe_future(km.shutdown_kernel(kernel_id)) 289s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 289s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 289s stopper = ensure_async(km.shutdown_kernel(now, restart)) 289s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/42c3c86a-374d-4e65-a416-295da1480d2f (127.0.0.1) 9.700000ms referer=None 289s --------------------------- Captured stderr teardown --------------------------- 289s Traceback (most recent call last): 289s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 289s return _run_code(code, main_globals, None, 289s "__main__", mod_spec) 289s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 289s exec(code, run_globals) 289s ~~~~^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 289s from ipykernel import kernelapp as app 289s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 289s from .connect import * # noqa: F403 289s ^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 12, in 289s import jupyter_client 289s File "/usr/lib/python3/dist-packages/jupyter_client/__init__.py", line 4, in 289s from .asynchronous import AsyncKernelClient 289s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/__init__.py", line 1, in 289s from .client import AsyncKernelClient # noqa 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/client.py", line 9, in 289s import zmq.asyncio 289s File "/usr/lib/python3/dist-packages/zmq/asyncio.py", line 10, in 289s import asyncio 289s File "/usr/lib/python3.13/asyncio/__init__.py", line 8, in 289s from .base_events import * 289s File "/usr/lib/python3.13/asyncio/base_events.py", line 18, in 289s import concurrent.futures 289s File "/usr/lib/python3.13/concurrent/futures/__init__.py", line 8, in 289s from concurrent.futures._base import (FIRST_COMPLETED, 289s ...<9 lines>... 289s as_completed) 289s File "/usr/lib/python3.13/concurrent/futures/_base.py", line 7, in 289s import logging 289s File "/usr/lib/python3.13/logging/__init__.py", line 26, in 289s import sys, os, time, io, re, traceback, warnings, weakref, collections.abc 289s File "", line 1360, in _find_and_load 289s File "", line 1331, in _find_and_load_unlocked 289s File "", line 935, in _load_unlocked 289s File "", line 1019, in exec_module 289s File "", line 1152, in get_code 289s File "", line 781, in _compile_bytecode 289s KeyboardInterrupt 289s _______ ERROR at teardown of AsyncKernelAPITest.test_main_kernel_handler _______ 289s 289s self = 289s 289s def tearDown(self): 289s for k in self.kern_api.list().json(): 289s > self.kern_api.shutdown(k['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/afbd8724-e283-4418-8788-8e612f096519 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ----------------------------- Captured stderr call ----------------------------- 289s Traceback (most recent call last): 289s File "/usr/lib/python3.13/runpy.py", line 189, in _run_module_as_main 289s mod_name, mod_spec, code = _get_module_details(mod_name, _Error) 289s File "/usr/lib/python3.13/runpy.py", line 131, in _get_module_details 289s spec = importlib.util.find_spec(mod_name) 289s File "/usr/lib/python3.13/importlib/util.py", line 100, in find_spec 289s return _find_spec(fullname, parent_path) 289s File "", line 1262, in _find_spec 289s File "", line 1556, in find_spec 289s File "", line 1530, in _get_spec 289s File "", line 1629, in find_spec 289s File "", line 152, in _path_stat 289s KeyboardInterrupt 289s Traceback (most recent call last): 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpsua20r9t/runtime/kernel-afbd8724-e283-4418-8788-8e612f096519.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:33869 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:52571 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: afbd8724-e283-4418-8788-8e612f096519, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.470000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.040000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpsua20r9t/runtime/kernel-ba47f4b9-1327-4019-8691-247f3273e7e0.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:60895 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55359 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: ba47f4b9-1327-4019-8691-247f3273e7e0, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 17.080000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.640000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: ba47f4b9-1327-4019-8691-247f3273e7e0 289s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/ba47f4b9-1327-4019-8691-247f3273e7e0/interrupt (127.0.0.1) 1.200000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 289s yield maybe_future(km.restart_kernel(kernel_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 291, in __step_run_and_handle_result 289s result = coro.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 289s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 289s File "/usr/lib/python3.14/asyncio/futures.py", line 295, in __await__ 289s yield self # This tells Task to wait for completion. 289s ^^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 289s future.result() 289s ~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 289s await ensure_async(kernel.restart_kernel(now=now)) 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 289s await self._async_shutdown_kernel(now=now, restart=True) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/ba47f4b9-1327-4019-8691-247f3273e7e0/restart (127.0.0.1) 4.300000ms referer=None 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.840000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for afbd8724-e283-4418-8788-8e612f096519 289s INFO NotebookApp:multikernelmanager.py:30/usr/lib/python3/dist-packages/_pytest/unraisableexception.py:33: RuntimeWarning: coroutine 'KernelManager._async_wait' was never awaited 289s gc.collect() 289s RuntimeWarning: Enable tracemalloc to get the object allocation traceback 289s 5 Kernel shutdown: afbd8724-e283-4418-8788-8e612f096519 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/afbd8724-e283-4418-8788-8e612f096519 (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/afbd8724-e283-4418-8788-8e612f096519', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 289s future.result() 289s ~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 289s yield maybe_future(km.shutdown_kernel(kernel_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 289s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 289s raise km.ready.exception() # type: ignore[misc] 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/afbd8724-e283-4418-8788-8e612f096519 (127.0.0.1) 8.680000ms referer=None 289s --------------------------- Captured stderr teardown --------------------------- 289s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 289s return _run_code(code, main_globals, None, 289s "__main__", mod_spec) 289s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 289s exec(code, run_globals) 289s ~~~~^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 289s from ipykernel import kernelapp as app 289s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 289s from .connect import * # noqa: F403 289s ^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 12, in 289s import jupyter_client 289s File "/usr/lib/python3/dist-packages/jupyter_client/__init__.py", line 4, in 289s from .asynchronous import AsyncKernelClient 289s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/__init__.py", line 1, in 289s from .client import AsyncKernelClient # noqa 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/asynchronous/client.py", line 9, in 289s import zmq.asyncio 289s File "/usr/lib/python3/dist-packages/zmq/__init__.py", line 52, in 289s from zmq import backend 289s File "/usr/lib/python3/dist-packages/zmq/backend/__init__.py", line 25, in 289s _ns = select_backend(first) 289s File "/usr/lib/python3/dist-packages/zmq/backend/select.py", line 31, in select_backend 289s mod = import_module(name) 289s File "/usr/lib/python3.13/importlib/__init__.py", line 88, in import_module 289s return _bootstrap._gcd_import(name[level:], package, level) 289s ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/zmq/backend/cython/__init__.py", line 6, in 289s from . import _zmq 289s File "_zmq.py", line 156, in init zmq.backend.cython._zmq 289s File "", line 1360, in _find_and_load 289s File "", line 1331, in _find_and_load_unlocked 289s File "", line 921, in _load_unlocked 289s File "", line 819, in module_from_spec 289s File "", line 798, in _init_module_attrs 289s File "", line 638, in cached 289s File "", line 642, in _get_cached 289s File "", line 540, in cache_from_source 289s KeyboardInterrupt 289s ________ ERROR at teardown of SessionAPITest.test_create_with_kernel_id ________ 289s 289s @self.addCleanup 289s def cleanup_sessions(): 289s for session in self.sess_api.list().json(): 289s > self.sess_api.delete(session['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/20ecc7fe-3ec9-4ad7-95fa-59042b466c0c 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ----------------------------- Captured stderr call ----------------------------- 289s Traceback (most recent call last): 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpmvyldrpd/runtime/kernel-0b2c88dc-eb6c-4709-911f-f0c4b426b689.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:46529 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:58751 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: 0b2c88dc-eb6c-4709-911f-f0c4b426b689, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 22.520000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.200000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.160000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.150000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 71892635-e5d7-4a54-a51a-e9f804a6d12b 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 71892635-e5d7-4a54-a51a-e9f804a6d12b 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/c6f195f7-de29-4f0f-8dc0-bce69e3ea792 (127.0.0.1) 1.690000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 0b2c88dc-eb6c-4709-911f-f0c4b426b689 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0b2c88dc-eb6c-4709-911f-f0c4b426b689 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/20ecc7fe-3ec9-4ad7-95fa-59042b466c0c (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/20ecc7fe-3ec9-4ad7-95fa-59042b466c0c', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 289s yield maybe_future(sm.delete_session(session_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 289s yielded = self.gen.send(value) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 289s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 289s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 289s stopper = ensure_async(km.shutdown_kernel(now, restart)) 289s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/20ecc7fe-3ec9-4ad7-95fa-59042b466c0c (127.0.0.1) 9.220000ms referer=None 289s --------------------------- Captured stderr teardown --------------------------- 289s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 289s return _run_code(code, main_globals, None, 289s "__main__", mod_spec) 289s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 289s exec(code, run_globals) 289s ~~~~^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 289s from ipykernel import kernelapp as app 289s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 289s from .connect import * # noqa: F403 289s ^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 9, in 289s from subprocess import PIPE, Popen 289s File "/usr/lib/python3.13/subprocess.py", line 51, in 289s import threading 289s File "", line 1360, in _find_and_load 289s File "", line 1331, in _find_and_load_unlocked 289s File "", line 935, in _load_unlocked 289s File "", line 1019, in exec_module 289s File "", line 1152, in get_code 289s File "", line 781, in _compile_bytecode 289s KeyboardInterrupt 289s _____ ERROR at teardown of AsyncSessionAPITest.test_create_with_kernel_id ______ 289s 289s @self.addCleanup 289s def cleanup_sessions(): 289s for session in self.sess_api.list().json(): 289s > self.sess_api.delete(session['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/a654b638-0f75-42f4-8e97-3c2b6e1e6c87 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ----------------------------- Captured stderr call ----------------------------- 289s File "/usr/lib/python3.13/site.py", line 735, in 289s main() 289s ~~~~^^ 289s File "/usr/lib/python3.13/site.py", line 722, in main 289s known_paths = addsitepackages(known_paths) 289s File "/usr/lib/python3.13/site.py", line 441, in addsitepackages 289s addsitedir(sitedir, known_paths) 289s ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3.13/site.py", line 254, in addsitedir 289s addpackage(sitedir, name, known_paths) 289s ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3.13/site.py", line 197, in addpackage 289s pth_content = pth_content.decode("utf-8-sig") 289s File "/usr/lib/python3.13/encodings/__init__.py", line 99, in search_function 289s mod = __import__('encodings.' + modname, fromlist=_import_tail, 289s level=0) 289s File "", line 1360, in _find_and_load 289s File "", line 1331, in _find_and_load_unlocked 289s File "", line 935, in _load_unlocked 289s File "", line 1019, in exec_module 289s File "", line 1152, in get_code 289s File "", line 785, in _compile_bytecode 289s KeyboardInterrupt 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpj4ps_shk/runtime/kernel-ba271671-fc2e-48b8-a05a-3ef07a068663.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:50717 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:36121 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: ba271671-fc2e-48b8-a05a-3ef07a068663, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 17.200000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.220000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.070000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.070000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for fabc8f78-d375-478c-9d91-6f7a14012e82 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: fabc8f78-d375-478c-9d91-6f7a14012e82 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/b79dbf00-a6a9-49de-8a87-22223dd87527 (127.0.0.1) 1.280000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ba271671-fc2e-48b8-a05a-3ef07a068663 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ba271671-fc2e-48b8-a05a-3ef07a068663 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/a654b638-0f75-42f4-8e97-3c2b6e1e6c87 (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/a654b638-0f75-42f4-8e97-3c2b6e1e6c87', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 289s future.result() 289s ~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 289s yield maybe_future(sm.delete_session(session_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 289s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 289s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 289s raise km.ready.exception() # type: ignore[misc] 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/a654b638-0f75-42f4-8e97-3c2b6e1e6c87 (127.0.0.1) 7.770000ms referer=None 289s =================================== FAILURES =================================== 289s ______________________ KernelAPITest.test_default_kernel _______________________ 289s 289s self = 289s 289s def tearDown(self): 289s for k in self.kern_api.list().json(): 289s > self.kern_api.shutdown(k['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/455dd117-d57f-42e9-9098-770f0c3aa4dc 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ------------------------------ Captured log setup ------------------------------ 289s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmp2xntu6k7/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmp2xntu6k7/etc/jupyter'] for config files 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmp2xntu6k7/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmp2xntu6k7/config 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmp2xntu6k7/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmp2xntu6k7/config 289s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmp2xntu6k7/notebooks 289s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 289s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 289s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 289s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 289s WARNING NotebookApp:handlers.py:612 Forbidden 289s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 2.000000ms referer=None 289s ----------------------------- Captured stderr call ----------------------------- 289s Traceback (most recent call last): 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp2xntu6k7/runtime/kernel-455dd117-d57f-42e9-9098-770f0c3aa4dc.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:44777 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:46943 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: 455dd117-d57f-42e9-9098-770f0c3aa4dc, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 66.160000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.310000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 455dd117-d57f-42e9-9098-770f0c3aa4dc 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 455dd117-d57f-42e9-9098-770f0c3aa4dc 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/455dd117-d57f-42e9-9098-770f0c3aa4dc (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/455dd117-d57f-42e9-9098-770f0c3aa4dc', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 289s yielded = ctx_run(next, result) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 289s yield maybe_future(km.shutdown_kernel(kernel_id)) 289s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 289s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 289s stopper = ensure_async(km.shutdown_kernel(now, restart)) 289s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/455dd117-d57f-42e9-9098-770f0c3aa4dc (127.0.0.1) 11.050000ms referer=None 289s --------------------------- Captured stderr teardown --------------------------- 289s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 289s return _run_code(code, main_globals, None, 289s "__main__", mod_spec) 289s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 289s exec(code, run_globals) 289s ~~~~^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 289s from pathlib import Path 289s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 289s from ._abc import * 289s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 289s from glob import _Globber, _no_recurse_symlinks 289s File "/usr/lib/python3.13/glob.py", line 5, in 289s import re 289s File "/usr/lib/python3.13/re/__init__.py", line 126, in 289s from . import _compiler, _parser 289s File "/usr/lib/python3.13/re/_compiler.py", line 14, in 289s from . import _parser 289s File "", line 1360, in _find_and_load 289s File "", line 1331, in _find_and_load_unlocked 289s File "", line 935, in _load_unlocked 289s File "", line 1019, in exec_module 289s File "", line 1115, in get_code 289s File "", line 1215, in get_data 289s KeyboardInterrupt 289s ______________________ KernelAPITest.test_kernel_handler _______________________ 289s 289s self = 289s 289s def test_kernel_handler(self): 289s # GET kernel with given id 289s kid = self.kern_api.start().json()['id'] 289s r = self.kern_api.get(kid) 289s kern1 = r.json() 289s self.assertEqual(r.status_code, 200) 289s assert isinstance(kern1, dict) 289s self.assertIn('id', kern1) 289s self.assertEqual(kern1['id'], kid) 289s 289s # Request a bad kernel id and check that a JSON 289s # message is returned! 289s bad_id = '111-111-111-111-111' 289s with assert_http_error(404, 'Kernel does not exist: ' + bad_id): 289s self.kern_api.get(bad_id) 289s 289s # DELETE kernel with id 289s > r = self.kern_api.shutdown(kid) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:169: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/7fb72e56-6858-4cc2-861f-5d06272a00f2 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ----------------------------- Captured stderr call ----------------------------- 289s Traceback (most recent call last): 289s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 289s return _run_code(code, main_globals, None, 289s "__main__", mod_spec) 289s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 289s exec(code, run_globals) 289s ~~~~^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 289s from pathlib import Path 289s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 289s from ._abc import * 289s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 289s from glob import _Globber, _no_recurse_symlinks 289s File "/usr/lib/python3.13/glob.py", line 5, in 289s import re 289s File "/usr/lib/python3.13/re/__init__.py", line 125, in 289s import enum 289s File "/usr/lib/python3.13/enum.py", line 1343, in 289s class ReprEnum(Enum): 289s ...<2 lines>... 289s """ 289s File "/usr/lib/python3.13/enum.py", line 491, in __prepare__ 289s member_type, first_enum = metacls._get_mixins_(cls, bases) 289s ~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^ 289s File "/usr/lib/python3.13/enum.py", line 962, in _get_mixins_ 289s member_type = mcls._find_data_type_(class_name, bases) or object 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3.13/enum.py", line 987, in _find_data_type_ 289s @classmethod 289s 289s KeyboardInterrupt 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp2xntu6k7/runtime/kernel-7fb72e56-6858-4cc2-861f-5d06272a00f2.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:56065 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:41627 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: 7fb72e56-6858-4cc2-861f-5d06272a00f2, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 18.210000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/7fb72e56-6858-4cc2-861f-5d06272a00f2 (127.0.0.1) 1.370000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s WARNING NotebookApp:web.py:1943 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1): Kernel does not exist: 111-111-111-111-111 289s WARNING NotebookApp:handlers.py:612 Kernel does not exist: 111-111-111-111-111 289s WARNING NotebookApp:log.py:59 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1) 1.090000ms referer=None 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 7fb72e56-6858-4cc2-861f-5d06272a00f2 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 7fb72e56-6858-4cc2-861f-5d06272a00f2 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/7fb72e56-6858-4cc2-861f-5d06272a00f2 (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/7fb72e56-6858-4cc2-861f-5d06272a00f2', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 289s yielded = ctx_run(next, result) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 289s yield maybe_future(km.shutdown_kernel(kernel_id)) 289s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 289s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 289s stopper = ensure_async(km.shutdown_kernel(now, restart)) 289s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/7fb72e56-6858-4cc2-861f-5d06272a00f2 (127.0.0.1) 10.250000ms referer=None 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.020000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 455dd117-d57f-42e9-9098-770f0c3aa4dc 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 455dd117-d57f-42e9-9098-770f0c3aa4dc 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/455dd117-d57f-42e9-9098-770f0c3aa4dc (127.0.0.1) 1.420000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 7fb72e56-6858-4cc2-861f-5d06272a00f2 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 7fb72e56-6858-4cc2-861f-5d06272a00f2 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/7fb72e56-6858-4cc2-861f-5d06272a00f2 (127.0.0.1) 1.480000ms 289s ____________________ KernelAPITest.test_main_kernel_handler ____________________ 289s 289s self = 289s 289s def test_main_kernel_handler(self): 289s # POST request 289s r = self.kern_api.start() 289s kern1 = r.json() 289s self.assertEqual(r.headers['location'], url_path_join(self.url_prefix, 'api/kernels', kern1['id'])) 289s self.assertEqual(r.status_code, 201) 289s self.assertIsInstance(kern1, dict) 289s 289s report_uri = url_path_join(self.url_prefix, 'api/security/csp-report') 289s expected_csp = '; '.join([ 289s "frame-ancestors 'self'", 289s 'report-uri ' + report_uri, 289s "default-src 'none'" 289s ]) 289s self.assertEqual(r.headers['Content-Security-Policy'], expected_csp) 289s 289s # GET request 289s r = self.kern_api.list() 289s self.assertEqual(r.status_code, 200) 289s assert isinstance(r.json(), list) 289s self.assertEqual(r.json()[0]['id'], kern1['id']) 289s self.assertEqual(r.json()[0]['name'], kern1['name']) 289s 289s # create another kernel and check that they both are added to the 289s # list of kernels from a GET request 289s kern2 = self.kern_api.start().json() 289s assert isinstance(kern2, dict) 289s r = self.kern_api.list() 289s kernels = r.json() 289s self.assertEqual(r.status_code, 200) 289s assert isinstance(kernels, list) 289s self.assertEqual(len(kernels), 2) 289s 289s # Interrupt a kernel 289s r = self.kern_api.interrupt(kern2['id']) 289s self.assertEqual(r.status_code, 204) 289s 289s # Restart a kernel 289s > r = self.kern_api.restart(kern2['id']) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:147: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:63: in restart 289s return self._req('POST', url_path_join(id, 'restart')) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: http://localhost:12341/a%40b/api/kernels/1fb7a04c-8c2a-44ab-91a2-cbd43084e43e/restart 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ----------------------------- Captured stderr call ----------------------------- 289s Traceback (most recent call last): 289s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 289s return _run_code(code, main_globals, None, 289s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 289s exec(code, run_globals) 289s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 289s from pathlib import Path 289s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 289s from ._abc import * 289s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 289s from glob import _Globber, _no_recurse_symlinks 289s File "/usr/lib/python3.13/glob.py", line 5, in 289s import re 289s File "/usr/lib/python3.13/re/__init__.py", line 125, in 289s import enum 289s File "/usr/lib/python3.13/enum.py", line 339, in 289s class EnumDict(dict): 289s File "/usr/lib/python3.13/enum.py", line 238, in __set_name__ 289s def __set_name__(self, ownerclass, name): 289s KeyboardInterrupt 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp2xntu6k7/runtime/kernel-42c3c86a-374d-4e65-a416-295da1480d2f.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:39935 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:38153 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: 42c3c86a-374d-4e65-a416-295da1480d2f, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 19.800000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.990000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmp2xntu6k7/runtime/kernel-1fb7a04c-8c2a-44ab-91a2-cbd43084e43e.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:40671 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:47643 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: 1fb7a04c-8c2a-44ab-91a2-cbd43084e43e, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 20.990000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.990000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: 1fb7a04c-8c2a-44ab-91a2-cbd43084e43e 289s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/1fb7a04c-8c2a-44ab-91a2-cbd43084e43e/interrupt (127.0.0.1) 1.440000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 289s yield maybe_future(km.restart_kernel(kernel_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 289s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 289s await ensure_async(kernel.restart_kernel(now=now)) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 289s await self._async_shutdown_kernel(now=now, restart=True) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/1fb7a04c-8c2a-44ab-91a2-cbd43084e43e/restart (127.0.0.1) 5.470000ms referer=None 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.960000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 42c3c86a-374d-4e65-a416-295da1480d2f 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 42c3c86a-374d-4e65-a416-295da1480d2f 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/42c3c86a-374d-4e65-a416-295da1480d2f (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/42c3c86a-374d-4e65-a416-295da1480d2f', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 239, in wrapper 289s yielded = ctx_run(next, result) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 289s yield maybe_future(km.shutdown_kernel(kernel_id)) 289s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 289s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 289s stopper = ensure_async(km.shutdown_kernel(now, restart)) 289s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/42c3c86a-374d-4e65-a416-295da1480d2f (127.0.0.1) 9.700000ms referer=None 289s ________________________ KernelAPITest.test_no_kernels _________________________ 289s 289s self = 289s 289s def test_no_kernels(self): 289s """Make sure there are no kernels running at the start""" 289s kernels = self.kern_api.list().json() 289s > self.assertEqual(kernels, []) 289s E AssertionError: Lists differ: [{'id': '42c3c86a-374d-4e65-a416-295da1480[281 chars]: 0}] != [] 289s E 289s E First list contains 2 additional elements. 289s E First extra element 0: 289s E {'id': '42c3c86a-374d-4e65-a416-295da1480d2f', 'name': 'python3', 'last_activity': '2026-02-06T04:19:19.555455Z', 'execution_state': 'starting', 'connections': 0} 289s E 289s E + [] 289s E - [{'connections': 0, 289s E - 'execution_state': 'starting', 289s E - 'id': '42c3c86a-374d-4e65-a416-295da1480d2f', 289s E - 'last_activity': '2026-02-06T04:19:19.555455Z', 289s E - 'name': 'python3'}, 289s E - {'connections': 0, 289s E - 'execution_state': 'starting', 289s E - 'id': '1fb7a04c-8c2a-44ab-91a2-cbd43084e43e', 289s E - 'last_activity': '2026-02-06T04:19:19.583375Z', 289s E - 'name': 'python3'}] 289s 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:91: AssertionError 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.150000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.970000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 42c3c86a-374d-4e65-a416-295da1480d2f 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 42c3c86a-374d-4e65-a416-295da1480d2f 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/42c3c86a-374d-4e65-a416-295da1480d2f (127.0.0.1) 1.980000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 1fb7a04c-8c2a-44ab-91a2-cbd43084e43e 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 1fb7a04c-8c2a-44ab-91a2-cbd43084e43e 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/1fb7a04c-8c2a-44ab-91a2-cbd43084e43e (127.0.0.1) 1.910000ms 289s ---------------------------- Captured log teardown ----------------------------- 289s INFO NotebookApp:notebookapp.py:2164 Shutting down 0 kernels 289s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 289s _____________________ AsyncKernelAPITest.test_connections ______________________ 289s 289s self = 289s 289s def tearDown(self): 289s for k in self.kern_api.list().json(): 289s > self.kern_api.shutdown(k['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/604e3a61-90b4-47ec-8b16-0f24662f4309 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ------------------------------ Captured log setup ------------------------------ 289s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmpsua20r9t/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmpsua20r9t/etc/jupyter'] for config files 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpsua20r9t/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpsua20r9t/config 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpsua20r9t/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpsua20r9t/config 289s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmpsua20r9t/notebooks 289s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 289s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 289s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 289s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 289s WARNING NotebookApp:handlers.py:612 Forbidden 289s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 0.800000ms referer=None 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpsua20r9t/runtime/kernel-604e3a61-90b4-47ec-8b16-0f24662f4309.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:49167 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:42387 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: 604e3a61-90b4-47ec-8b16-0f24662f4309, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 17.260000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/604e3a61-90b4-47ec-8b16-0f24662f4309 (127.0.0.1) 1.000000ms 289s DEBUG NotebookApp:zmqhandlers.py:298 Initializing websocket connection /a%40b/api/kernels/604e3a61-90b4-47ec-8b16-0f24662f4309/channels 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s WARNING NotebookApp:zmqhandlers.py:286 No session ID specified 289s DEBUG NotebookApp:handlers.py:277 Requesting kernel info from 604e3a61-90b4-47ec-8b16-0f24662f4309 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:58841 289s DEBUG NotebookApp:kernelmanager.py:423 activity on 604e3a61-90b4-47ec-8b16-0f24662f4309: status (starting) 289s DEBUG NotebookApp:kernelmanager.py:423 activity on 604e3a61-90b4-47ec-8b16-0f24662f4309: status (busy) 289s DEBUG NotebookApp:handlers.py:306 Received kernel info: {'status': 'ok', 'protocol_version': '5.3', 'implementation': 'ipython', 'implementation_version': '8.35.0', 'language_info': {'name': 'python', 'version': '3.13.11', 'mimetype': 'text/x-python', 'codemirror_mode': {'name': 'ipython', 'version': 3}, 'pygments_lexer': 'ipython3', 'nbconvert_exporter': 'python', 'file_extension': '.py'}, 'banner': "Python 3.13.11 (main, Dec 6 2025, 13:15:20) [GCC 15.2.0]\nType 'copyright', 'credits' or 'license' for more information\nIPython 8.35.0 -- An enhanced Interactive Python. Type '?' for help.\n", 'help_links': [{'text': 'Python Reference', 'url': 'https://docs.python.org/3.13'}, {'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/'}]} 289s INFO NotebookApp:handlers.py:326 Adapting from protocol version 5.3 (kernel 604e3a61-90b4-47ec-8b16-0f24662f4309) to 5.4 (client). 289s DEBUG NotebookApp:kernelmanager.py:423 activity on 604e3a61-90b4-47ec-8b16-0f24662f4309: status (idle) 289s DEBUG NotebookApp:log.py:59 101 GET /a%40b/api/kernels/604e3a61-90b4-47ec-8b16-0f24662f4309/channels (127.0.0.1) 623.080000ms 289s DEBUG NotebookApp:zmqhandlers.py:159 Opening websocket /a%40b/api/kernels/604e3a61-90b4-47ec-8b16-0f24662f4309/channels 289s DEBUG NotebookApp:kernelmanager.py:252 Getting buffer for 604e3a61-90b4-47ec-8b16-0f24662f4309 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:42387 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:58841 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:49167 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:56709 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:58841 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:49167 289s WARNING NotebookApp:websocket.py:1327 The websocket_ping_timeout (90000) cannot be longer than the websocket_ping_interval (30000). 289s Setting websocket_ping_timeout=30000 289s DEBUG NotebookApp:handlers.py:255 Nudge: attempt 1 on kernel 604e3a61-90b4-47ec-8b16-0f24662f4309 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/604e3a61-90b4-47ec-8b16-0f24662f4309 (127.0.0.1) 1.170000ms 289s DEBUG NotebookApp:kernelmanager.py:423 activity on 604e3a61-90b4-47ec-8b16-0f24662f4309: status (busy) 289s DEBUG NotebookApp:kernelmanager.py:423 activity on 604e3a61-90b4-47ec-8b16-0f24662f4309: status (busy) 289s DEBUG NotebookApp:handlers.py:207 Nudge: IOPub received: 604e3a61-90b4-47ec-8b16-0f24662f4309 289s DEBUG NotebookApp:handlers.py:210 Nudge: resolving iopub future: 604e3a61-90b4-47ec-8b16-0f24662f4309 289s DEBUG NotebookApp:handlers.py:195 Nudge: shell info reply received: 604e3a61-90b4-47ec-8b16-0f24662f4309 289s DEBUG NotebookApp:handlers.py:197 Nudge: resolving shell future: 604e3a61-90b4-47ec-8b16-0f24662f4309 289s DEBUG NotebookApp:kernelmanager.py:423 activity on 604e3a61-90b4-47ec-8b16-0f24662f4309: status (idle) 289s DEBUG NotebookApp:kernelmanager.py:423 activity on 604e3a61-90b4-47ec-8b16-0f24662f4309: status (idle) 289s DEBUG NotebookApp:handlers.py:579 Websocket closed 604e3a61-90b4-47ec-8b16-0f24662f4309:6d502b1e-0a030fda02a7c8c8a7a6e8cc 289s INFO NotebookApp:kernelmanager.py:222 Starting buffering for 604e3a61-90b4-47ec-8b16-0f24662f4309:6d502b1e-0a030fda02a7c8c8a7a6e8cc 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 604e3a61-90b4-47ec-8b16-0f24662f4309 289s DEBUG NotebookApp:kernelmanager.py:235 Buffering msg on 604e3a61-90b4-47ec-8b16-0f24662f4309:iopub 289s DEBUG NotebookApp:kernelmanager.py:235 Buffering msg on 604e3a61-90b4-47ec-8b16-0f24662f4309:iopub 289s DEBUG NotebookApp:kernelmanager.py:235 Buffering msg on 604e3a61-90b4-47ec-8b16-0f24662f4309:iopub 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/604e3a61-90b4-47ec-8b16-0f24662f4309 (127.0.0.1) 1.030000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/604e3a61-90b4-47ec-8b16-0f24662f4309 (127.0.0.1) 1.100000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.090000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 604e3a61-90b4-47ec-8b16-0f24662f4309 289s INFO NotebookApp:kernelmanager.py:286 Discarding 3 buffered messages for 604e3a61-90b4-47ec-8b16-0f24662f4309:6d502b1e-0a030fda02a7c8c8a7a6e8cc 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 604e3a61-90b4-47ec-8b16-0f24662f4309 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/604e3a61-90b4-47ec-8b16-0f24662f4309 (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/604e3a61-90b4-47ec-8b16-0f24662f4309', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 289s future.result() 289s ~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 289s yield maybe_future(km.shutdown_kernel(kernel_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 289s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 289s raise km.ready.exception() # type: ignore[misc] 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/604e3a61-90b4-47ec-8b16-0f24662f4309 (127.0.0.1) 8.460000ms referer=None 289s ____________________ AsyncKernelAPITest.test_default_kernel ____________________ 289s 289s self = 289s 289s def tearDown(self): 289s for k in self.kern_api.list().json(): 289s > self.kern_api.shutdown(k['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:86: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/f5a1d52e-0318-42bd-93b9-e9be41c565c7 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ----------------------------- Captured stderr call ----------------------------- 289s Traceback (most recent call last): 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpsua20r9t/runtime/kernel-f5a1d52e-0318-42bd-93b9-e9be41c565c7.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:58949 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:58303 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: f5a1d52e-0318-42bd-93b9-e9be41c565c7, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 17.070000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 2.800000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 604e3a61-90b4-47ec-8b16-0f24662f4309 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 604e3a61-90b4-47ec-8b16-0f24662f4309 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/604e3a61-90b4-47ec-8b16-0f24662f4309 (127.0.0.1) 2.250000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for f5a1d52e-0318-42bd-93b9-e9be41c565c7 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: f5a1d52e-0318-42bd-93b9-e9be41c565c7 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/f5a1d52e-0318-42bd-93b9-e9be41c565c7 (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/f5a1d52e-0318-42bd-93b9-e9be41c565c7', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 289s future.result() 289s ~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 289s yield maybe_future(km.shutdown_kernel(kernel_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 289s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 289s raise km.ready.exception() # type: ignore[misc] 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/f5a1d52e-0318-42bd-93b9-e9be41c565c7 (127.0.0.1) 9.200000ms referer=None 289s --------------------------- Captured stderr teardown --------------------------- 289s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 289s return _run_code(code, main_globals, None, 289s "__main__", mod_spec) 289s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 289s exec(code, run_globals) 289s ~~~~^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 289s from pathlib import Path 289s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 289s from ._abc import * 289s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 289s from glob import _Globber, _no_recurse_symlinks 289s File "/usr/lib/python3.13/glob.py", line 5, in 289s import re 289s File "/usr/lib/python3.13/re/__init__.py", line 126, in 289s from . import _compiler, _parser 289s File "/usr/lib/python3.13/re/_compiler.py", line 13, in 289s import _sre 289s File "", line 1349, in _find_and_load 289s KeyboardInterrupt 289s ____________________ AsyncKernelAPITest.test_kernel_handler ____________________ 289s 289s self = 289s 289s def test_kernel_handler(self): 289s # GET kernel with given id 289s kid = self.kern_api.start().json()['id'] 289s r = self.kern_api.get(kid) 289s kern1 = r.json() 289s self.assertEqual(r.status_code, 200) 289s assert isinstance(kern1, dict) 289s self.assertIn('id', kern1) 289s self.assertEqual(kern1['id'], kid) 289s 289s # Request a bad kernel id and check that a JSON 289s # message is returned! 289s bad_id = '111-111-111-111-111' 289s with assert_http_error(404, 'Kernel does not exist: ' + bad_id): 289s self.kern_api.get(bad_id) 289s 289s # DELETE kernel with id 289s > r = self.kern_api.shutdown(kid) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:169: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:57: in shutdown 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/kernels/2f88aa75-5b93-4c35-a4f5-eca2b9c187e4 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ----------------------------- Captured stderr call ----------------------------- 289s Traceback (most recent call last): 289s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 289s return _run_code(code, main_globals, None, 289s "__main__", mod_spec) 289s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 289s exec(code, run_globals) 289s ~~~~^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 289s from pathlib import Path 289s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 289s from ._abc import * 289s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 289s from glob import _Globber, _no_recurse_symlinks 289s File "/usr/lib/python3.13/glob.py", line 5, in 289s import re 289s File "/usr/lib/python3.13/re/__init__.py", line 125, in 289s import enum 289s File "/usr/lib/python3.13/enum.py", line 1398, in 289s class FlagBoundary(StrEnum): 289s ...<10 lines>... 289s KEEP = auto() 289s File "/usr/lib/python3.13/enum.py", line 498, in __new__ 289s def __new__(metacls, cls, bases, classdict, *, boundary=None, _simple=False, **kwds): 289s 289s KeyboardInterrupt 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpsua20r9t/runtime/kernel-2f88aa75-5b93-4c35-a4f5-eca2b9c187e4.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:54285 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:52447 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: 2f88aa75-5b93-4c35-a4f5-eca2b9c187e4, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 18.630000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels/2f88aa75-5b93-4c35-a4f5-eca2b9c187e4 (127.0.0.1) 1.050000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s WARNING NotebookApp:web.py:1943 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1): Kernel does not exist: 111-111-111-111-111 289s WARNING NotebookApp:handlers.py:612 Kernel does not exist: 111-111-111-111-111 289s WARNING NotebookApp:log.py:59 404 GET /a%40b/api/kernels/111-111-111-111-111 (127.0.0.1) 1.090000ms referer=None 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 2f88aa75-5b93-4c35-a4f5-eca2b9c187e4 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 2f88aa75-5b93-4c35-a4f5-eca2b9c187e4 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/2f88aa75-5b93-4c35-a4f5-eca2b9c187e4 (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/2f88aa75-5b93-4c35-a4f5-eca2b9c187e4', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 289s future.result() 289s ~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 289s yield maybe_future(km.shutdown_kernel(kernel_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 289s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 289s raise km.ready.exception() # type: ignore[misc] 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/2f88aa75-5b93-4c35-a4f5-eca2b9c187e4 (127.0.0.1) 8.120000ms referer=None 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.160000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for f5a1d52e-0318-42bd-93b9-e9be41c565c7 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: f5a1d52e-0318-42bd-93b9-e9be41c565c7 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/f5a1d52e-0318-42bd-93b9-e9be41c565c7 (127.0.0.1) 1.120000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 2f88aa75-5b93-4c35-a4f5-eca2b9c187e4 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 2f88aa75-5b93-4c35-a4f5-eca2b9c187e4 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/2f88aa75-5b93-4c35-a4f5-eca2b9c187e4 (127.0.0.1) 1.100000ms 289s _________________ AsyncKernelAPITest.test_main_kernel_handler __________________ 289s 289s self = 289s 289s def test_main_kernel_handler(self): 289s # POST request 289s r = self.kern_api.start() 289s kern1 = r.json() 289s self.assertEqual(r.headers['location'], url_path_join(self.url_prefix, 'api/kernels', kern1['id'])) 289s self.assertEqual(r.status_code, 201) 289s self.assertIsInstance(kern1, dict) 289s 289s report_uri = url_path_join(self.url_prefix, 'api/security/csp-report') 289s expected_csp = '; '.join([ 289s "frame-ancestors 'self'", 289s 'report-uri ' + report_uri, 289s "default-src 'none'" 289s ]) 289s self.assertEqual(r.headers['Content-Security-Policy'], expected_csp) 289s 289s # GET request 289s r = self.kern_api.list() 289s self.assertEqual(r.status_code, 200) 289s assert isinstance(r.json(), list) 289s self.assertEqual(r.json()[0]['id'], kern1['id']) 289s self.assertEqual(r.json()[0]['name'], kern1['name']) 289s 289s # create another kernel and check that they both are added to the 289s # list of kernels from a GET request 289s kern2 = self.kern_api.start().json() 289s assert isinstance(kern2, dict) 289s r = self.kern_api.list() 289s kernels = r.json() 289s self.assertEqual(r.status_code, 200) 289s assert isinstance(kernels, list) 289s self.assertEqual(len(kernels), 2) 289s 289s # Interrupt a kernel 289s r = self.kern_api.interrupt(kern2['id']) 289s self.assertEqual(r.status_code, 204) 289s 289s # Restart a kernel 289s > r = self.kern_api.restart(kern2['id']) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:147: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:63: in restart 289s return self._req('POST', url_path_join(id, 'restart')) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:42: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: http://localhost:12341/a%40b/api/kernels/ba47f4b9-1327-4019-8691-247f3273e7e0/restart 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ----------------------------- Captured stderr call ----------------------------- 289s Traceback (most recent call last): 289s File "/usr/lib/python3.13/runpy.py", line 189, in _run_module_as_main 289s mod_name, mod_spec, code = _get_module_details(mod_name, _Error) 289s File "/usr/lib/python3.13/runpy.py", line 131, in _get_module_details 289s spec = importlib.util.find_spec(mod_name) 289s File "/usr/lib/python3.13/importlib/util.py", line 100, in find_spec 289s return _find_spec(fullname, parent_path) 289s File "", line 1262, in _find_spec 289s File "", line 1556, in find_spec 289s File "", line 1530, in _get_spec 289s File "", line 1629, in find_spec 289s File "", line 152, in _path_stat 289s KeyboardInterrupt 289s Traceback (most recent call last): 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpsua20r9t/runtime/kernel-afbd8724-e283-4418-8788-8e612f096519.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:33869 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:52571 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: afbd8724-e283-4418-8788-8e612f096519, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.470000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.040000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpsua20r9t/runtime/kernel-ba47f4b9-1327-4019-8691-247f3273e7e0.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:60895 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:55359 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: ba47f4b9-1327-4019-8691-247f3273e7e0, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 17.080000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.640000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s INFO NotebookApp:multikernelmanager.py:396 Kernel interrupted: ba47f4b9-1327-4019-8691-247f3273e7e0 289s DEBUG NotebookApp:log.py:59 204 POST /a%40b/api/kernels/ba47f4b9-1327-4019-8691-247f3273e7e0/interrupt (127.0.0.1) 1.200000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:handlers.py:91 Exception restarting kernel 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 89, in post 289s yield maybe_future(km.restart_kernel(kernel_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 291, in __step_run_and_handle_result 289s result = coro.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 314, in restart_kernel 289s await maybe_future(self.pinned_superclass.restart_kernel(self, kernel_id, now=now)) 289s File "/usr/lib/python3.14/asyncio/futures.py", line 295, in __await__ 289s yield self # This tells Task to wait for completion. 289s ^^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 289s future.result() 289s ~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 434, in _async_restart_kernel 289s await ensure_async(kernel.restart_kernel(now=now)) 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 590, in _async_restart_kernel 289s await self._async_shutdown_kernel(now=now, restart=True) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 POST /a%40b/api/kernels/ba47f4b9-1327-4019-8691-247f3273e7e0/restart (127.0.0.1) 4.300000ms referer=None 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.840000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for afbd8724-e283-4418-8788-8e612f096519 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: afbd8724-e283-4418-8788-8e612f096519 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/kernels/afbd8724-e283-4418-8788-8e612f096519 (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/kernels/afbd8724-e283-4418-8788-8e612f096519', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 289s future.result() 289s ~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/handlers.py", line 72, in delete 289s yield maybe_future(km.shutdown_kernel(kernel_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 289s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 289s raise km.ready.exception() # type: ignore[misc] 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/kernels/afbd8724-e283-4418-8788-8e612f096519 (127.0.0.1) 8.680000ms referer=None 289s ______________________ AsyncKernelAPITest.test_no_kernels ______________________ 289s 289s self = 289s 289s def test_no_kernels(self): 289s """Make sure there are no kernels running at the start""" 289s kernels = self.kern_api.list().json() 289s > self.assertEqual(kernels, []) 289s E AssertionError: Lists differ: [{'id': 'afbd8724-e283-4418-8788-8e612f096[281 chars]: 0}] != [] 289s E 289s E First list contains 2 additional elements. 289s E First extra element 0: 289s E {'id': 'afbd8724-e283-4418-8788-8e612f096519', 'name': 'python3', 'last_activity': '2026-02-06T04:19:20.650483Z', 'execution_state': 'starting', 'connections': 0} 289s E 289s E + [] 289s E - [{'connections': 0, 289s E - 'execution_state': 'starting', 289s E - 'id': 'afbd8724-e283-4418-8788-8e612f096519', 289s E - 'last_activity': '2026-02-06T04:19:20.650483Z', 289s E - 'name': 'python3'}, 289s E - {'connections': 0, 289s E - 'execution_state': 'starting', 289s E - 'id': 'ba47f4b9-1327-4019-8691-247f3273e7e0', 289s E - 'last_activity': '2026-02-06T04:19:20.674029Z', 289s E - 'name': 'python3'}] 289s 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:91: AssertionError 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.040000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.960000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for afbd8724-e283-4418-8788-8e612f096519 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: afbd8724-e283-4418-8788-8e612f096519 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/afbd8724-e283-4418-8788-8e612f096519 (127.0.0.1) 1.100000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ba47f4b9-1327-4019-8691-247f3273e7e0 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ba47f4b9-1327-4019-8691-247f3273e7e0 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/kernels/ba47f4b9-1327-4019-8691-247f3273e7e0 (127.0.0.1) 1.570000ms 289s ---------------------------- Captured log teardown ----------------------------- 289s INFO NotebookApp:notebookapp.py:2164 Shutting down 0 kernels 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 604e3a61-90b4-47ec-8b16-0f24662f4309 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: f5a1d52e-0318-42bd-93b9-e9be41c565c7 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: afbd8724-e283-4418-8788-8e612f096519 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 2f88aa75-5b93-4c35-a4f5-eca2b9c187e4 289s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 289s __________________________ SessionAPITest.test_create __________________________ 289s 289s @self.addCleanup 289s def cleanup_sessions(): 289s for session in self.sess_api.list().json(): 289s > self.sess_api.delete(session['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/27cab13b-0201-4625-b5a1-702c29432fc2 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ------------------------------ Captured log setup ------------------------------ 289s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmpmvyldrpd/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmpmvyldrpd/etc/jupyter'] for config files 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpmvyldrpd/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpmvyldrpd/config 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpmvyldrpd/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpmvyldrpd/config 289s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmpmvyldrpd/notebooks 289s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 289s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 289s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 289s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 289s WARNING NotebookApp:handlers.py:612 Forbidden 289s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 0.800000ms referer=None 289s ----------------------------- Captured stderr call ----------------------------- 289s Traceback (most recent call last): 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.460000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpmvyldrpd/runtime/kernel-0f56e730-d62d-4967-afe3-6ed0e1bef0cd.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:50079 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:37421 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: 0f56e730-d62d-4967-afe3-6ed0e1bef0cd, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpmvyldrpd/notebooks/foo'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 21.610000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.260000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions/27cab13b-0201-4625-b5a1-702c29432fc2 (127.0.0.1) 1.080000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 2.740000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 0f56e730-d62d-4967-afe3-6ed0e1bef0cd 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0f56e730-d62d-4967-afe3-6ed0e1bef0cd 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/27cab13b-0201-4625-b5a1-702c29432fc2 (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/27cab13b-0201-4625-b5a1-702c29432fc2', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 289s yield maybe_future(sm.delete_session(session_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 289s yielded = self.gen.send(value) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 289s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 289s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 289s stopper = ensure_async(km.shutdown_kernel(now, restart)) 289s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/27cab13b-0201-4625-b5a1-702c29432fc2 (127.0.0.1) 9.100000ms referer=None 289s --------------------------- Captured stderr teardown --------------------------- 289s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 289s return _run_code(code, main_globals, None, 289s "__main__", mod_spec) 289s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 289s exec(code, run_globals) 289s ~~~~^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 289s from ipykernel import kernelapp as app 289s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 289s from .connect import * # noqa: F403 289s ^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 7, in 289s import json 289s File "/usr/lib/python3.13/json/__init__.py", line 106, in 289s from .decoder import JSONDecoder, JSONDecodeError 289s File "", line 1360, in _find_and_load 289s File "", line 1331, in _find_and_load_unlocked 289s File "", line 935, in _load_unlocked 289s File "", line 1019, in exec_module 289s File "", line 1152, in get_code 289s File "", line 781, in _compile_bytecode 289s KeyboardInterrupt 289s __________________ SessionAPITest.test_create_console_session __________________ 289s 289s @self.addCleanup 289s def cleanup_sessions(): 289s for session in self.sess_api.list().json(): 289s > self.sess_api.delete(session['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/2b89ef0f-572d-4368-a356-2972f5c53eed 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ----------------------------- Captured stderr call ----------------------------- 289s Traceback (most recent call last): 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpmvyldrpd/runtime/kernel-fe18334d-ed06-486a-be7b-ff0f291b5117.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:45583 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:60165 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: fe18334d-ed06-486a-be7b-ff0f291b5117, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpmvyldrpd/notebooks/foo'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 18.020000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 2.020000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 0f56e730-d62d-4967-afe3-6ed0e1bef0cd 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0f56e730-d62d-4967-afe3-6ed0e1bef0cd 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/27cab13b-0201-4625-b5a1-702c29432fc2 (127.0.0.1) 1.740000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for fe18334d-ed06-486a-be7b-ff0f291b5117 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: fe18334d-ed06-486a-be7b-ff0f291b5117 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/2b89ef0f-572d-4368-a356-2972f5c53eed (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/2b89ef0f-572d-4368-a356-2972f5c53eed', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 289s yield maybe_future(sm.delete_session(session_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 289s yielded = self.gen.send(value) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 289s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 289s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 289s stopper = ensure_async(km.shutdown_kernel(now, restart)) 289s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/2b89ef0f-572d-4368-a356-2972f5c53eed (127.0.0.1) 9.090000ms referer=None 289s --------------------------- Captured stderr teardown --------------------------- 289s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 289s return _run_code(code, main_globals, None, 289s "__main__", mod_spec) 289s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 289s exec(code, run_globals) 289s ~~~~^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 289s from pathlib import Path 289s File "/usr/lib/python3.13/pathlib/__init__.py", line 9, in 289s from ._local import * 289s File "", line 1357, in _find_and_load 289s File "", line 418, in __enter__ 289s File "", line 316, in acquire 289s KeyboardInterrupt 289s ____________________ SessionAPITest.test_create_deprecated _____________________ 289s 289s @self.addCleanup 289s def cleanup_sessions(): 289s for session in self.sess_api.list().json(): 289s > self.sess_api.delete(session['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/9b3f96a8-95e3-4353-a9e1-fc40fff73b34 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ----------------------------- Captured stderr call ----------------------------- 289s Traceback (most recent call last): 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s WARNING NotebookApp:handlers.py:46 Sessions API changed, see updated swagger docs 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpmvyldrpd/runtime/kernel-a02487e6-14ae-4ce9-9c80-a78abbcf7275.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:43989 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:41621 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: a02487e6-14ae-4ce9-9c80-a78abbcf7275, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpmvyldrpd/notebooks/foo'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 18.190000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.270000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for fe18334d-ed06-486a-be7b-ff0f291b5117 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: fe18334d-ed06-486a-be7b-ff0f291b5117 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/2b89ef0f-572d-4368-a356-2972f5c53eed (127.0.0.1) 1.620000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for a02487e6-14ae-4ce9-9c80-a78abbcf7275 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a02487e6-14ae-4ce9-9c80-a78abbcf7275 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/9b3f96a8-95e3-4353-a9e1-fc40fff73b34 (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/9b3f96a8-95e3-4353-a9e1-fc40fff73b34', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 289s yield maybe_future(sm.delete_session(session_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 289s yielded = self.gen.send(value) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 289s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 289s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 289s stopper = ensure_async(km.shutdown_kernel(now, restart)) 289s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/9b3f96a8-95e3-4353-a9e1-fc40fff73b34 (127.0.0.1) 8.750000ms referer=None 289s --------------------------- Captured stderr teardown --------------------------- 289s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 289s return _run_code(code, main_globals, None, 289s "__main__", mod_spec) 289s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 289s exec(code, run_globals) 289s ~~~~^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 289s from pathlib import Path 289s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 289s from ._abc import * 289s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 289s from glob import _Globber, _no_recurse_symlinks 289s File "/usr/lib/python3.13/glob.py", line 5, in 289s import re 289s File "/usr/lib/python3.13/re/__init__.py", line 126, in 289s from . import _compiler, _parser 289s File "/usr/lib/python3.13/re/_compiler.py", line 16, in 289s from ._casefix import _EXTRA_CASES 289s File "", line 1360, in _find_and_load 289s File "", line 1331, in _find_and_load_unlocked 289s File "", line 935, in _load_unlocked 289s File "", line 1019, in exec_module 289s File "", line 1115, in get_code 289s File "", line 1215, in get_data 289s KeyboardInterrupt 289s ___________________ SessionAPITest.test_create_file_session ____________________ 289s 289s @self.addCleanup 289s def cleanup_sessions(): 289s for session in self.sess_api.list().json(): 289s > self.sess_api.delete(session['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/c6f195f7-de29-4f0f-8dc0-bce69e3ea792 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpmvyldrpd/runtime/kernel-71892635-e5d7-4a54-a51a-e9f804a6d12b.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34141 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:35993 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: 71892635-e5d7-4a54-a51a-e9f804a6d12b, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpmvyldrpd/notebooks/foo'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 18.030000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.080000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for a02487e6-14ae-4ce9-9c80-a78abbcf7275 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: a02487e6-14ae-4ce9-9c80-a78abbcf7275 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/9b3f96a8-95e3-4353-a9e1-fc40fff73b34 (127.0.0.1) 1.520000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 71892635-e5d7-4a54-a51a-e9f804a6d12b 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 71892635-e5d7-4a54-a51a-e9f804a6d12b 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/c6f195f7-de29-4f0f-8dc0-bce69e3ea792 (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/c6f195f7-de29-4f0f-8dc0-bce69e3ea792', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 289s yield maybe_future(sm.delete_session(session_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 289s yielded = self.gen.send(value) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 289s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 289s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 289s stopper = ensure_async(km.shutdown_kernel(now, restart)) 289s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/c6f195f7-de29-4f0f-8dc0-bce69e3ea792 (127.0.0.1) 9.590000ms referer=None 289s --------------------------- Captured stderr teardown --------------------------- 289s Traceback (most recent call last): 289s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 289s return _run_code(code, main_globals, None, 289s "__main__", mod_spec) 289s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 289s exec(code, run_globals) 289s ~~~~^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 289s from pathlib import Path 289s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 289s from ._abc import * 289s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 289s from glob import _Globber, _no_recurse_symlinks 289s File "/usr/lib/python3.13/glob.py", line 5, in 289s import re 289s File "/usr/lib/python3.13/re/__init__.py", line 125, in 289s import enum 289s File "/usr/lib/python3.13/enum.py", line 23, in 289s class nonmember(object): 289s ...<4 lines>... 289s self.value = value 289s KeyboardInterrupt 289s __________________ SessionAPITest.test_create_with_kernel_id ___________________ 289s 289s self = 289s 289s def test_create_with_kernel_id(self): 289s # create a new kernel 289s r = self.request('POST', 'api/kernels') 289s r.raise_for_status() 289s kernel = r.json() 289s 289s resp = self.sess_api.create('foo/nb1.ipynb', kernel_id=kernel['id']) 289s self.assertEqual(resp.status_code, 201) 289s newsession = resp.json() 289s self.assertIn('id', newsession) 289s self.assertEqual(newsession['path'], 'foo/nb1.ipynb') 289s self.assertEqual(newsession['kernel']['id'], kernel['id']) 289s self.assertEqual(resp.headers['Location'], f'{self.url_prefix}api/sessions/{newsession["id"]}') 289s 289s sessions = self.sess_api.list().json() 289s > self.assertEqual(sessions, [newsession]) 289s E AssertionError: Lists differ: [{'id': 'c6f195f7-de29-4f0f-8dc0-bce69e3ea792', 'p[553 chars]ne}}] != [{'id': '20ecc7fe-3ec9-4ad7-95fa-59042b466c0c', 'p[279 chars]ne}}] 289s E 289s E First differing element 0: 289s E {'id': 'c6f195f7-de29-4f0f-8dc0-bce69e3ea792', 'p[218 chars]: 0}} 289s E {'id': '20ecc7fe-3ec9-4ad7-95fa-59042b466c0c', 'p[278 chars]one}} 289s E 289s E First list contains 1 additional elements. 289s E First extra element 1: 289s E {'id': '20ecc7fe-3ec9-4ad7-95fa-59042b466c0c', 'path': 'foo/nb1.ipynb', 'name': None, 'type': 'notebook', 'kernel': {'id': '0b2c88dc-eb6c-4709-911f-f0c4b426b689', 'name': 'python3', 'last_activity': '2026-02-06T04:19:21.213401Z', 'execution_state': 'starting', 'connections': 0}, 'notebook': {'path': 'foo/nb1.ipynb', 'name': None}} 289s E 289s E Diff is 830 characters long. Set self.maxDiff to None to see it. 289s 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:178: AssertionError 289s ----------------------------- Captured stderr call ----------------------------- 289s Traceback (most recent call last): 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpmvyldrpd/runtime/kernel-0b2c88dc-eb6c-4709-911f-f0c4b426b689.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:46529 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:58751 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: 0b2c88dc-eb6c-4709-911f-f0c4b426b689, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 22.520000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.200000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.160000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.150000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 71892635-e5d7-4a54-a51a-e9f804a6d12b 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 71892635-e5d7-4a54-a51a-e9f804a6d12b 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/c6f195f7-de29-4f0f-8dc0-bce69e3ea792 (127.0.0.1) 1.690000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 0b2c88dc-eb6c-4709-911f-f0c4b426b689 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0b2c88dc-eb6c-4709-911f-f0c4b426b689 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/20ecc7fe-3ec9-4ad7-95fa-59042b466c0c (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/20ecc7fe-3ec9-4ad7-95fa-59042b466c0c', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 289s yield maybe_future(sm.delete_session(session_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 289s yielded = self.gen.send(value) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 289s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 289s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 289s stopper = ensure_async(km.shutdown_kernel(now, restart)) 289s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/20ecc7fe-3ec9-4ad7-95fa-59042b466c0c (127.0.0.1) 9.220000ms referer=None 289s _____________________ SessionAPITest.test_modify_kernel_id _____________________ 289s 289s @self.addCleanup 289s def cleanup_sessions(): 289s for session in self.sess_api.list().json(): 289s > self.sess_api.delete(session['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/20ecc7fe-3ec9-4ad7-95fa-59042b466c0c 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ----------------------------- Captured stderr call ----------------------------- 289s Traceback (most recent call last): 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.210000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpmvyldrpd/runtime/kernel-58387543-b795-43b0-a950-e57699a413c7.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:33905 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:33395 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: 58387543-b795-43b0-a950-e57699a413c7, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 20.340000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 0b2c88dc-eb6c-4709-911f-f0c4b426b689 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0b2c88dc-eb6c-4709-911f-f0c4b426b689 289s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/20ecc7fe-3ec9-4ad7-95fa-59042b466c0c (127.0.0.1) 2.020000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.040000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.010000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 58387543-b795-43b0-a950-e57699a413c7 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 58387543-b795-43b0-a950-e57699a413c7 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/20ecc7fe-3ec9-4ad7-95fa-59042b466c0c (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/20ecc7fe-3ec9-4ad7-95fa-59042b466c0c', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 289s yield maybe_future(sm.delete_session(session_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 289s yielded = self.gen.send(value) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 289s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 289s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 289s stopper = ensure_async(km.shutdown_kernel(now, restart)) 289s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/20ecc7fe-3ec9-4ad7-95fa-59042b466c0c (127.0.0.1) 9.140000ms referer=None 289s --------------------------- Captured stderr teardown --------------------------- 289s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 289s return _run_code(code, main_globals, None, 289s "__main__", mod_spec) 289s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 289s exec(code, run_globals) 289s ~~~~^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 289s from ipykernel import kernelapp as app 289s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 7, in 289s from .connect import * # noqa: F403 289s ^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel/connect.py", line 9, in 289s from subprocess import PIPE, Popen 289s File "", line 1360, in _find_and_load 289s File "", line 1322, in _find_and_load_unlocked 289s File "", line 1262, in _find_spec 289s File "", line 1556, in find_spec 289s File "", line 1530, in _get_spec 289s File "", line 1629, in find_spec 289s File "", line 152, in _path_stat 289s KeyboardInterrupt 289s ____________________ SessionAPITest.test_modify_kernel_name ____________________ 289s 289s @self.addCleanup 289s def cleanup_sessions(): 289s for session in self.sess_api.list().json(): 289s > self.sess_api.delete(session['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/20ecc7fe-3ec9-4ad7-95fa-59042b466c0c 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ----------------------------- Captured stderr call ----------------------------- 289s Traceback (most recent call last): 289s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 289s return _run_code(code, main_globals, None, 289s "__main__", mod_spec) 289s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 289s exec(code, run_globals) 289s ~~~~^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 8, in 289s from pathlib import Path 289s File "/usr/lib/python3.13/pathlib/__init__.py", line 8, in 289s from ._abc import * 289s File "/usr/lib/python3.13/pathlib/_abc.py", line 15, in 289s from glob import _Globber, _no_recurse_symlinks 289s File "/usr/lib/python3.13/glob.py", line 6, in 289s import fnmatch 289s File "", line 1360, in _find_and_load 289s File "", line 1331, in _find_and_load_unlocked 289s File "", line 935, in _load_unlocked 289s File "", line 1019, in exec_module 289s File "", line 1115, in get_code 289s File "", line 1214, in get_data 289s KeyboardInterrupt 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 3.270000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpmvyldrpd/runtime/kernel-d0d4c3d6-a8ff-4ec3-953f-1f7d329598b8.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:42075 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:54787 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: d0d4c3d6-a8ff-4ec3-953f-1f7d329598b8, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3', 'cwd': '/tmp/tmpmvyldrpd/notebooks/foo'} 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 58387543-b795-43b0-a950-e57699a413c7 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 58387543-b795-43b0-a950-e57699a413c7 289s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/20ecc7fe-3ec9-4ad7-95fa-59042b466c0c (127.0.0.1) 27.520000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 2.440000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 2.610000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for d0d4c3d6-a8ff-4ec3-953f-1f7d329598b8 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: d0d4c3d6-a8ff-4ec3-953f-1f7d329598b8 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/20ecc7fe-3ec9-4ad7-95fa-59042b466c0c (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/20ecc7fe-3ec9-4ad7-95fa-59042b466c0c', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 289s yield maybe_future(sm.delete_session(session_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 802, in run 289s yielded = self.gen.send(value) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 289s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 304, in shutdown_kernel 289s self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 323, in _async_shutdown_kernel 289s stopper = ensure_async(km.shutdown_kernel(now, restart)) 289s ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 171, in wrapped 289s return _runner_map[name].run(inner) 289s ~~~~~~~~~~~~~~~~~~~~~^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 128, in run 289s return fut.result(None) 289s ~~~~~~~~~~^^^^^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 450, in result 289s return self.__get_result() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.14/concurrent/futures/_base.py", line 395, in __get_result 289s raise self._exception 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/20ecc7fe-3ec9-4ad7-95fa-59042b466c0c (127.0.0.1) 18.450000ms referer=None 289s ---------------------------- Captured log teardown ----------------------------- 289s INFO NotebookApp:notebookapp.py:2164 Shutting down 1 kernel 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: d0d4c3d6-a8ff-4ec3-953f-1f7d329598b8 289s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 289s _______________________ AsyncSessionAPITest.test_create ________________________ 289s 289s @self.addCleanup 289s def cleanup_sessions(): 289s for session in self.sess_api.list().json(): 289s > self.sess_api.delete(session['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/cfce920f-4cdd-498c-bfff-32935676c227 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ------------------------------ Captured log setup ------------------------------ 289s DEBUG NotebookApp:application.py:195 Searching ['/tmp/tmpj4ps_shk/config', '/tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter', '/usr/etc/jupyter', '/tmp/tmpj4ps_shk/etc/jupyter'] for config files 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpj4ps_shk/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /usr/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_config in /tmp/tmpj4ps_shk/config 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpj4ps_shk/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /usr/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/autopkgtest.d1RsUl/autopkgtest_tmp/home/.local/etc/jupyter 289s DEBUG NotebookApp:application.py:909 Looking for jupyter_notebook_config in /tmp/tmpj4ps_shk/config 289s INFO NotebookApp:notebookapp.py:2327 Serving notebooks from local directory: /tmp/tmpj4ps_shk/notebooks 289s INFO NotebookApp:notebookapp.py:2327 Jupyter Notebook 6.4.13 is running at: 289s INFO NotebookApp:notebookapp.py:2327 http://localhost:12341/a%40b/?token=... 289s INFO NotebookApp:notebookapp.py:2327 or http://127.0.0.1:12341/a%40b/?token=... 289s INFO NotebookApp:notebookapp.py:2328 Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 289s WARNING NotebookApp:handlers.py:612 Forbidden 289s WARNING NotebookApp:log.py:59 403 GET /a%40b/api/contents (127.0.0.1) 0.900000ms referer=None 289s ----------------------------- Captured stderr call ----------------------------- 289s Fatal Python error: init_import_site: Failed to import the site module 289s Python runtime state: initialized 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 2.230000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpj4ps_shk/runtime/kernel-ea0a6c27-96d4-430a-9306-dce326bf9f3a.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:53553 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:38465 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: ea0a6c27-96d4-430a-9306-dce326bf9f3a, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpj4ps_shk/notebooks/foo'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 18.250000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.040000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions/cfce920f-4cdd-498c-bfff-32935676c227 (127.0.0.1) 1.120000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.040000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ea0a6c27-96d4-430a-9306-dce326bf9f3a 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ea0a6c27-96d4-430a-9306-dce326bf9f3a 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/cfce920f-4cdd-498c-bfff-32935676c227 (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/cfce920f-4cdd-498c-bfff-32935676c227', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 289s future.result() 289s ~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 289s yield maybe_future(sm.delete_session(session_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 289s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 289s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 289s raise km.ready.exception() # type: ignore[misc] 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/cfce920f-4cdd-498c-bfff-32935676c227 (127.0.0.1) 7.770000ms referer=None 289s --------------------------- Captured stderr teardown --------------------------- 289s Traceback (most recent call last): 289s _______________ AsyncSessionAPITest.test_create_console_session ________________ 289s 289s @self.addCleanup 289s def cleanup_sessions(): 289s for session in self.sess_api.list().json(): 289s > self.sess_api.delete(session['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/30c588cf-9588-4768-b856-91bb6bb45423 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ---------------------------- Captured stderr setup ----------------------------- 289s File "/usr/lib/python3.13/types.py", line 55, in 289s raise TypeError 289s TypeError 289s 289s During handling of the above exception, another exception occurred: 289s 289s Traceback (most recent call last): 289s ----------------------------- Captured stderr call ----------------------------- 289s File "/usr/lib/python3.13/site.py", line 735, in 289s main() 289s ~~~~^^ 289s File "/usr/lib/python3.13/site.py", line 728, in main 289s execsitecustomize() 289s ~~~~~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3.13/site.py", line 667, in execsitecustomize 289s import sitecustomize 289s File "/usr/lib/python3.13/sitecustomize.py", line 3, in 289s import apport_python_hook 289s File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 14, in 289s import types 289s File "/usr/lib/python3.13/types.py", line 58, in 289s FrameType = type(exc.__traceback__.tb_frame) 289s KeyboardInterrupt 289s Fatal Python error: init_import_site: Failed to import the site module 289s Python runtime state: initialized 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpj4ps_shk/runtime/kernel-6bf8afc9-eb2d-4d41-8793-cb75a9eed779.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:37885 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:57771 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: 6bf8afc9-eb2d-4d41-8793-cb75a9eed779, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpj4ps_shk/notebooks/foo'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 18.520000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.260000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ea0a6c27-96d4-430a-9306-dce326bf9f3a 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ea0a6c27-96d4-430a-9306-dce326bf9f3a 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/cfce920f-4cdd-498c-bfff-32935676c227 (127.0.0.1) 1.430000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 6bf8afc9-eb2d-4d41-8793-cb75a9eed779 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 6bf8afc9-eb2d-4d41-8793-cb75a9eed779 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/30c588cf-9588-4768-b856-91bb6bb45423 (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/30c588cf-9588-4768-b856-91bb6bb45423', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 289s future.result() 289s ~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 289s yield maybe_future(sm.delete_session(session_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 289s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 289s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 289s raise km.ready.exception() # type: ignore[misc] 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/30c588cf-9588-4768-b856-91bb6bb45423 (127.0.0.1) 8.110000ms referer=None 289s --------------------------- Captured stderr teardown --------------------------- 289s Traceback (most recent call last): 289s File "", line 1513, in _path_importer_cache 289s KeyError: '/usr/lib/python3/dist-packages' 289s 289s During handling of the above exception, another exception occurred: 289s 289s Traceback (most recent call last): 289s __________________ AsyncSessionAPITest.test_create_deprecated __________________ 289s 289s @self.addCleanup 289s def cleanup_sessions(): 289s for session in self.sess_api.list().json(): 289s > self.sess_api.delete(session['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/919ff4e9-862c-476c-a592-37efc59d9528 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ----------------------------- Captured stderr call ----------------------------- 289s File "/usr/lib/python3.13/site.py", line 735, in 289s main() 289s ~~~~^^ 289s File "/usr/lib/python3.13/site.py", line 722, in main 289s known_paths = addsitepackages(known_paths) 289s File "/usr/lib/python3.13/site.py", line 441, in addsitepackages 289s addsitedir(sitedir, known_paths) 289s ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3.13/site.py", line 254, in addsitedir 289s addpackage(sitedir, name, known_paths) 289s ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3.13/site.py", line 213, in addpackage 289s exec(line) 289s ~~~~^^^^^^ 289s File "", line 1, in 289s File "", line 1360, in _find_and_load 289s File "", line 1322, in _find_and_load_unlocked 289s File "", line 1262, in _find_spec 289s File "", line 1556, in find_spec 289s File "", line 1528, in _get_spec 289s File "", line 1515, in _path_importer_cache 289s File "", line 1491, in _path_hooks 289s File "", line 79, in __init__ 289s File "", line 152, in _path_stat 289s KeyboardInterrupt 289s Fatal Python error: init_import_site: Failed to import the site module 289s Python runtime state: initialized 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s WARNING NotebookApp:handlers.py:46 Sessions API changed, see updated swagger docs 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpj4ps_shk/runtime/kernel-e3df7218-e465-48ad-b206-e9f53633e9b8.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:54941 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:57663 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: e3df7218-e465-48ad-b206-e9f53633e9b8, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpj4ps_shk/notebooks/foo'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 17.770000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.130000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 6bf8afc9-eb2d-4d41-8793-cb75a9eed779 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 6bf8afc9-eb2d-4d41-8793-cb75a9eed779 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/30c588cf-9588-4768-b856-91bb6bb45423 (127.0.0.1) 1.450000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for e3df7218-e465-48ad-b206-e9f53633e9b8 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: e3df7218-e465-48ad-b206-e9f53633e9b8 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/919ff4e9-862c-476c-a592-37efc59d9528 (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/919ff4e9-862c-476c-a592-37efc59d9528', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 289s future.result() 289s ~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 289s yield maybe_future(sm.delete_session(session_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 289s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 289s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 289s raise km.ready.exception() # type: ignore[misc] 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/919ff4e9-862c-476c-a592-37efc59d9528 (127.0.0.1) 7.770000ms referer=None 289s --------------------------- Captured stderr teardown --------------------------- 289s Traceback (most recent call last): 289s _________________ AsyncSessionAPITest.test_create_file_session _________________ 289s 289s @self.addCleanup 289s def cleanup_sessions(): 289s for session in self.sess_api.list().json(): 289s > self.sess_api.delete(session['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/b79dbf00-a6a9-49de-8a87-22223dd87527 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ----------------------------- Captured stderr call ----------------------------- 289s File "/usr/lib/python3.13/site.py", line 735, in 289s main() 289s ~~~~^^ 289s File "/usr/lib/python3.13/site.py", line 722, in main 289s known_paths = addsitepackages(known_paths) 289s File "/usr/lib/python3.13/site.py", line 441, in addsitepackages 289s addsitedir(sitedir, known_paths) 289s ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3.13/site.py", line 254, in addsitedir 289s addpackage(sitedir, name, known_paths) 289s ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3.13/site.py", line 197, in addpackage 289s pth_content = pth_content.decode("utf-8-sig") 289s File "/usr/lib/python3.13/encodings/__init__.py", line 99, in search_function 289s mod = __import__('encodings.' + modname, fromlist=_import_tail, 289s level=0) 289s File "/usr/lib/python3.13/encodings/utf_8_sig.py", line 85, in 289s class StreamWriter(codecs.StreamWriter): 289s ...<9 lines>... 289s return encode(input, errors) 289s File "/usr/lib/python3.13/encodings/utf_8_sig.py", line 85, in StreamWriter 289s class StreamWriter(codecs.StreamWriter): 289s 289s KeyboardInterrupt 289s Fatal Python error: init_import_site: Failed to import the site module 289s Python runtime state: initialized 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpj4ps_shk/runtime/kernel-fabc8f78-d375-478c-9d91-6f7a14012e82.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:37887 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:34093 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: fabc8f78-d375-478c-9d91-6f7a14012e82, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python', 'cwd': '/tmp/tmpj4ps_shk/notebooks/foo'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 17.420000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.150000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for e3df7218-e465-48ad-b206-e9f53633e9b8 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: e3df7218-e465-48ad-b206-e9f53633e9b8 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/919ff4e9-862c-476c-a592-37efc59d9528 (127.0.0.1) 1.290000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for fabc8f78-d375-478c-9d91-6f7a14012e82 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: fabc8f78-d375-478c-9d91-6f7a14012e82 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/b79dbf00-a6a9-49de-8a87-22223dd87527 (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/b79dbf00-a6a9-49de-8a87-22223dd87527', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 289s future.result() 289s ~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 289s yield maybe_future(sm.delete_session(session_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 289s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 289s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 289s raise km.ready.exception() # type: ignore[misc] 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/b79dbf00-a6a9-49de-8a87-22223dd87527 (127.0.0.1) 7.830000ms referer=None 289s --------------------------- Captured stderr teardown --------------------------- 289s Traceback (most recent call last): 289s ________________ AsyncSessionAPITest.test_create_with_kernel_id ________________ 289s 289s self = 289s 289s def test_create_with_kernel_id(self): 289s # create a new kernel 289s r = self.request('POST', 'api/kernels') 289s r.raise_for_status() 289s kernel = r.json() 289s 289s resp = self.sess_api.create('foo/nb1.ipynb', kernel_id=kernel['id']) 289s self.assertEqual(resp.status_code, 201) 289s newsession = resp.json() 289s self.assertIn('id', newsession) 289s self.assertEqual(newsession['path'], 'foo/nb1.ipynb') 289s self.assertEqual(newsession['kernel']['id'], kernel['id']) 289s self.assertEqual(resp.headers['Location'], f'{self.url_prefix}api/sessions/{newsession["id"]}') 289s 289s sessions = self.sess_api.list().json() 289s > self.assertEqual(sessions, [newsession]) 289s E AssertionError: Lists differ: [{'id': 'b79dbf00-a6a9-49de-8a87-22223dd87527', 'p[553 chars]ne}}] != [{'id': 'a654b638-0f75-42f4-8e97-3c2b6e1e6c87', 'p[279 chars]ne}}] 289s E 289s E First differing element 0: 289s E {'id': 'b79dbf00-a6a9-49de-8a87-22223dd87527', 'p[218 chars]: 0}} 289s E {'id': 'a654b638-0f75-42f4-8e97-3c2b6e1e6c87', 'p[278 chars]one}} 289s E 289s E First list contains 1 additional elements. 289s E First extra element 1: 289s E {'id': 'a654b638-0f75-42f4-8e97-3c2b6e1e6c87', 'path': 'foo/nb1.ipynb', 'name': None, 'type': 'notebook', 'kernel': {'id': 'ba271671-fc2e-48b8-a05a-3ef07a068663', 'name': 'python3', 'last_activity': '2026-02-06T04:19:21.803440Z', 'execution_state': 'starting', 'connections': 0}, 'notebook': {'path': 'foo/nb1.ipynb', 'name': None}} 289s E 289s E Diff is 830 characters long. Set self.maxDiff to None to see it. 289s 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:178: AssertionError 289s ----------------------------- Captured stderr call ----------------------------- 289s File "/usr/lib/python3.13/site.py", line 735, in 289s main() 289s ~~~~^^ 289s File "/usr/lib/python3.13/site.py", line 722, in main 289s known_paths = addsitepackages(known_paths) 289s File "/usr/lib/python3.13/site.py", line 441, in addsitepackages 289s addsitedir(sitedir, known_paths) 289s ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3.13/site.py", line 254, in addsitedir 289s addpackage(sitedir, name, known_paths) 289s ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3.13/site.py", line 197, in addpackage 289s pth_content = pth_content.decode("utf-8-sig") 289s File "/usr/lib/python3.13/encodings/__init__.py", line 99, in search_function 289s mod = __import__('encodings.' + modname, fromlist=_import_tail, 289s level=0) 289s File "", line 1360, in _find_and_load 289s File "", line 1331, in _find_and_load_unlocked 289s File "", line 935, in _load_unlocked 289s File "", line 1019, in exec_module 289s File "", line 1152, in get_code 289s File "", line 785, in _compile_bytecode 289s KeyboardInterrupt 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpj4ps_shk/runtime/kernel-ba271671-fc2e-48b8-a05a-3ef07a068663.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:50717 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:36121 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: ba271671-fc2e-48b8-a05a-3ef07a068663, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 17.200000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.220000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.070000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 1.070000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for fabc8f78-d375-478c-9d91-6f7a14012e82 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: fabc8f78-d375-478c-9d91-6f7a14012e82 289s DEBUG NotebookApp:log.py:59 204 DELETE /a%40b/api/sessions/b79dbf00-a6a9-49de-8a87-22223dd87527 (127.0.0.1) 1.280000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ba271671-fc2e-48b8-a05a-3ef07a068663 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ba271671-fc2e-48b8-a05a-3ef07a068663 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/a654b638-0f75-42f4-8e97-3c2b6e1e6c87 (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/a654b638-0f75-42f4-8e97-3c2b6e1e6c87', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 289s future.result() 289s ~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 289s yield maybe_future(sm.delete_session(session_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 289s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 289s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 289s raise km.ready.exception() # type: ignore[misc] 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/a654b638-0f75-42f4-8e97-3c2b6e1e6c87 (127.0.0.1) 7.770000ms referer=None 289s __________________ AsyncSessionAPITest.test_modify_kernel_id ___________________ 289s 289s @self.addCleanup 289s def cleanup_sessions(): 289s for session in self.sess_api.list().json(): 289s > self.sess_api.delete(session['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/a654b638-0f75-42f4-8e97-3c2b6e1e6c87 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ---------------------------- Captured stderr setup ----------------------------- 289s Traceback (most recent call last): 289s File "/usr/lib/python3.13/runpy.py", line 189, in _run_module_as_main 289s mod_name, mod_spec, code = _get_module_details(mod_name, _Error) 289s ~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3.13/runpy.py", line 159, in _get_module_details 289s code = loader.get_code(mod_name) 289s File "", line 1152, in get_code 289s File "", line 781, in _compile_bytecode 289s KeyboardInterrupt 289s ----------------------------- Captured stderr call ----------------------------- 289s Traceback (most recent call last): 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.140000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpj4ps_shk/runtime/kernel-6fd5ee69-c586-4553-8381-7351fbd3b7dd.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:52423 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:56725 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: 6fd5ee69-c586-4553-8381-7351fbd3b7dd, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3'} 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/kernels (127.0.0.1) 16.170000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for ba271671-fc2e-48b8-a05a-3ef07a068663 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ba271671-fc2e-48b8-a05a-3ef07a068663 289s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/a654b638-0f75-42f4-8e97-3c2b6e1e6c87 (127.0.0.1) 1.540000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 0.930000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 0.980000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 6fd5ee69-c586-4553-8381-7351fbd3b7dd 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 6fd5ee69-c586-4553-8381-7351fbd3b7dd 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/a654b638-0f75-42f4-8e97-3c2b6e1e6c87 (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/a654b638-0f75-42f4-8e97-3c2b6e1e6c87', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 289s future.result() 289s ~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 289s yield maybe_future(sm.delete_session(session_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 289s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 289s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 289s raise km.ready.exception() # type: ignore[misc] 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/a654b638-0f75-42f4-8e97-3c2b6e1e6c87 (127.0.0.1) 7.990000ms referer=None 289s --------------------------- Captured stderr teardown --------------------------- 289s File "/usr/lib/python3.13/runpy.py", line 198, in _run_module_as_main 289s return _run_code(code, main_globals, None, 289s "__main__", mod_spec) 289s File "/usr/lib/python3.13/runpy.py", line 88, in _run_code 289s exec(code, run_globals) 289s ~~~~^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/ipykernel_launcher.py", line 16, in 289s from ipykernel import kernelapp as app 289s File "/usr/lib/python3/dist-packages/ipykernel/__init__.py", line 1, in 289s from ._version import ( 289s ...<4 lines>... 289s ) 289s File "", line 1360, in _find_and_load 289s File "", line 1331, in _find_and_load_unlocked 289s File "", line 935, in _load_unlocked 289s File "", line 1019, in exec_module 289s File "", line 1115, in get_code 289s File "", line 1214, in get_data 289s KeyboardInterrupt 289s _________________ AsyncSessionAPITest.test_modify_kernel_name __________________ 289s 289s @self.addCleanup 289s def cleanup_sessions(): 289s for session in self.sess_api.list().json(): 289s > self.sess_api.delete(session['id']) 289s 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:111: 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:85: in delete 289s return self._req('DELETE', id) 289s ^^^^^^^^^^^^^^^^^^^^^^^ 289s /usr/lib/python3/dist-packages/notebook/services/sessions/tests/test_sessions_api.py:40: in _req 289s response.raise_for_status() 289s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 289s 289s self = 289s 289s def raise_for_status(self): 289s """Raises :class:`HTTPError`, if one occurred.""" 289s 289s http_error_msg = "" 289s if isinstance(self.reason, bytes): 289s # We attempt to decode utf-8 first because some servers 289s # choose to localize their reason strings. If the string 289s # isn't utf-8, we fall back to iso-8859-1 for all other 289s # encodings. (See PR #3538) 289s try: 289s reason = self.reason.decode("utf-8") 289s except UnicodeDecodeError: 289s reason = self.reason.decode("iso-8859-1") 289s else: 289s reason = self.reason 289s 289s if 400 <= self.status_code < 500: 289s http_error_msg = ( 289s f"{self.status_code} Client Error: {reason} for url: {self.url}" 289s ) 289s 289s elif 500 <= self.status_code < 600: 289s http_error_msg = ( 289s f"{self.status_code} Server Error: {reason} for url: {self.url}" 289s ) 289s 289s if http_error_msg: 289s > raise HTTPError(http_error_msg, response=self) 289s E requests.exceptions.HTTPError: 500 Server Error: Unhandled error for url: http://localhost:12341/a%40b/api/sessions/a654b638-0f75-42f4-8e97-3c2b6e1e6c87 289s 289s /usr/lib/python3/dist-packages/requests/models.py:1026: HTTPError 289s ----------------------------- Captured stderr call ----------------------------- 289s Fatal Python error: init_import_site: Failed to import the site module 289s Python runtime state: initialized 289s ------------------------------ Captured log call ------------------------------- 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 201 POST /a%40b/api/sessions (127.0.0.1) 1.220000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:factory.py:92 Instantiating kernel 'Python 3 (ipykernel)' with kernel provisioner: local-provisioner 289s DEBUG NotebookApp:manager.py:439 Starting kernel: ['/usr/bin/python3', '-Xfrozen_modules=off', '-m', 'ipykernel_launcher', '-f', '/tmp/tmpj4ps_shk/runtime/kernel-0dba55f2-e69b-48ba-8bc5-79a4cb4a8e32.json'] 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:41583 289s DEBUG NotebookApp:connect.py:654 Connecting to: tcp://127.0.0.1:50265 289s INFO NotebookApp:kernelmanager.py:179 Kernel started: 0dba55f2-e69b-48ba-8bc5-79a4cb4a8e32, name: python3 289s DEBUG NotebookApp:kernelmanager.py:180 Kernel args: {'kernel_name': 'python3', 'cwd': '/tmp/tmpj4ps_shk/notebooks/foo'} 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 6fd5ee69-c586-4553-8381-7351fbd3b7dd 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 6fd5ee69-c586-4553-8381-7351fbd3b7dd 289s DEBUG NotebookApp:log.py:59 200 PATCH /a%40b/api/sessions/a654b638-0f75-42f4-8e97-3c2b6e1e6c87 (127.0.0.1) 17.540000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/kernels (127.0.0.1) 1.090000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:log.py:59 200 GET /a%40b/api/sessions (127.0.0.1) 0.980000ms 289s DEBUG NotebookApp:login.py:213 Accepting token-authenticated connection from 127.0.0.1 289s DEBUG NotebookApp:kernelmanager.py:272 Clearing buffer for 0dba55f2-e69b-48ba-8bc5-79a4cb4a8e32 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0dba55f2-e69b-48ba-8bc5-79a4cb4a8e32 289s ERROR NotebookApp:manager.py:96 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:multikernelmanager.py:247 Timeout should be used inside a task 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s ERROR NotebookApp:web.py:1945 Uncaught exception DELETE /a%40b/api/sessions/a654b638-0f75-42f4-8e97-3c2b6e1e6c87 (127.0.0.1) 289s HTTPServerRequest(protocol='http', host='localhost:12341', method='DELETE', uri='/a%40b/api/sessions/a654b638-0f75-42f4-8e97-3c2b6e1e6c87', version='HTTP/1.1', remote_ip='127.0.0.1') 289s Traceback (most recent call last): 289s File "/usr/lib/python3/dist-packages/tornado/web.py", line 1859, in _execute 289s result = await result 289s ^^^^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 362, in __wakeup 289s future.result() 289s ~~~~~~~~~~~~~^^ 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/handlers.py", line 164, in delete 289s yield maybe_future(sm.delete_session(session_id)) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 796, in run 289s yielded = self.gen.throw(exc) 289s File "/usr/lib/python3/dist-packages/notebook/services/sessions/sessionmanager.py", line 287, in delete_session 289s yield maybe_future(self.kernel_manager.shutdown_kernel(session['kernel']['id'])) 289s File "/usr/lib/python3/dist-packages/tornado/gen.py", line 783, in run 289s value = future.result() 289s File "/usr/lib/python3.14/asyncio/futures.py", line 208, in result 289s raise self._exception.with_traceback(self._exception_tb) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 289, in __step_run_and_handle_result 289s result = coro.send(None) 289s File "/usr/lib/python3/dist-packages/notebook/services/kernels/kernelmanager.py", line 517, in shutdown_kernel 289s await self.pinned_superclass.shutdown_kernel(self, kernel_id, now=now, restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 331, in _async_shutdown_kernel 289s raise km.ready.exception() # type: ignore[misc] 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/multikernelmanager.py", line 243, in _remove_kernel_when_ready 289s await kernel_awaitable 289s File "/usr/lib/python3/dist-packages/jupyter_core/utils/__init__.py", line 214, in ensure_async 289s result = await obj 289s ^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 97, in wrapper 289s raise e 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 88, in wrapper 289s out = await method(self, *args, **kwargs) 289s ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 552, in _async_shutdown_kernel 289s await self._async_finish_shutdown(restart=restart) 289s File "/usr/lib/python3/dist-packages/jupyter_client/manager.py", line 475, in _async_finish_shutdown 289s await asyncio.wait_for( 289s self._async_wait(pollinterval=pollinterval), timeout=waittime / 2 289s ) 289s File "/usr/lib/python3.14/asyncio/tasks.py", line 487, in wait_for 289s async with timeouts.timeout(timeout): 289s ~~~~~~~~~~~~~~~~^^^^^^^^^ 289s File "/usr/lib/python3.14/asyncio/timeouts.py", line 88, in __aenter__ 289s raise RuntimeError("Timeout should be used inside a task") 289s RuntimeError: Timeout should be used inside a task 289s WARNING NotebookApp:handlers.py:612 Unhandled error 289s ERROR NotebookApp:log.py:55 { 289s "Host": "localhost:12341", 289s "Accept": "*/*", 289s "User-Agent": "python-requests/2.32.5" 289s } 289s ERROR NotebookApp:log.py:59 500 DELETE /a%40b/api/sessions/a654b638-0f75-42f4-8e97-3c2b6e1e6c87 (127.0.0.1) 8.120000ms referer=None 289s --------------------------- Captured stderr teardown --------------------------- 289s Traceback (most recent call last): 289s File "/usr/lib/python3.13/site.py", line 735, in 289s main() 289s ~~~~^^ 289s File "/usr/lib/python3.13/site.py", line 722, in main 289s known_paths = addsitepackages(known_paths) 289s File "/usr/lib/python3.13/site.py", line 441, in addsitepackages 289s addsitedir(sitedir, known_paths) 289s ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^ 289s File "/usr/lib/python3.13/site.py", line 248, in addsitedir 289s names = os.listdir(sitedir) 289s KeyboardInterrupt 289s ---------------------------- Captured log teardown ----------------------------- 289s INFO NotebookApp:notebookapp.py:2164 Shutting down 1 kernel 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: e3df7218-e465-48ad-b206-e9f53633e9b8 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 0dba55f2-e69b-48ba-8bc5-79a4cb4a8e32 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 6fd5ee69-c586-4553-8381-7351fbd3b7dd 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: fabc8f78-d375-478c-9d91-6f7a14012e82 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ea0a6c27-96d4-430a-9306-dce326bf9f3a 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: ba271671-fc2e-48b8-a05a-3ef07a068663 289s INFO NotebookApp:multikernelmanager.py:305 Kernel shutdown: 6bf8afc9-eb2d-4d41-8793-cb75a9eed779 289s INFO NotebookApp:notebookapp.py:2179 Shutting down 0 terminals 289s =============================== warnings summary =============================== 289s ../../../usr/lib/python3/dist-packages/notebook/utils.py:280 289s ../../../usr/lib/python3/dist-packages/notebook/utils.py:280 289s /usr/lib/python3/dist-packages/notebook/utils.py:280: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead. 289s return LooseVersion(v) >= LooseVersion(check) 289s 289s ../../../usr/lib/python3/dist-packages/notebook/_tz.py:29: 1 warning 289s services/kernels/tests/test_kernels_api.py: 72 warnings 289s services/sessions/tests/test_sessions_api.py: 88 warnings 289s /usr/lib/python3/dist-packages/notebook/_tz.py:29: DeprecationWarning: datetime.datetime.utcnow() is deprecated and scheduled for removal in a future version. Use timezone-aware objects to represent datetimes in UTC: datetime.datetime.now(datetime.UTC). 289s dt = unaware(*args, **kwargs) 289s 289s ../../../usr/lib/python3/dist-packages/notebook/tests/test_notebookapp_integration.py:14 289s /usr/lib/python3/dist-packages/notebook/tests/test_notebookapp_integration.py:14: PytestUnknownMarkWarning: Unknown pytest.mark.integration_tests - is this a typo? You can register custom marks to avoid this warning - for details, see https://docs.pytest.org/en/stable/how-to/mark.html 289s pytestmark = pytest.mark.integration_tests 289s 289s services/kernels/tests/test_kernels_api.py: 6 warnings 289s services/sessions/tests/test_sessions_api.py: 6 warnings 289s /usr/lib/python3/dist-packages/nest_asyncio.py:71: DeprecationWarning: 'asyncio.get_event_loop_policy' is deprecated and slated for removal in Python 3.16 289s policy = events.get_event_loop_policy() 289s 289s services/kernels/tests/test_kernels_api.py: 22 warnings 289s services/sessions/tests/test_sessions_api.py: 17 warnings 289s /usr/lib/python3/dist-packages/nest_asyncio.py:40: DeprecationWarning: 'asyncio.get_event_loop_policy' is deprecated and slated for removal in Python 3.16 289s loop = events.get_event_loop_policy().get_event_loop() 289s 289s services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_connections 289s /usr/lib/python3/dist-packages/notebook/services/kernels/tests/test_kernels_api.py:67: DeprecationWarning: make_current is deprecated; start the event loop first 289s loop.make_current() 289s 289s -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html 289s =========================== short test summary info ============================ 289s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_default_kernel 289s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_kernel_handler 289s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_main_kernel_handler 289s FAILED services/kernels/tests/test_kernels_api.py::KernelAPITest::test_no_kernels 289s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_connections 289s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_default_kernel 289s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_kernel_handler 289s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_main_kernel_handler 289s FAILED services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_no_kernels 289s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create 289s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_console_session 289s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_deprecated 289s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_file_session 289s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_with_kernel_id 289s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_modify_kernel_id 289s FAILED services/sessions/tests/test_sessions_api.py::SessionAPITest::test_modify_kernel_name 289s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create 289s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_console_session 289s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_deprecated 289s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_file_session 289s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_with_kernel_id 289s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_modify_kernel_id 289s FAILED services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_modify_kernel_name 289s ERROR services/kernels/tests/test_kernels_api.py::KernelAPITest::test_main_kernel_handler 289s ERROR services/kernels/tests/test_kernels_api.py::AsyncKernelAPITest::test_main_kernel_handler 289s ERROR services/sessions/tests/test_sessions_api.py::SessionAPITest::test_create_with_kernel_id 289s ERROR services/sessions/tests/test_sessions_api.py::AsyncSessionAPITest::test_create_with_kernel_id 289s ========== 23 failed, 307 deselected, 216 warnings, 4 errors in 6.43s ========== 290s *** END OF RUN 5: NOT ALL TESTS HAVE YET PASSED/XFAILED *** 290s *** SOME TESTS FAILED/ERRORED EVERY RUN, ABORTING *** 290s autopkgtest [04:19:23]: test pytest: -----------------------] 295s pytest FAIL non-zero exit status 1 295s autopkgtest [04:19:28]: test pytest: - - - - - - - - - - results - - - - - - - - - - 299s autopkgtest [04:19:32]: @@@@@@@@@@@@@@@@@@@@ summary 299s pytest FAIL non-zero exit status 1