Mock Version: 5.0 Mock Version: 5.0 Mock Version: 5.0 ENTER ['do_with_status'](['bash', '--login', '-c', '/usr/bin/rpmbuild -bs --noclean --target noarch --nodeps /builddir/build/SPECS/python-nbclient.spec'], chrootPath='/var/lib/mock/f40-build-2496394-61664/root'env={'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'}shell=Falselogger=timeout=864000uid=996gid=135user='mockbuild'nspawn_args=[]unshare_net=TrueprintOutput=False) Executing command: ['bash', '--login', '-c', '/usr/bin/rpmbuild -bs --noclean --target noarch --nodeps /builddir/build/SPECS/python-nbclient.spec'] with env {'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'} and shell False Building target platforms: noarch Building for target noarch setting SOURCE_DATE_EPOCH=1709510400 Wrote: /builddir/build/SRPMS/python-nbclient-0.9.0-1.fc40.src.rpm Child return code was: 0 ENTER ['do_with_status'](['bash', '--login', '-c', '/usr/bin/rpmbuild -br --noclean --target noarch --nodeps /builddir/build/SPECS/python-nbclient.spec'], chrootPath='/var/lib/mock/f40-build-2496394-61664/root'env={'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'}shell=Falselogger=timeout=864000uid=996gid=135user='mockbuild'nspawn_args=[]unshare_net=TrueraiseExc=FalseprintOutput=False) Executing command: ['bash', '--login', '-c', '/usr/bin/rpmbuild -br --noclean --target noarch --nodeps /builddir/build/SPECS/python-nbclient.spec'] with env {'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'} and shell False Building target platforms: noarch Building for target noarch setting SOURCE_DATE_EPOCH=1709510400 Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.HC7Lvj + umask 022 + cd /builddir/build/BUILD + cd /builddir/build/BUILD + rm -rf nbclient-0.9.0 + /usr/lib/rpm/rpmuncompress -x /builddir/build/SOURCES/nbclient-0.9.0.tar.gz + STATUS=0 + '[' 0 -ne 0 ']' + cd nbclient-0.9.0 + rm -rf /builddir/build/BUILD/nbclient-0.9.0-SPECPARTS + /usr/bin/mkdir -p /builddir/build/BUILD/nbclient-0.9.0-SPECPARTS + /usr/bin/chmod -Rf a+rX,u+w,g-w,o-w . + rm -rf nbclient.egg-info + RPM_EC=0 ++ jobs -p + exit 0 Executing(%generate_buildrequires): /bin/sh -e /var/tmp/rpm-tmp.TFJu3z + umask 022 + cd /builddir/build/BUILD + cd nbclient-0.9.0 + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CFLAGS + CXXFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CXXFLAGS + FFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FFLAGS + FCFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FCFLAGS + VALAFLAGS=-g + export VALAFLAGS + RUSTFLAGS='-Copt-level=3 -Cdebuginfo=2 -Ccodegen-units=1 -Cstrip=none -Cforce-frame-pointers=yes -Clink-arg=-Wl,-z,relro -Clink-arg=-Wl,-z,now --cap-lints=warn' + export RUSTFLAGS + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + export LDFLAGS + LT_SYS_LIBRARY_PATH=/usr/lib: + export LT_SYS_LIBRARY_PATH + CC=gcc + export CC + CXX=g++ + export CXX + echo pyproject-rpm-macros + echo python3-devel + echo 'python3dist(pip) >= 19' + echo 'python3dist(packaging)' + '[' -f pyproject.toml ']' + echo '(python3dist(tomli) if python3-devel < 3.11)' + rm -rfv '*.dist-info/' + '[' -f /usr/bin/python3 ']' + mkdir -p /builddir/build/BUILD/nbclient-0.9.0/.pyproject-builddir + echo -n + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + TMPDIR=/builddir/build/BUILD/nbclient-0.9.0/.pyproject-builddir + RPM_TOXENV=py312 + HOSTNAME=rpmbuild + /usr/bin/python3 -Bs /usr/lib/rpm/redhat/pyproject_buildrequires.py --generate-extras --python3_pkgversion 3 --wheeldir /builddir/build/BUILD/nbclient-0.9.0/pyproject-wheeldir --output /builddir/build/BUILD/python-nbclient-0.9.0-1.fc40.noarch-pyproject-buildrequires -x test Handling hatchling>=1.10.0 from build-system.requires Requirement not satisfied: hatchling>=1.10.0 Exiting dependency generation pass: build backend + cat /builddir/build/BUILD/python-nbclient-0.9.0-1.fc40.noarch-pyproject-buildrequires + rm -rfv '*.dist-info/' + RPM_EC=0 ++ jobs -p + exit 0 Wrote: /builddir/build/SRPMS/python-nbclient-0.9.0-1.fc40.buildreqs.nosrc.rpm Child return code was: 11 Dynamic buildrequires detected Going to install missing buildrequires. See root.log for details. ENTER ['do_with_status'](['bash', '--login', '-c', '/usr/bin/rpmbuild -br --noclean --target noarch --nodeps /builddir/build/SPECS/python-nbclient.spec'], chrootPath='/var/lib/mock/f40-build-2496394-61664/root'env={'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'}shell=Falselogger=timeout=864000uid=996gid=135user='mockbuild'nspawn_args=[]unshare_net=TrueraiseExc=FalseprintOutput=False) Executing command: ['bash', '--login', '-c', '/usr/bin/rpmbuild -br --noclean --target noarch --nodeps /builddir/build/SPECS/python-nbclient.spec'] with env {'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'} and shell False Building target platforms: noarch Building for target noarch setting SOURCE_DATE_EPOCH=1709510400 Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.KOQA4e + umask 022 + cd /builddir/build/BUILD + cd /builddir/build/BUILD + rm -rf nbclient-0.9.0 + /usr/lib/rpm/rpmuncompress -x /builddir/build/SOURCES/nbclient-0.9.0.tar.gz + STATUS=0 + '[' 0 -ne 0 ']' + cd nbclient-0.9.0 + rm -rf /builddir/build/BUILD/nbclient-0.9.0-SPECPARTS + /usr/bin/mkdir -p /builddir/build/BUILD/nbclient-0.9.0-SPECPARTS + /usr/bin/chmod -Rf a+rX,u+w,g-w,o-w . + rm -rf nbclient.egg-info + RPM_EC=0 ++ jobs -p + exit 0 Executing(%generate_buildrequires): /bin/sh -e /var/tmp/rpm-tmp.oEEWOq + umask 022 + cd /builddir/build/BUILD + cd nbclient-0.9.0 + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CFLAGS + CXXFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CXXFLAGS + FFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FFLAGS + FCFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FCFLAGS + VALAFLAGS=-g + export VALAFLAGS + RUSTFLAGS='-Copt-level=3 -Cdebuginfo=2 -Ccodegen-units=1 -Cstrip=none -Cforce-frame-pointers=yes -Clink-arg=-Wl,-z,relro -Clink-arg=-Wl,-z,now --cap-lints=warn' + export RUSTFLAGS + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + export LDFLAGS + LT_SYS_LIBRARY_PATH=/usr/lib: + export LT_SYS_LIBRARY_PATH + CC=gcc + export CC + CXX=g++ + export CXX + echo pyproject-rpm-macros + echo python3-devel + echo 'python3dist(pip) >= 19' + echo 'python3dist(packaging)' + '[' -f pyproject.toml ']' + echo '(python3dist(tomli) if python3-devel < 3.11)' + rm -rfv '*.dist-info/' + '[' -f /usr/bin/python3 ']' + mkdir -p /builddir/build/BUILD/nbclient-0.9.0/.pyproject-builddir + echo -n + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + TMPDIR=/builddir/build/BUILD/nbclient-0.9.0/.pyproject-builddir + RPM_TOXENV=py312 + HOSTNAME=rpmbuild + /usr/bin/python3 -Bs /usr/lib/rpm/redhat/pyproject_buildrequires.py --generate-extras --python3_pkgversion 3 --wheeldir /builddir/build/BUILD/nbclient-0.9.0/pyproject-wheeldir --output /builddir/build/BUILD/python-nbclient-0.9.0-1.fc40.noarch-pyproject-buildrequires -x test Handling hatchling>=1.10.0 from build-system.requires Requirement satisfied: hatchling>=1.10.0 (installed: hatchling 1.21.1) Handling jupyter-client>=6.1.12 from hook generated metadata: Requires-Dist (nbclient) Requirement not satisfied: jupyter-client>=6.1.12 Handling jupyter-core!=5.0.*,>=4.12 from hook generated metadata: Requires-Dist (nbclient) Requirement not satisfied: jupyter-core!=5.0.*,>=4.12 Handling nbformat>=5.1 from hook generated metadata: Requires-Dist (nbclient) Requirement not satisfied: nbformat>=5.1 Handling traitlets>=5.4 from hook generated metadata: Requires-Dist (nbclient) Requirement not satisfied: traitlets>=5.4 Handling pre-commit; extra == 'dev' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: pre-commit; extra == 'dev' Handling autodoc-traits; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: autodoc-traits; extra == 'docs' Handling mock; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: mock; extra == 'docs' Handling moto; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: moto; extra == 'docs' Handling myst-parser; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: myst-parser; extra == 'docs' Handling nbclient[test]; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: nbclient[test]; extra == 'docs' Handling sphinx-book-theme; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: sphinx-book-theme; extra == 'docs' Handling sphinx>=1.7; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: sphinx>=1.7; extra == 'docs' Handling sphinxcontrib-spelling; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: sphinxcontrib-spelling; extra == 'docs' Handling flaky; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement not satisfied: flaky; extra == 'test' Handling ipykernel>=6.19.3; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement not satisfied: ipykernel>=6.19.3; extra == 'test' Handling ipython; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement not satisfied: ipython; extra == 'test' Handling ipywidgets; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement not satisfied: ipywidgets; extra == 'test' Handling nbconvert>=7.0.0; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement not satisfied: nbconvert>=7.0.0; extra == 'test' Handling pytest-asyncio; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement not satisfied: pytest-asyncio; extra == 'test' Handling pytest-cov>=4.0; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement not satisfied: pytest-cov>=4.0; extra == 'test' Handling pytest>=7.0; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement not satisfied: pytest>=7.0; extra == 'test' Handling testpath; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement not satisfied: testpath; extra == 'test' Handling xmltodict; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement not satisfied: xmltodict; extra == 'test' + cat /builddir/build/BUILD/python-nbclient-0.9.0-1.fc40.noarch-pyproject-buildrequires + rm -rfv nbclient-0.9.0.dist-info/ removed 'nbclient-0.9.0.dist-info/METADATA' removed directory 'nbclient-0.9.0.dist-info/' + RPM_EC=0 ++ jobs -p + exit 0 Wrote: /builddir/build/SRPMS/python-nbclient-0.9.0-1.fc40.buildreqs.nosrc.rpm Child return code was: 11 Dynamic buildrequires detected Going to install missing buildrequires. See root.log for details. ENTER ['do_with_status'](['bash', '--login', '-c', '/usr/bin/rpmbuild -br --noclean --target noarch --nodeps /builddir/build/SPECS/python-nbclient.spec'], chrootPath='/var/lib/mock/f40-build-2496394-61664/root'env={'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'}shell=Falselogger=timeout=864000uid=996gid=135user='mockbuild'nspawn_args=[]unshare_net=TrueraiseExc=FalseprintOutput=False) Executing command: ['bash', '--login', '-c', '/usr/bin/rpmbuild -br --noclean --target noarch --nodeps /builddir/build/SPECS/python-nbclient.spec'] with env {'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'} and shell False Building target platforms: noarch Building for target noarch setting SOURCE_DATE_EPOCH=1709510400 Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.mEiXic + umask 022 + cd /builddir/build/BUILD + cd /builddir/build/BUILD + rm -rf nbclient-0.9.0 + /usr/lib/rpm/rpmuncompress -x /builddir/build/SOURCES/nbclient-0.9.0.tar.gz + STATUS=0 + '[' 0 -ne 0 ']' + cd nbclient-0.9.0 + rm -rf /builddir/build/BUILD/nbclient-0.9.0-SPECPARTS + /usr/bin/mkdir -p /builddir/build/BUILD/nbclient-0.9.0-SPECPARTS + /usr/bin/chmod -Rf a+rX,u+w,g-w,o-w . + rm -rf nbclient.egg-info + RPM_EC=0 ++ jobs -p + exit 0 Executing(%generate_buildrequires): /bin/sh -e /var/tmp/rpm-tmp.T6Zy1V + umask 022 + cd /builddir/build/BUILD + cd nbclient-0.9.0 + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CFLAGS + CXXFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CXXFLAGS + FFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FFLAGS + FCFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FCFLAGS + VALAFLAGS=-g + export VALAFLAGS + RUSTFLAGS='-Copt-level=3 -Cdebuginfo=2 -Ccodegen-units=1 -Cstrip=none -Cforce-frame-pointers=yes -Clink-arg=-Wl,-z,relro -Clink-arg=-Wl,-z,now --cap-lints=warn' + export RUSTFLAGS + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + export LDFLAGS + LT_SYS_LIBRARY_PATH=/usr/lib: + export LT_SYS_LIBRARY_PATH + CC=gcc + export CC + CXX=g++ + export CXX + echo pyproject-rpm-macros + echo python3-devel + echo 'python3dist(pip) >= 19' + echo 'python3dist(packaging)' + '[' -f pyproject.toml ']' + echo '(python3dist(tomli) if python3-devel < 3.11)' + rm -rfv '*.dist-info/' + '[' -f /usr/bin/python3 ']' + mkdir -p /builddir/build/BUILD/nbclient-0.9.0/.pyproject-builddir + echo -n + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + TMPDIR=/builddir/build/BUILD/nbclient-0.9.0/.pyproject-builddir + RPM_TOXENV=py312 + HOSTNAME=rpmbuild + /usr/bin/python3 -Bs /usr/lib/rpm/redhat/pyproject_buildrequires.py --generate-extras --python3_pkgversion 3 --wheeldir /builddir/build/BUILD/nbclient-0.9.0/pyproject-wheeldir --output /builddir/build/BUILD/python-nbclient-0.9.0-1.fc40.noarch-pyproject-buildrequires -x test Handling hatchling>=1.10.0 from build-system.requires Requirement satisfied: hatchling>=1.10.0 (installed: hatchling 1.21.1) Handling jupyter-client>=6.1.12 from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: jupyter-client>=6.1.12 (installed: jupyter-client 7.4.9) Handling jupyter-core!=5.0.*,>=4.12 from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: jupyter-core!=5.0.*,>=4.12 (installed: jupyter-core 5.1.0) Handling nbformat>=5.1 from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: nbformat>=5.1 (installed: nbformat 5.9.2) Handling traitlets>=5.4 from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: traitlets>=5.4 (installed: traitlets 5.11.2) Handling pre-commit; extra == 'dev' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: pre-commit; extra == 'dev' Handling autodoc-traits; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: autodoc-traits; extra == 'docs' Handling mock; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: mock; extra == 'docs' Handling moto; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: moto; extra == 'docs' Handling myst-parser; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: myst-parser; extra == 'docs' Handling nbclient[test]; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: nbclient[test]; extra == 'docs' Handling sphinx-book-theme; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: sphinx-book-theme; extra == 'docs' Handling sphinx>=1.7; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: sphinx>=1.7; extra == 'docs' Handling sphinxcontrib-spelling; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: sphinxcontrib-spelling; extra == 'docs' Handling flaky; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: flaky; extra == 'test' (installed: flaky 3.7.0) Handling ipykernel>=6.19.3; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: ipykernel>=6.19.3; extra == 'test' (installed: ipykernel 6.25.1) Handling ipython; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: ipython; extra == 'test' (installed: ipython 8.14.0) Handling ipywidgets; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: ipywidgets; extra == 'test' (installed: ipywidgets 8.0.7) Handling nbconvert>=7.0.0; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: nbconvert>=7.0.0; extra == 'test' (installed: nbconvert 7.2.5) Handling pytest-asyncio; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: pytest-asyncio; extra == 'test' (installed: pytest-asyncio 0.21.0) Handling pytest-cov>=4.0; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: pytest-cov>=4.0; extra == 'test' (installed: pytest-cov 4.0.0) Handling pytest>=7.0; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: pytest>=7.0; extra == 'test' (installed: pytest 7.3.2) Handling testpath; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: testpath; extra == 'test' (installed: testpath 0.6.0) Handling xmltodict; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: xmltodict; extra == 'test' (installed: xmltodict 0.13.0) + cat /builddir/build/BUILD/python-nbclient-0.9.0-1.fc40.noarch-pyproject-buildrequires + rm -rfv nbclient-0.9.0.dist-info/ removed 'nbclient-0.9.0.dist-info/METADATA' removed directory 'nbclient-0.9.0.dist-info/' + RPM_EC=0 ++ jobs -p + exit 0 Wrote: /builddir/build/SRPMS/python-nbclient-0.9.0-1.fc40.buildreqs.nosrc.rpm Child return code was: 11 Dynamic buildrequires detected Going to install missing buildrequires. See root.log for details. ENTER ['do_with_status'](['bash', '--login', '-c', '/usr/bin/rpmbuild -ba --noprep --noclean --target noarch --nodeps /builddir/build/SPECS/python-nbclient.spec'], chrootPath='/var/lib/mock/f40-build-2496394-61664/root'env={'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'}shell=Falselogger=timeout=864000uid=996gid=135user='mockbuild'nspawn_args=[]unshare_net=TrueprintOutput=False) Executing command: ['bash', '--login', '-c', '/usr/bin/rpmbuild -ba --noprep --noclean --target noarch --nodeps /builddir/build/SPECS/python-nbclient.spec'] with env {'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'} and shell False Building target platforms: noarch Building for target noarch setting SOURCE_DATE_EPOCH=1709510400 Executing(%generate_buildrequires): /bin/sh -e /var/tmp/rpm-tmp.FKM1Su + umask 022 + cd /builddir/build/BUILD + cd nbclient-0.9.0 + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CFLAGS + CXXFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CXXFLAGS + FFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FFLAGS + FCFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FCFLAGS + VALAFLAGS=-g + export VALAFLAGS + RUSTFLAGS='-Copt-level=3 -Cdebuginfo=2 -Ccodegen-units=1 -Cstrip=none -Cforce-frame-pointers=yes -Clink-arg=-Wl,-z,relro -Clink-arg=-Wl,-z,now --cap-lints=warn' + export RUSTFLAGS + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + export LDFLAGS + LT_SYS_LIBRARY_PATH=/usr/lib: + export LT_SYS_LIBRARY_PATH + CC=gcc + export CC + CXX=g++ + export CXX + echo pyproject-rpm-macros + echo python3-devel + echo 'python3dist(pip) >= 19' + echo 'python3dist(packaging)' + '[' -f pyproject.toml ']' + echo '(python3dist(tomli) if python3-devel < 3.11)' + rm -rfv '*.dist-info/' + '[' -f /usr/bin/python3 ']' + mkdir -p /builddir/build/BUILD/nbclient-0.9.0/.pyproject-builddir + echo -n + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + TMPDIR=/builddir/build/BUILD/nbclient-0.9.0/.pyproject-builddir + RPM_TOXENV=py312 + HOSTNAME=rpmbuild + /usr/bin/python3 -Bs /usr/lib/rpm/redhat/pyproject_buildrequires.py --generate-extras --python3_pkgversion 3 --wheeldir /builddir/build/BUILD/nbclient-0.9.0/pyproject-wheeldir --output /builddir/build/BUILD/python-nbclient-0.9.0-1.fc40.noarch-pyproject-buildrequires -x test Handling hatchling>=1.10.0 from build-system.requires Requirement satisfied: hatchling>=1.10.0 (installed: hatchling 1.21.1) Handling jupyter-client>=6.1.12 from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: jupyter-client>=6.1.12 (installed: jupyter-client 7.4.9) Handling jupyter-core!=5.0.*,>=4.12 from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: jupyter-core!=5.0.*,>=4.12 (installed: jupyter-core 5.1.0) Handling nbformat>=5.1 from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: nbformat>=5.1 (installed: nbformat 5.9.2) Handling traitlets>=5.4 from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: traitlets>=5.4 (installed: traitlets 5.11.2) Handling pre-commit; extra == 'dev' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: pre-commit; extra == 'dev' Handling autodoc-traits; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: autodoc-traits; extra == 'docs' Handling mock; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: mock; extra == 'docs' Handling moto; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: moto; extra == 'docs' Handling myst-parser; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: myst-parser; extra == 'docs' Handling nbclient[test]; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: nbclient[test]; extra == 'docs' Handling sphinx-book-theme; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: sphinx-book-theme; extra == 'docs' Handling sphinx>=1.7; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: sphinx>=1.7; extra == 'docs' Handling sphinxcontrib-spelling; extra == 'docs' from hook generated metadata: Requires-Dist (nbclient) Ignoring alien requirement: sphinxcontrib-spelling; extra == 'docs' Handling flaky; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: flaky; extra == 'test' (installed: flaky 3.7.0) Handling ipykernel>=6.19.3; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: ipykernel>=6.19.3; extra == 'test' (installed: ipykernel 6.25.1) Handling ipython; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: ipython; extra == 'test' (installed: ipython 8.14.0) Handling ipywidgets; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: ipywidgets; extra == 'test' (installed: ipywidgets 8.0.7) Handling nbconvert>=7.0.0; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: nbconvert>=7.0.0; extra == 'test' (installed: nbconvert 7.2.5) Handling pytest-asyncio; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: pytest-asyncio; extra == 'test' (installed: pytest-asyncio 0.21.0) Handling pytest-cov>=4.0; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: pytest-cov>=4.0; extra == 'test' (installed: pytest-cov 4.0.0) Handling pytest>=7.0; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: pytest>=7.0; extra == 'test' (installed: pytest 7.3.2) Handling testpath; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: testpath; extra == 'test' (installed: testpath 0.6.0) Handling xmltodict; extra == 'test' from hook generated metadata: Requires-Dist (nbclient) Requirement satisfied: xmltodict; extra == 'test' (installed: xmltodict 0.13.0) + cat /builddir/build/BUILD/python-nbclient-0.9.0-1.fc40.noarch-pyproject-buildrequires + rm -rfv nbclient-0.9.0.dist-info/ removed 'nbclient-0.9.0.dist-info/METADATA' removed directory 'nbclient-0.9.0.dist-info/' + RPM_EC=0 ++ jobs -p + exit 0 Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.z9hDdd + umask 022 + cd /builddir/build/BUILD + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CFLAGS + CXXFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CXXFLAGS + FFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FFLAGS + FCFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FCFLAGS + VALAFLAGS=-g + export VALAFLAGS + RUSTFLAGS='-Copt-level=3 -Cdebuginfo=2 -Ccodegen-units=1 -Cstrip=none -Cforce-frame-pointers=yes -Clink-arg=-Wl,-z,relro -Clink-arg=-Wl,-z,now --cap-lints=warn' + export RUSTFLAGS + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + export LDFLAGS + LT_SYS_LIBRARY_PATH=/usr/lib: + export LT_SYS_LIBRARY_PATH + CC=gcc + export CC + CXX=g++ + export CXX + cd nbclient-0.9.0 + mkdir -p /builddir/build/BUILD/nbclient-0.9.0/.pyproject-builddir + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + TMPDIR=/builddir/build/BUILD/nbclient-0.9.0/.pyproject-builddir + /usr/bin/python3 -Bs /usr/lib/rpm/redhat/pyproject_wheel.py /builddir/build/BUILD/nbclient-0.9.0/pyproject-wheeldir Processing /builddir/build/BUILD/nbclient-0.9.0 Preparing metadata (pyproject.toml): started Running command Preparing metadata (pyproject.toml) Preparing metadata (pyproject.toml): finished with status 'done' Building wheels for collected packages: nbclient Building wheel for nbclient (pyproject.toml): started Running command Building wheel for nbclient (pyproject.toml) Building wheel for nbclient (pyproject.toml): finished with status 'done' Created wheel for nbclient: filename=nbclient-0.9.0-py3-none-any.whl size=24743 sha256=d28521e1bdc1a9fe09dc42a5e058701b8d21722dbe6dec7359a4fd7af7ce6b40 Stored in directory: /builddir/.cache/pip/wheels/7b/61/7c/2173124ac3e4a88db3d16d38f9c1565b823ba98d0a42672c1b Successfully built nbclient + RPM_EC=0 ++ jobs -p + exit 0 Executing(%install): /bin/sh -e /var/tmp/rpm-tmp.p3eD7L + umask 022 + cd /builddir/build/BUILD + '[' /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch '!=' / ']' + rm -rf /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch ++ dirname /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch + mkdir -p /builddir/build/BUILDROOT + mkdir /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CFLAGS + CXXFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CXXFLAGS + FFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FFLAGS + FCFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FCFLAGS + VALAFLAGS=-g + export VALAFLAGS + RUSTFLAGS='-Copt-level=3 -Cdebuginfo=2 -Ccodegen-units=1 -Cstrip=none -Cforce-frame-pointers=yes -Clink-arg=-Wl,-z,relro -Clink-arg=-Wl,-z,now --cap-lints=warn' + export RUSTFLAGS + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + export LDFLAGS + LT_SYS_LIBRARY_PATH=/usr/lib: + export LT_SYS_LIBRARY_PATH + CC=gcc + export CC + CXX=g++ + export CXX + cd nbclient-0.9.0 ++ xargs basename --multiple ++ sed -E 's/([^-]+)-([^-]+)-.+\.whl/\1==\2/' ++ ls /builddir/build/BUILD/nbclient-0.9.0/pyproject-wheeldir/nbclient-0.9.0-py3-none-any.whl + specifier=nbclient==0.9.0 + '[' -z nbclient==0.9.0 ']' + TMPDIR=/builddir/build/BUILD/nbclient-0.9.0/.pyproject-builddir + /usr/bin/python3 -m pip install --root /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch --prefix /usr --no-deps --disable-pip-version-check --progress-bar off --verbose --ignore-installed --no-warn-script-location --no-index --no-cache-dir --find-links /builddir/build/BUILD/nbclient-0.9.0/pyproject-wheeldir nbclient==0.9.0 Using pip 23.3.2 from /usr/lib/python3.12/site-packages/pip (python 3.12) Looking in links: /builddir/build/BUILD/nbclient-0.9.0/pyproject-wheeldir Processing ./pyproject-wheeldir/nbclient-0.9.0-py3-none-any.whl Installing collected packages: nbclient Creating /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/bin changing mode of /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/bin/jupyter-execute to 755 Successfully installed nbclient-0.9.0 + '[' -d /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/bin ']' + '[' -z P ']' + shebang_flags=-kaP + /usr/bin/python3 -B /usr/lib/rpm/redhat/pathfix.py -pni /usr/bin/python3 -kaP /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/bin/jupyter-execute /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/bin/jupyter-execute: updating + rm -rfv /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/bin/__pycache__ + rm -f /builddir/build/BUILD/python-nbclient-0.9.0-1.fc40.noarch-pyproject-ghost-distinfo + site_dirs=() + '[' -d /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/lib/python3.12/site-packages ']' + site_dirs+=("/usr/lib/python3.12/site-packages") + '[' /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/lib64/python3.12/site-packages '!=' /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/lib/python3.12/site-packages ']' + '[' -d /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/lib64/python3.12/site-packages ']' + for site_dir in ${site_dirs[@]} + for distinfo in /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch$site_dir/*.dist-info + echo '%ghost /usr/lib/python3.12/site-packages/nbclient-0.9.0.dist-info' + sed -i s/pip/rpm/ /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/lib/python3.12/site-packages/nbclient-0.9.0.dist-info/INSTALLER + PYTHONPATH=/usr/lib/rpm/redhat + /usr/bin/python3 -B /usr/lib/rpm/redhat/pyproject_preprocess_record.py --buildroot /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch --record /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/lib/python3.12/site-packages/nbclient-0.9.0.dist-info/RECORD --output /builddir/build/BUILD/python-nbclient-0.9.0-1.fc40.noarch-pyproject-record + rm -fv /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/lib/python3.12/site-packages/nbclient-0.9.0.dist-info/RECORD removed '/builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/lib/python3.12/site-packages/nbclient-0.9.0.dist-info/RECORD' + rm -fv /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/lib/python3.12/site-packages/nbclient-0.9.0.dist-info/REQUESTED removed '/builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/lib/python3.12/site-packages/nbclient-0.9.0.dist-info/REQUESTED' ++ wc -l /builddir/build/BUILD/python-nbclient-0.9.0-1.fc40.noarch-pyproject-ghost-distinfo ++ cut -f1 '-d ' + lines=1 + '[' 1 -ne 1 ']' + RPM_PERCENTAGES_COUNT=2 + /usr/bin/python3 /usr/lib/rpm/redhat/pyproject_save_files.py --output-files /builddir/build/BUILD/python-nbclient-0.9.0-1.fc40.noarch-pyproject-files --output-modules /builddir/build/BUILD/python-nbclient-0.9.0-1.fc40.noarch-pyproject-modules --buildroot /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch --sitelib /usr/lib/python3.12/site-packages --sitearch /usr/lib64/python3.12/site-packages --python-version 3.12 --pyproject-record /builddir/build/BUILD/python-nbclient-0.9.0-1.fc40.noarch-pyproject-record --prefix /usr nbclient + /usr/bin/find-debuginfo -j8 --strict-build-id -m -i --build-id-seed 0.9.0-1.fc40 --unique-debug-suffix -0.9.0-1.fc40.noarch --unique-debug-src-base python-nbclient-0.9.0-1.fc40.noarch --run-dwz --dwz-low-mem-die-limit 10000000 --dwz-max-die-limit 50000000 -S debugsourcefiles.list /builddir/build/BUILD/nbclient-0.9.0 find-debuginfo: starting Extracting debug info from 0 files Creating .debug symlinks for symlinks to ELF files find: ‘debug’: No such file or directory find-debuginfo: done + /usr/lib/rpm/check-buildroot + /usr/lib/rpm/redhat/brp-ldconfig + /usr/lib/rpm/brp-compress + /usr/lib/rpm/redhat/brp-strip-lto /usr/bin/strip + /usr/lib/rpm/brp-strip-static-archive /usr/bin/strip + /usr/lib/rpm/check-rpaths + /usr/lib/rpm/redhat/brp-mangle-shebangs + /usr/lib/rpm/brp-remove-la-files + env /usr/lib/rpm/redhat/brp-python-bytecompile '' 1 0 -j8 Bytecompiling .py files below /builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/lib/python3.12 using python3.12 + /usr/lib/rpm/redhat/brp-python-hardlink Executing(%check): /bin/sh -e /var/tmp/rpm-tmp.9kG3DL + umask 022 + cd /builddir/build/BUILD + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CFLAGS + CXXFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CXXFLAGS + FFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FFLAGS + FCFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FCFLAGS + VALAFLAGS=-g + export VALAFLAGS + RUSTFLAGS='-Copt-level=3 -Cdebuginfo=2 -Ccodegen-units=1 -Cstrip=none -Cforce-frame-pointers=yes -Clink-arg=-Wl,-z,relro -Clink-arg=-Wl,-z,now --cap-lints=warn' + export RUSTFLAGS + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + export LDFLAGS + LT_SYS_LIBRARY_PATH=/usr/lib: + export LT_SYS_LIBRARY_PATH + CC=gcc + export CC + CXX=g++ + export CXX + cd nbclient-0.9.0 + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + PATH=/builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/sbin + PYTHONPATH=/builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/lib64/python3.12/site-packages:/builddir/build/BUILDROOT/python-nbclient-0.9.0-1.fc40.noarch/usr/lib/python3.12/site-packages + PYTHONDONTWRITEBYTECODE=1 + PYTEST_ADDOPTS=' --ignore=/builddir/build/BUILD/nbclient-0.9.0/.pyproject-builddir' + PYTEST_XDIST_AUTO_NUM_WORKERS=8 + /usr/bin/pytest -vv ============================= test session starts ============================== platform linux -- Python 3.12.0, pytest-7.3.2, pluggy-1.3.0 -- /usr/bin/python3 cachedir: .pytest_cache rootdir: /builddir/build/BUILD/nbclient-0.9.0 configfile: pyproject.toml testpaths: tests plugins: asyncio-0.21.0, anyio-3.7.0, flaky-3.7.0, cov-4.0.0 asyncio: mode=Mode.AUTO collecting ... collected 94 items tests/test_client.py::test_run_all_notebooks[Other Comms.ipynb-opts0] FAILED [ 1%] tests/test_client.py::test_run_all_notebooks[Clear Output.ipynb-opts1] FAILED [ 2%] tests/test_client.py::test_run_all_notebooks[Empty Cell.ipynb-opts2] FAILED [ 3%] tests/test_client.py::test_run_all_notebooks[Factorials.ipynb-opts3] FAILED [ 4%] tests/test_client.py::test_run_all_notebooks[HelloWorld.ipynb-opts4] FAILED [ 5%] tests/test_client.py::test_run_all_notebooks[Inline Image.ipynb-opts5] FAILED [ 6%] tests/test_client.py::test_run_all_notebooks[Interrupt.ipynb-opts6] FAILED [ 7%] tests/test_client.py::test_run_all_notebooks[JupyterWidgets.ipynb-opts7] FAILED [ 8%] tests/test_client.py::test_run_all_notebooks[Skip Exceptions with Cell Tags.ipynb-opts8] FAILED [ 9%] tests/test_client.py::test_run_all_notebooks[Skip Exceptions.ipynb-opts9] FAILED [ 10%] tests/test_client.py::test_run_all_notebooks[Skip Execution with Cell Tag.ipynb-opts10] FAILED [ 11%] tests/test_client.py::test_run_all_notebooks[SVG.ipynb-opts11] FAILED [ 12%] tests/test_client.py::test_run_all_notebooks[Unicode.ipynb-opts12] FAILED [ 13%] tests/test_client.py::test_run_all_notebooks[UnicodePy3.ipynb-opts13] FAILED [ 14%] tests/test_client.py::test_run_all_notebooks[update-display-id.ipynb-opts14] FAILED [ 15%] tests/test_client.py::test_run_all_notebooks[Check History in Memory.ipynb-opts15] FAILED [ 17%] tests/test_client.py::test_parallel_notebooks PASSED [ 18%] tests/test_client.py::test_many_parallel_notebooks FAILED [ 19%] tests/test_client.py::test_async_parallel_notebooks FAILED [ 20%] tests/test_client.py::test_many_async_parallel_notebooks FAILED [ 21%] tests/test_client.py::test_execution_timing FAILED [ 22%] tests/test_client.py::test_synchronous_setup_kernel FAILED [ 23%] tests/test_client.py::test_startnewkernel_with_kernelmanager FAILED [ 24%] tests/test_client.py::test_start_new_kernel_history_file_setting PASSED [ 25%] tests/test_client.py::test_start_new_kernel_client_cleans_up_kernel_on_failure PASSED [ 26%] tests/test_client.py::TestExecute::test_allow_errors FAILED [ 27%] tests/test_client.py::TestExecute::test_async_execution_hook FAILED [ 28%] tests/test_client.py::TestExecute::test_cleanup_kernel_client FAILED [ 29%] tests/test_client.py::TestExecute::test_constructor PASSED [ 30%] tests/test_client.py::TestExecute::test_custom_kernel_manager FAILED [ 31%] tests/test_client.py::TestExecute::test_disable_stdin FAILED [ 32%] tests/test_client.py::TestExecute::test_empty_kernel_name FAILED [ 34%] tests/test_client.py::TestExecute::test_empty_path FAILED [ 35%] tests/test_client.py::TestExecute::test_error_async_execution_hook FAILED [ 36%] tests/test_client.py::TestExecute::test_error_execution_hook_error FAILED [ 37%] tests/test_client.py::TestExecute::test_error_notebook_hook FAILED [ 38%] tests/test_client.py::TestExecute::test_execute_function FAILED [ 39%] tests/test_client.py::TestExecute::test_execution_hook FAILED [ 40%] tests/test_client.py::TestExecute::test_force_raise_errors FAILED [ 41%] tests/test_client.py::TestExecute::test_kernel_death_after_timeout FAILED [ 42%] tests/test_client.py::TestExecute::test_kernel_death_during_execution PASSED [ 43%] tests/test_client.py::TestExecute::test_populate_language_info FAILED [ 44%] tests/test_client.py::TestExecute::test_process_message_wrapper FAILED [ 45%] tests/test_client.py::TestExecute::test_reset_kernel_client FAILED [ 46%] tests/test_client.py::TestExecute::test_sync_kernel_manager FAILED [ 47%] tests/test_client.py::TestExecute::test_timeout FAILED [ 48%] tests/test_client.py::TestExecute::test_timeout_func FAILED [ 50%] tests/test_client.py::TestExecute::test_widgets FAILED [ 51%] tests/test_client.py::TestRunCell::test_allow_error_names PASSED [ 52%] tests/test_client.py::TestRunCell::test_allow_errors PASSED [ 53%] tests/test_client.py::TestRunCell::test_async_cell_hooks PASSED [ 54%] tests/test_client.py::TestRunCell::test_busy_message PASSED [ 55%] tests/test_client.py::TestRunCell::test_cell_hooks PASSED [ 56%] tests/test_client.py::TestRunCell::test_clear_output_message PASSED [ 57%] tests/test_client.py::TestRunCell::test_clear_output_wait_message PASSED [ 58%] tests/test_client.py::TestRunCell::test_clear_output_wait_then_message_message PASSED [ 59%] tests/test_client.py::TestRunCell::test_clear_output_wait_then_update_display_message PASSED [ 60%] tests/test_client.py::TestRunCell::test_coalesce_streams PASSED [ 61%] tests/test_client.py::TestRunCell::test_deadline_exec_reply PASSED [ 62%] tests/test_client.py::TestRunCell::test_deadline_iopub PASSED [ 63%] tests/test_client.py::TestRunCell::test_display_data_message PASSED [ 64%] tests/test_client.py::TestRunCell::test_display_data_same_id_message PASSED [ 65%] tests/test_client.py::TestRunCell::test_display_data_without_id_message PASSED [ 67%] tests/test_client.py::TestRunCell::test_error_and_error_status_messages PASSED [ 68%] tests/test_client.py::TestRunCell::test_error_async_cell_hooks PASSED [ 69%] tests/test_client.py::TestRunCell::test_error_cell_hooks PASSED [ 70%] tests/test_client.py::TestRunCell::test_error_message PASSED [ 71%] tests/test_client.py::TestRunCell::test_error_message_only PASSED [ 72%] tests/test_client.py::TestRunCell::test_eventual_deadline_iopub PASSED [ 73%] tests/test_client.py::TestRunCell::test_execute_input_message PASSED [ 74%] tests/test_client.py::TestRunCell::test_execute_result_message PASSED [ 75%] tests/test_client.py::TestRunCell::test_execute_result_with_display_message PASSED [ 76%] tests/test_client.py::TestRunCell::test_execution_count_message PASSED [ 77%] tests/test_client.py::TestRunCell::test_execution_count_message_ignored_on_override PASSED [ 78%] tests/test_client.py::TestRunCell::test_execution_count_with_stream_message PASSED [ 79%] tests/test_client.py::TestRunCell::test_idle_message PASSED [ 80%] tests/test_client.py::TestRunCell::test_message_for_wrong_parent PASSED [ 81%] tests/test_client.py::TestRunCell::test_no_source PASSED [ 82%] tests/test_client.py::TestRunCell::test_non_code_cell PASSED [ 84%] tests/test_client.py::TestRunCell::test_non_code_cell_hooks PASSED [ 85%] tests/test_client.py::TestRunCell::test_raises_exception_tag PASSED [ 86%] tests/test_client.py::TestRunCell::test_stream_messages PASSED [ 87%] tests/test_client.py::TestRunCell::test_unknown_comm_message PASSED [ 88%] tests/test_client.py::TestRunCell::test_update_display_data_message PASSED [ 89%] tests/test_client.py::TestRunCell::test_update_display_data_mismatch_id_message PASSED [ 90%] tests/test_client.py::TestRunCell::test_update_display_data_without_id_message PASSED [ 91%] tests/test_client.py::TestRunCell::test_widget_comm_buffer_message_single PASSED [ 92%] tests/test_client.py::TestRunCell::test_widget_comm_buffer_messages PASSED [ 93%] tests/test_client.py::TestRunCell::test_widget_comm_message PASSED [ 94%] tests/test_util.py::test_nested_asyncio_with_existing_ioloop PASSED [ 95%] tests/test_util.py::test_nested_asyncio_with_no_ioloop PASSED [ 96%] tests/test_util.py::test_nested_asyncio_with_tornado PASSED [ 97%] tests/test_util.py::test_run_hook_sync PASSED [ 98%] tests/test_util.py::test_run_hook_async PASSED [100%] =================================== FAILURES =================================== _______________ test_run_all_notebooks[Other Comms.ipynb-opts0] ________________ input_name = 'Other Comms.ipynb', opts = {'kernel_name': 'python'} @pytest.mark.parametrize( ["input_name", "opts"], [ ("Other Comms.ipynb", {"kernel_name": "python"}), ("Clear Output.ipynb", {"kernel_name": "python"}), ("Empty Cell.ipynb", {"kernel_name": "python"}), ("Factorials.ipynb", {"kernel_name": "python"}), ("HelloWorld.ipynb", {"kernel_name": "python"}), ("Inline Image.ipynb", {"kernel_name": "python"}), ( "Interrupt.ipynb", { "kernel_name": "python", "timeout": 3, "interrupt_on_timeout": True, "allow_errors": True, }, ), ("JupyterWidgets.ipynb", {"kernel_name": "python"}), ("Skip Exceptions with Cell Tags.ipynb", {"kernel_name": "python"}), ("Skip Exceptions.ipynb", {"kernel_name": "python", "allow_errors": True}), ("Skip Execution with Cell Tag.ipynb", {"kernel_name": "python"}), ("SVG.ipynb", {"kernel_name": "python"}), ("Unicode.ipynb", {"kernel_name": "python"}), ("UnicodePy3.ipynb", {"kernel_name": "python"}), ("update-display-id.ipynb", {"kernel_name": "python"}), ("Check History in Memory.ipynb", {"kernel_name": "python"}), ], ) def test_run_all_notebooks(input_name, opts): """Runs a series of test notebooks and compares them to their actual output""" input_file = os.path.join(current_dir, "files", input_name) > input_nb, output_nb = run_notebook(input_file, opts, notebook_resources()) input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Other Comms.ipynb' input_name = 'Other Comms.ipynb' opts = {'kernel_name': 'python'} tests/test_client.py:351: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'ExecuteTime': {'end_time': '2020-05-29T11:16:26.584520Z', 'start_time': '2020-05-29T11:16:26.581213Z'}}, 'outputs': [], 'source': "comm.send(data={'id': 'bar'})"} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'ExecuteTime': {'end_time': '2020-05-29T11:16:26.365338Z', 'start_time': '2020-05-29T11:16:26.362047Z'}}, 'outputs': [], 'source': 'from comm import create_comm'}, {'cell_type': 'code', 'metadata': {'ExecuteTime': {'end_time': '2020-05-29T11:16:26.377700Z', 'start_time': '2020-05-29T11:16:26.371603Z'}}, 'outputs': [], 'source': "comm = create_comm('this-comm-tests-a-missing-handler', " "data={'id': 'foo'})"}, {'cell_type': 'code', 'metadata': {'ExecuteTime': {'end_time': '2020-05-29T11:16:26.584520Z', 'start_time': '2020-05-29T11:16:26.581213Z'}}, 'outputs': [], 'source': "comm.send(data={'id': 'bar'})"}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.7.3'}}, 'nbformat': 4, 'nbformat_minor': 2} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Other Comms.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Other Comms.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'ExecuteTime': {'end_time': '2020-05-29T11:16:26.365338Z', 'start_time': '2020-05-29T11:16:26.362047Z'}}, 'outputs': [], 'source': 'from comm import create_comm'}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {'ExecuteTime': {'end_time': '2020-05-29T11:16:26.377700Z', 'start_time': '2020-05-29T11:16:26.371603Z'}}, 'outputs': [], 'source': "comm = create_comm('this-comm-tests-a-missing-handler', " "data={'id': 'foo'})"}, {'cell_type': 'code', 'execution_count': 3, 'metadata': {'ExecuteTime': {'end_time': '2020-05-29T11:16:26.584520Z', 'start_time': '2020-05-29T11:16:26.581213Z'}}, 'outputs': [], 'source': "comm.send(data={'id': 'bar'})"}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.7.3'}}, 'nbformat': 4, 'nbformat_minor': 2} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff82ed7880> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709559129.7782137 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 22, in from .auto_suggest import AutoSuggest, Suggestion File "/usr/lib/python3.12/site-packages/prompt_toolkit/auto_suggest.py", line 21, in from .document import Document File "/usr/lib/python3.12/site-packages/prompt_toolkit/document.py", line 12, in from .clipboard import ClipboardData File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 915, in _load_unlocked File "", line 819, in module_from_spec File "", line 798, in _init_module_attrs File "", line 638, in cached File "", line 611, in _get_cached KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 78751d6f-6d32-480c-9454-d4c7d45b8a23: Kernel didn't respond in 60 seconds _______________ test_run_all_notebooks[Clear Output.ipynb-opts1] _______________ input_name = 'Clear Output.ipynb', opts = {'kernel_name': 'python'} @pytest.mark.parametrize( ["input_name", "opts"], [ ("Other Comms.ipynb", {"kernel_name": "python"}), ("Clear Output.ipynb", {"kernel_name": "python"}), ("Empty Cell.ipynb", {"kernel_name": "python"}), ("Factorials.ipynb", {"kernel_name": "python"}), ("HelloWorld.ipynb", {"kernel_name": "python"}), ("Inline Image.ipynb", {"kernel_name": "python"}), ( "Interrupt.ipynb", { "kernel_name": "python", "timeout": 3, "interrupt_on_timeout": True, "allow_errors": True, }, ), ("JupyterWidgets.ipynb", {"kernel_name": "python"}), ("Skip Exceptions with Cell Tags.ipynb", {"kernel_name": "python"}), ("Skip Exceptions.ipynb", {"kernel_name": "python", "allow_errors": True}), ("Skip Execution with Cell Tag.ipynb", {"kernel_name": "python"}), ("SVG.ipynb", {"kernel_name": "python"}), ("Unicode.ipynb", {"kernel_name": "python"}), ("UnicodePy3.ipynb", {"kernel_name": "python"}), ("update-display-id.ipynb", {"kernel_name": "python"}), ("Check History in Memory.ipynb", {"kernel_name": "python"}), ], ) def test_run_all_notebooks(input_name, opts): """Runs a series of test notebooks and compares them to their actual output""" input_file = os.path.join(current_dir, "files", input_name) > input_nb, output_nb = run_notebook(input_file, opts, notebook_resources()) input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Clear Output.ipynb' input_name = 'Clear Output.ipynb' opts = {'kernel_name': 'python'} tests/test_client.py:351: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "handle4.update('Hello world') # it is cleared, so it should not " 'show up in the above cell'} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 'from __future__ import print_function\n' 'from IPython.display import clear_output'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 'for i in range(10):\n clear_output()\n print(i)'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 'print("Hello world")\nclear_output()'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 'print("Hello world", end=\'\')\n' 'clear_output(wait=True) # no output after this'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 'print("Hello", end=\'\')\n' 'clear_output(wait=True) # here we have new output ' 'after wait=True\n' 'print("world", end=\'\')'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 'handle0 = display("Hello world", display_id="id0")'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 'handle1 = display("Hello", display_id="id1")'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "handle1.update('world')"}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 'handle2 = display("Hello world", display_id="id2")\n' 'clear_output() # clears all output, also with ' 'display_ids'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 'handle3 = display("Hello world", display_id="id3")\n' 'clear_output(wait=True)'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 'handle4 = display("Hello", display_id="id4")\n' 'clear_output(wait=True)\n' "print('world', end='')"}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "handle4.update('Hello world') # it is cleared, so it " 'should not show up in the above cell'}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.6.7'}}, 'nbformat': 4, 'nbformat_minor': 1} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Clear Output.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Clear Output.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {}, 'outputs': [], 'source': 'from __future__ import print_function\n' 'from IPython.display import clear_output'}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': '9\n'}], 'source': 'for i in range(10):\n clear_output()\n print(i)'}, {'cell_type': 'code', 'execution_count': 3, 'metadata': {}, 'outputs': [], 'source': 'print("Hello world")\nclear_output()'}, {'cell_type': 'code', 'execution_count': 4, 'metadata': {}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'Hello world'}], 'source': 'print("Hello world", end=\'\')\n' 'clear_output(wait=True) # no output after this'}, {'cell_type': 'code', 'execution_count': 5, 'metadata': {}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'world'}], 'source': 'print("Hello", end=\'\')\n' 'clear_output(wait=True) # here we have new output ' 'after wait=True\n' 'print("world", end=\'\')'}, {'cell_type': 'code', 'execution_count': 6, 'metadata': {}, 'outputs': [{'data': {'text/plain': "'Hello world'"}, 'metadata': {}, 'output_type': 'display_data'}], 'source': 'handle0 = display("Hello world", display_id="id0")'}, {'cell_type': 'code', 'execution_count': 7, 'metadata': {}, 'outputs': [{'data': {'text/plain': "'world'"}, 'metadata': {}, 'output_type': 'display_data'}], 'source': 'handle1 = display("Hello", display_id="id1")'}, {'cell_type': 'code', 'execution_count': 8, 'metadata': {}, 'outputs': [], 'source': "handle1.update('world')"}, {'cell_type': 'code', 'execution_count': 9, 'metadata': {}, 'outputs': [], 'source': 'handle2 = display("Hello world", display_id="id2")\n' 'clear_output() # clears all output, also with ' 'display_ids'}, {'cell_type': 'code', 'execution_count': 10, 'metadata': {}, 'outputs': [{'data': {'text/plain': "'Hello world'"}, 'metadata': {}, 'output_type': 'display_data'}], 'source': 'handle3 = display("Hello world", display_id="id3")\n' 'clear_output(wait=True)'}, {'cell_type': 'code', 'execution_count': 11, 'metadata': {}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'world'}], 'source': 'handle4 = display("Hello", display_id="id4")\n' 'clear_output(wait=True)\n' "print('world', end='')"}, {'cell_type': 'code', 'execution_count': 12, 'metadata': {}, 'outputs': [], 'source': "handle4.update('Hello world') # it is cleared, so it " 'should not show up in the above cell'}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.6.7'}}, 'nbformat': 4, 'nbformat_minor': 1} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff82fa6e80> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709559249.246045 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 13, in from .dummy import DummyApplication File "", line 1354, in _find_and_load File "", line 1333, in _find_and_load_unlocked KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 39f48d92-b034-4034-8fb8-c099ef9b1557: Kernel didn't respond in 60 seconds ________________ test_run_all_notebooks[Empty Cell.ipynb-opts2] ________________ input_name = 'Empty Cell.ipynb', opts = {'kernel_name': 'python'} @pytest.mark.parametrize( ["input_name", "opts"], [ ("Other Comms.ipynb", {"kernel_name": "python"}), ("Clear Output.ipynb", {"kernel_name": "python"}), ("Empty Cell.ipynb", {"kernel_name": "python"}), ("Factorials.ipynb", {"kernel_name": "python"}), ("HelloWorld.ipynb", {"kernel_name": "python"}), ("Inline Image.ipynb", {"kernel_name": "python"}), ( "Interrupt.ipynb", { "kernel_name": "python", "timeout": 3, "interrupt_on_timeout": True, "allow_errors": True, }, ), ("JupyterWidgets.ipynb", {"kernel_name": "python"}), ("Skip Exceptions with Cell Tags.ipynb", {"kernel_name": "python"}), ("Skip Exceptions.ipynb", {"kernel_name": "python", "allow_errors": True}), ("Skip Execution with Cell Tag.ipynb", {"kernel_name": "python"}), ("SVG.ipynb", {"kernel_name": "python"}), ("Unicode.ipynb", {"kernel_name": "python"}), ("UnicodePy3.ipynb", {"kernel_name": "python"}), ("update-display-id.ipynb", {"kernel_name": "python"}), ("Check History in Memory.ipynb", {"kernel_name": "python"}), ], ) def test_run_all_notebooks(input_name, opts): """Runs a series of test notebooks and compares them to their actual output""" input_file = os.path.join(current_dir, "files", input_name) > input_nb, output_nb = run_notebook(input_file, opts, notebook_resources()) input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Empty Cell.ipynb' input_name = 'Empty Cell.ipynb' opts = {'kernel_name': 'python'} tests/test_client.py:351: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': '"Code 2"'} cleaned_input_nb = {'cells': [{'cell_type': 'markdown', 'metadata': {}, 'outputs': [], 'source': 'Test that executing skips over an empty cell.'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': '"Code 1"'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': ''}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': '"Code 2"'}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.5.2'}}, 'nbformat': 4, 'nbformat_minor': 2} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Empty Cell.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Empty Cell.ipynb' input_nb = {'cells': [{'cell_type': 'markdown', 'metadata': {}, 'source': 'Test that executing skips over an empty cell.'}, {'cell_type': 'code', 'execution_count': 1, 'metadata': {}, 'outputs': [{'data': {'text/plain': "'Code 1'"}, 'execution_count': 1, 'metadata': {}, 'output_type': 'execute_result'}], 'source': '"Code 1"'}, {'cell_type': 'code', 'execution_count': None, 'metadata': {}, 'outputs': [], 'source': ''}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {}, 'outputs': [{'data': {'text/plain': "'Code 2'"}, 'execution_count': 2, 'metadata': {}, 'output_type': 'execute_result'}], 'source': '"Code 2"'}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.5.2'}}, 'nbformat': 4, 'nbformat_minor': 2} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff82fa7ec0> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709559338.5932732 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 3, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/base.py", line 11, in from prompt_toolkit.formatted_text import AnyFormattedText, StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/__init__.py", line 15, in from .ansi import ANSI File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/ansi.py", line 6, in from prompt_toolkit.output.vt100 import BG_ANSI_COLORS, FG_ANSI_COLORS File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/__init__.py", line 3, in from .base import DummyOutput, Output File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/base.py", line 13, in from .color_depth import ColorDepth File "", line 1354, in _find_and_load File "", line 1316, in _find_and_load_unlocked File "", line 1256, in _find_spec File "", line 1524, in find_spec File "", line 1498, in _get_spec File "", line 1625, in find_spec File "", line 126, in _path_join KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel a4bf5c8e-9513-490e-94df-a0e07554dded: Kernel didn't respond in 60 seconds ________________ test_run_all_notebooks[Factorials.ipynb-opts3] ________________ input_name = 'Factorials.ipynb', opts = {'kernel_name': 'python'} @pytest.mark.parametrize( ["input_name", "opts"], [ ("Other Comms.ipynb", {"kernel_name": "python"}), ("Clear Output.ipynb", {"kernel_name": "python"}), ("Empty Cell.ipynb", {"kernel_name": "python"}), ("Factorials.ipynb", {"kernel_name": "python"}), ("HelloWorld.ipynb", {"kernel_name": "python"}), ("Inline Image.ipynb", {"kernel_name": "python"}), ( "Interrupt.ipynb", { "kernel_name": "python", "timeout": 3, "interrupt_on_timeout": True, "allow_errors": True, }, ), ("JupyterWidgets.ipynb", {"kernel_name": "python"}), ("Skip Exceptions with Cell Tags.ipynb", {"kernel_name": "python"}), ("Skip Exceptions.ipynb", {"kernel_name": "python", "allow_errors": True}), ("Skip Execution with Cell Tag.ipynb", {"kernel_name": "python"}), ("SVG.ipynb", {"kernel_name": "python"}), ("Unicode.ipynb", {"kernel_name": "python"}), ("UnicodePy3.ipynb", {"kernel_name": "python"}), ("update-display-id.ipynb", {"kernel_name": "python"}), ("Check History in Memory.ipynb", {"kernel_name": "python"}), ], ) def test_run_all_notebooks(input_name, opts): """Runs a series of test notebooks and compares them to their actual output""" input_file = os.path.join(current_dir, "files", input_name) > input_nb, output_nb = run_notebook(input_file, opts, notebook_resources()) input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Factorials.ipynb' input_name = 'Factorials.ipynb' opts = {'kernel_name': 'python'} tests/test_client.py:351: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'for m in range(10):\n i, j = j, i + j\n print(j)'} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'i, j = 1, 1'}, {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'for m in range(10):\n' ' i, j = j, i + j\n' ' print(j)'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Factorials.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Factorials.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'i, j = 1, 1'}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': '2\n3\n5\n8\n13\n21\n34\n55\n89\n144\n'}], 'source': 'for m in range(10):\n' ' i, j = j, i + j\n' ' print(j)'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff80390b80> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709559431.3809934 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 3, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/base.py", line 11, in from prompt_toolkit.formatted_text import AnyFormattedText, StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/__init__.py", line 15, in from .ansi import ANSI File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/ansi.py", line 6, in from prompt_toolkit.output.vt100 import BG_ANSI_COLORS, FG_ANSI_COLORS File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/__init__.py", line 3, in from .base import DummyOutput, Output File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/base.py", line 9, in from prompt_toolkit.cursor_shapes import CursorShape File "/usr/lib/python3.12/site-packages/prompt_toolkit/cursor_shapes.py", line 8, in from prompt_toolkit.key_binding.vi_state import InputMode File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/__init__.py", line 3, in from .key_bindings import ( File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 929, in _load_unlocked File "", line 990, in exec_module File "", line 1095, in get_code File "", line 690, in _classify_pyc File "", line 87, in _unpack_uint32 KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 2b1a4863-a36d-413c-8ca3-79590d2d0783: Kernel didn't respond in 60 seconds ________________ test_run_all_notebooks[HelloWorld.ipynb-opts4] ________________ input_name = 'HelloWorld.ipynb', opts = {'kernel_name': 'python'} @pytest.mark.parametrize( ["input_name", "opts"], [ ("Other Comms.ipynb", {"kernel_name": "python"}), ("Clear Output.ipynb", {"kernel_name": "python"}), ("Empty Cell.ipynb", {"kernel_name": "python"}), ("Factorials.ipynb", {"kernel_name": "python"}), ("HelloWorld.ipynb", {"kernel_name": "python"}), ("Inline Image.ipynb", {"kernel_name": "python"}), ( "Interrupt.ipynb", { "kernel_name": "python", "timeout": 3, "interrupt_on_timeout": True, "allow_errors": True, }, ), ("JupyterWidgets.ipynb", {"kernel_name": "python"}), ("Skip Exceptions with Cell Tags.ipynb", {"kernel_name": "python"}), ("Skip Exceptions.ipynb", {"kernel_name": "python", "allow_errors": True}), ("Skip Execution with Cell Tag.ipynb", {"kernel_name": "python"}), ("SVG.ipynb", {"kernel_name": "python"}), ("Unicode.ipynb", {"kernel_name": "python"}), ("UnicodePy3.ipynb", {"kernel_name": "python"}), ("update-display-id.ipynb", {"kernel_name": "python"}), ("Check History in Memory.ipynb", {"kernel_name": "python"}), ], ) def test_run_all_notebooks(input_name, opts): """Runs a series of test notebooks and compares them to their actual output""" input_file = os.path.join(current_dir, "files", input_name) > input_nb, output_nb = run_notebook(input_file, opts, notebook_resources()) input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' input_name = 'HelloWorld.ipynb' opts = {'kernel_name': 'python'} tests/test_client.py:351: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'print("Hello World")'} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'Hello World\n'}], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff80390a40> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709559519.9834368 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 1481, in _path_importer_cache KeyError: '/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 3, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/base.py", line 11, in from prompt_toolkit.formatted_text import AnyFormattedText, StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/__init__.py", line 15, in from .ansi import ANSI File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/ansi.py", line 6, in from prompt_toolkit.output.vt100 import BG_ANSI_COLORS, FG_ANSI_COLORS File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/__init__.py", line 3, in from .base import DummyOutput, Output File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/base.py", line 9, in from prompt_toolkit.cursor_shapes import CursorShape File "/usr/lib/python3.12/site-packages/prompt_toolkit/cursor_shapes.py", line 8, in from prompt_toolkit.key_binding.vi_state import InputMode File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/__init__.py", line 3, in from .key_bindings import ( File "", line 1354, in _find_and_load File "", line 1316, in _find_and_load_unlocked File "", line 1256, in _find_spec File "", line 1524, in find_spec File "", line 1496, in _get_spec File "", line 1483, in _path_importer_cache File "", line 1452, in _path_hooks KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel cf4b40f8-a9bf-41b7-a5d3-32e58835627d: Kernel didn't respond in 60 seconds _______________ test_run_all_notebooks[Inline Image.ipynb-opts5] _______________ input_name = 'Inline Image.ipynb', opts = {'kernel_name': 'python'} @pytest.mark.parametrize( ["input_name", "opts"], [ ("Other Comms.ipynb", {"kernel_name": "python"}), ("Clear Output.ipynb", {"kernel_name": "python"}), ("Empty Cell.ipynb", {"kernel_name": "python"}), ("Factorials.ipynb", {"kernel_name": "python"}), ("HelloWorld.ipynb", {"kernel_name": "python"}), ("Inline Image.ipynb", {"kernel_name": "python"}), ( "Interrupt.ipynb", { "kernel_name": "python", "timeout": 3, "interrupt_on_timeout": True, "allow_errors": True, }, ), ("JupyterWidgets.ipynb", {"kernel_name": "python"}), ("Skip Exceptions with Cell Tags.ipynb", {"kernel_name": "python"}), ("Skip Exceptions.ipynb", {"kernel_name": "python", "allow_errors": True}), ("Skip Execution with Cell Tag.ipynb", {"kernel_name": "python"}), ("SVG.ipynb", {"kernel_name": "python"}), ("Unicode.ipynb", {"kernel_name": "python"}), ("UnicodePy3.ipynb", {"kernel_name": "python"}), ("update-display-id.ipynb", {"kernel_name": "python"}), ("Check History in Memory.ipynb", {"kernel_name": "python"}), ], ) def test_run_all_notebooks(input_name, opts): """Runs a series of test notebooks and compares them to their actual output""" input_file = os.path.join(current_dir, "files", input_name) > input_nb, output_nb = run_notebook(input_file, opts, notebook_resources()) input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Inline Image.ipynb' input_name = 'Inline Image.ipynb' opts = {'kernel_name': 'python'} tests/test_client.py:351: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': "Image('python.png')"} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'from IPython.display import Image'}, {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': "Image('python.png')"}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Inline Image.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Inline Image.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'from IPython.display import Image'}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {'collapsed': False}, 'outputs': [{'data': {'image/png': 'iVBORw0KGgoAAAANSUhEUgAAAMgAAABQCAYAAABcbTqwAAAABHNCSVQICAgIfAhkiAAAABl0RVh0\n' 'U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAACAASURBVHic7Z15eJNV2vDvJ0/2vUmapk3b\n' 'dG9pKYWyFARkd6GojOI2vs6HfjqKI17i+LnNfM68LpfMq4KjM6/44jbgqKCfKLIoUFrWUigglO5N\n' '1yxttmZfnzzP90dImrZpmqY75nddVZJnO0nOfc597u0gBEFUQ4wYMUJCmuwGxIgxlYkJSIwYYYgJ\n' 'SIwYYYgJSIwYYYgJSIxh8Xg8SHV1Na+srEw42W2ZaMiT3YAYU5vLly9zdu7cmeXxeEh5eXnGVatW\n' '6Se7TRPJlBGQbqONcr5Rzdaa7BSDxUExWl1ko81JNtmcFLPNRTbZnWTMi5PYdCrGYVAxLouK8ehU\n' 'jMemYVwmDeOz6Vg8j+lZXJBqEXAY2GR/nhsFq9VK8Xg8v1pNY1IF5Gy9in2yVsG72NLD69QYGQAI\n' 'ABAABMD1/wx4TYDR6qQYrQ4KaAGACDoHfK9JCEIUyESWFUXpvQ+sKNSjKImAGDGiZFIExGBxkl/b\n' 'U5laWa+O6xMEJMwVkfdxnCCQmnYNt6ZNwz14vkn0xsaVbRlJQteoGnyDg+M4kEi/2kkiLBP+rdR1\n' 'GRgPvnMov7JBHTfez5KrDKyN/7Uv/0h1M2+8nzXdwDAMOX/+PO/9999P37lzp2yy2zNVmXAB+eDH\n' 'y1KjzUUZ+D4SbgIZBS7MS9r69ck0lc486Jm/ZiorK+N27tyZVVNTI3C5XOhkt2eqMqECclmuYV5q\n' '1fQbzedlJ8C7jy6DY2/eB6/cVwLpCWM/2NscHvKrn5el4fiY3zrGDc6ECkhVcw8n+DWXQYV3//dy\n' 'WFKQDGw6Fe5amA2v/ceScXl2TVsPt6FTwxiXm8e4YZlQATFYHP3UnNIFGUCn9LcT5EgFUJgWPy7P\n' 'r2nvZo7LjWPcsEyoFavX6pzUdUB9h5YFAJPq6HI6nSStVkvV6XQUp9OJZmZm2sVisTvS6+VyOUMm\n' 'kznJZPKUMV/jOA4EQSAoio64TV6vF+ns7KSr1Wp6YmKiMzU11RnNfQB8hge1Wk1Tq9U0j8dD4vF4\n' 'nszMTDuDwYhauZ5QAbG7sH4z1o9VcnjytllAp/Y1o1FhgJp27bg8X2uyT4qAWiwW9OTJk8LKykpR\n' 'T0/PIDWPy+W6c3JyzBs3buyi0Wghf8y9e/cmXrp0SaDX6+nbtm37hcPheMM986233spWKpUsAIBN\n' 'mza1FBQUWAEADh8+HH/w4EGp1+sNmEVqa2v5Tz/99Gz/661bt9aw2ewh749hGFJWViZsbGzkajQa\n' 'ul6vpxEEARKJxDF//nzD7bffrhnObFxTU8P+/vvvpSqViolhff2CTCbjSUlJ9vXr1ysLCwutYW8C\n' 'PgE7fvy4sLy8PEGn09EIguhn7mEymdiaNWvUt956q5ZCoYxY8CbVUWh1euCZ/zkO9y/Ng7mZYjhy\n' 'uQP2nqqfzCaNOfv27ZP8/PPPiV6vN9AJ2Gy2RywWOx0OB6pWq5lms5laXV0t0mq19GeffbYlVOc8\n' 'fvx4YnCnHg6Xy4X6rVPB1+E4jmAYRiKIvr7ify+C2yLHjx8XHj58ONFoNNIGHlQqlSylUsmqra3l\n' 'bdmypWWoDrl///6EAwcOSP2dmU6nYxKJxKlUKpkej4fU2dnJ/uCDD3LWrl2rXL9+fU+oe+A4DqdO\n' 'nRIcOnQoyWAw0FAUJSQSiUMsFjvtdjtZrVYzrFYrxW63k3/44YeUioqKhOeff75RIpFEPFsDTIFQ\n' 'kyttWrjSph3sFZ/m4DgOO3bsSLt8+bIQAEAsFjvWrVunKiwstAQLgF6vp/z973/PUqvVzI6ODvbb\n' 'b7+d8+qrrzZEq2YMR2lpqaa0tFRz6tQpwa5du9IBAAoLC3ufeeaZ1uGubWho4DU0NPAQBCHmzp2r\n' 'z8/PN+Xl5dnsdjt69uxZQXl5uQQAoLm5mfvDDz9INmzYoB54j48//ji1qqoqHgBAIBC4Hnnkkbac\n' 'nBwbiUQCj8eD1NTUcHbv3p1mtVopBw8eTO7u7mY8+eST7cH3aG5uZn7++edpGo2GQSaT8aVLl/bc\n' 'dddd3TweLxBihGEYcuDAAfGhQ4ekBEEgJpOJumvXrtQXXnihZSTf16QLyI2Kx+Mh+YUDAOD111+v\n' 'C6V2CIVCz3PPPdf82muv5VssFopKpWKePn06btmyZYYJbXCEpKenWx588MGu9PR0R/D7aWlpSgRB\n' 'iOPHjycCAJSVlUnWrl2rYTKZgcGgvr6e5ReO+Ph4x4svvtgU3KkpFApRXFxs5vP5zdu3b891Op3o\n' 'xYsXhTU1NfrCwkKL/7yGhga2RuOzSBYXF+t/97vfKQa2k0wmE+vXr+9xOByov00tLS1cl8tFGkqN\n' 'DUUsvmCCCKeT8/l8bN68eQHjQXl5uXhCGjVCMjMzza+88krTQOHwc9NNNwWEGsMwUkdHB93/Gsdx\n' '2LNnT4r/9e23395vxA8mIyPDUVpaqvS/3rt3bzIepRPrjjvuCKhoBEEgKpVqkGoYjpiATBEWLlwY\n' '6FxKpZLV2Ng45UzSFAolbC+VyWRODofj8b9WqVQBAampqeH4jQZsNtuzaNGi3nD3WrJkiYFMJuMA\n' 'AN3d3cyLFy9G5UFms9leNpsdaBOO4yOK2ZhQFeuvDy7ssLuwrtBHh1e5d5VdTThwrmVKjq6jJSMj\n' 'w4GiKO5fzHd1dTFyc3Ptk92ukSKTyazXrl2LA/Cpmf73Ozs7A9a7pKQk+3Bmajab7U1LS7O2tLRw\n' 'AXzfx/z5803RtIlGo3mtVmtUFswJFZB4HnNUeRpsBjWsaXO6w2QyMYvFQgUAMBgM1MluTzRQqdSQ\n' 's4xarQ4ICI/H84Q6ZyBcLjdwXnd3Nz3cuePFmAiIXG2inWpQczu1FnqnzkLXmx3UgBmRGJjXAX2v\n' 'g/8/6Lygk68fs9idYyPQ5vNs6Ngm6/9sAgAQAGqCC5jZdmDNsIFgpRmQ8bEmhYLFYgUExGg0TksB\n' 'GQqtVhvo4JEKSLC6ptFopp+AdGgt1A+P1CZV1CgFfQ6aAR18yI4fyXkhjo0FXjsJ3N30wQICAC4V\n' 'HSyXfPpu91dWyHqzFWiJEf2goyXYb2CxWG4oCyOFQgnM/h6PJ6J1QLCKNtTMNN5EvUjfc0YufHD7\n' 'sZnlNUohQYTNdpq+2BrYcG1jPlivTUiQo9VqDQhFsHpxIyASiQJJa2ZzZKkHwYOEUDg5SW9RCciR\n' 'Kwreeweuyrw4cWMKRjBeCxla30gDInIvdrQELyRFItGIPL5TnYSEhEAHj1R9DP4+EhISnOPRruEY\n' 'sYBUy7Ws17+5mIHfqLNGKJwdTFB8PK7WM41GQw1WKeLj44ccMV0u17Qzz6empgZ8J11dXSyHwxH2\n' 'M3i9XiR43ZKSkhLS9zLejPiL/vDnOqnbi0+7H2jUdO9JBNw9boPCyZMnA153CoWCFxUVmYOP0+n0\n' 'gAUw2GQaLURwMNYEUFhYaJFIJHYAnxOxurqaH+78y5cvc/0ziEQiccyZM8cc7vzxYkQdvUllol/r\n' '6uUMf+ZomYLxWLgdhd4T3KgvD+MJtlqt6Llz50T+1yUlJdqB0bopKSkBn8iJEyeGTZgZGNU6EIFA\n' 'EFjjGI3GCYlyXrt2bSA269ChQ4lWq3XIVN+KiorA97Fu3TrVZBWVGNFT95yRj08m0wTBpJF9nc5r\n' 'jy4HW3806kITr7zySkF5eblgYESu3W5Ht23blmUymagAvtmjtLR0UATr7NmzA57nuro6/q5du5JD\n' 'qSk1NTXsN998M1elUoX1xMtksoDKolarmd3d3eNuVi4pKTGmpqZaAQB0Oh39ww8/TB84cOA4Dp9+\n' '+mlKY2MjHwAgIyPDUlJSYhzvtg1FxKZEHAcor1MJxrMxoyKCSSdbKvJ1CnuUYRymaj4QRFQVJvR6\n' 'Pf3LL79M379/f7JUKrXHx8c7tVotXS6Xc/yh5kwmE9u0aVOLSCQaZMFatWqVXi6Xsy9cuCACADh1\n' '6lTCpUuXBOnp6VaBQOA2Go0UhULBMhgMg2KNEAQZ9O1wOBzvihUrusvLyyUYhpG2b9+eM2fOHENB\n' 'QYG5oKDAOh4jNolEghdeeKF5x44dadeuXYtramrivfzyyzOzs7PN6enpNpVKxWhubuao1WomgC8Q\n' '8bHHHusY84aMgIgFpF1rptmc2LS2zRekiX1qir2JFdUNcDsKjlYaMDNHbHLcsmVL4+HDhxMaGhr4\n' 'jY2NvMbGxn6xRUKh0Ll58+YWqVQ65L0fffTRToFA4C4rK5NgGEay2WwUf1iHH6lUaisuLu5tbGzk\n' 'NDU18QAAhsqou//++1Verxc5c+ZMvMFgoJWVlSWWlZUlRpKQFS00Gg3fvHlz6zfffJNUUVGRYDAY\n' 'aFVVVfH+KF8AACqV6l2zZo16qFyQiSTiDn+1XR9dp5oisBhkrChTYgOCAHC2Rx8IaL3GjEZA8vPz\n' 'rfn5+VaFQkFvaGhgaTQautVqJctkMltBQYE1OTl5WDMmmUwmNmzYoF6xYoWutraW7Q+/4PP5nri4\n' 'OI9MJnP403ffeeedwFoxOOQ8GBRFiYcfflixdu3anqamJlZPTw/N5XKhdDo9IFCFhYXmzZs3NwEA\n' 'cDicYUOF1q1b17148WI9AEBSUlLIz0QikeD+++9XbdiwQd3W1sZobm5mdXd305OSkhw5OTk2mUzm\n' 'CDeDLVy40OhXEYPXUkOxcePGdrfbTQrXpqGIWEDqlMYpF106Ev5w16IuNoOGg6GMB7gj+jpQtnoW\n' 'wF1hI1HDkZyc7IxEGMIhFAo9N998c9g26PX6gKrFYrHCzgZCodCzaNGikHo+n8/H+Hy+JdSxUKSk\n' 'pDhTUlIi+nwoihJZWVn2rKysEQVlxsfHu+Pj4yP2E+Xl5dlGcv9gIlY0WzWWaVsyZ26u1HjP0gID\n' 'eIwoKD4YXRVBe/OUHyhwHIfe3t6AgITLL48RnohnkF7r4GqIE8IoLb4rZqfr//TbZb4Q+863UwEz\n' 'je5zuDVTPohQp9NR/dYyiURiH6/03V8DEQuI1emZVgt0cRzLtemO+Yq1C3J8qoP6Xwlgqhy9FQ4z\n' 'T/nvoaurK+CBzs/PjyqHIoaPUQjI2AxKCAAkCdjO7CS+LUPCc6AoQvTdeuAzCICQ9hhfBDAZJREZ\n' 'SXHOWWliO5/D8KkVLjUFOramga0maidfP3AnCl4nCVD6lCxkajQayV9//XUqgM+8u2DBgqjXSzEi\n' 'FBCvF0cw79gGJgo5DPczpbO7FhckWTgM2tjryI52GpgrudD9b+moFuWh8OjIgCZPqWBCj8eDlJWV\n' 'iY4ePSoxm81UAIC77767KzMzc1JimG4UIhIQFCURdArqdXq8Y9LRVhel6l7aME8REAyXggb2eia4\n' '2hm+qNng5KoBs0hw7sagxCovAq4OBthbmYDbyb773Jjqt8vlIp0+fTquo6ODqVQqmWq1mukPdqTT\n' '6VhpaanqtttuG58KfL8iIlax2HTKqAUEAYA/318iXzc/w7cuMB6LA83uFPBaKP06/sCkqUGJVUP9\n' '23/tOAsFRTSsPwBFUUIoFDr1ev24ZMKRyWRi3759Kf7icAiCEGKx2JGXl2dev369erwcfb82RiIg\n' 'mM7iHJUF586SjJ518zOMgJlR6P5nKliqBVMyMDEcJBoeyfqDTCYTW7durW1paWFWVo6BcWAAKIoS\n' 't9xyixpFUSI9Pd2WmZnpGEm9pxiREbGACDk0d7vWErUPQCpkOZ9bX6wCAADl2+ngqJ+euz6hI8v0\n' 'i8YRFil33nnnpIdi3OhE7CjMSuSNarH3yr0L2ukUMg6GA6JpKxwAAIzQRdNiTF3MNgf69ZEq4b8O\n' 'nhENf3Z/Ip5B8qT866PgyFUiLpPqmZeZYAOvBQXt18kjvsFUgjsn4rCLGFODl//5rez0L81xty6a\n' 'qQMA3UiujXgGmZnCj1pNyE6K88XC2BuYQEzz/fC482MCMs3AvL5qimTSyLcEj1hAUkUcN4dOGb7w\n' 'W4gmzEiO8wmXs2VaRwQDysaAPTOmYk0zsOthNyg6jgICALA4LyEqr2xO0vXZxzX6XOpJRbDCMG7b\n' '8cYYN7z+GSSKmLQRCci6ualRbV9GRq9ntBHTrxpHPxLuiTnepiF+FQsdTxULAGB+ltgm4TMmpT7R\n' 'pMPMsQIr79f52ac5/hkERUc+Po/4is23zxy0WcmvguTfqya7CTGiw4v7VayRzyAjDt1ePSvZVHFN\n' 'pTt6VTFim/K0hX+zHuKWjMp6pek1k89caeGotL3Ubr2JKhHy3HNnpFnn5MrsNEr4rQA0vWbyxfp2\n' 'Vk2LkuXBMKQwK9k2Ny/NJhXHDXJa2hwu0uGzV/kpCUJXycyMkJl0ap2Rsq/ikuC3ty7U8TmD03Fr\n' 'W5WMK01dzLuWzellMfp7501WB1p1Tc6ub1MzUhOFrtnZKfZ06dBF7vxgXhyplSsYV5q7mLWtKpbJ\n' 'aifftqjQsH558aB1bV2bil51Tc7xYF6kIENqn52Tah/YjoGYrA70fG0rq7q+neP2YIhUHOdaUJBu\n' 'nZWV4sD6ZpCJ2cTzpbvndCn0Vnq90siO5vppBTXBBWl/jHrWvNTQwfz4h5OSc9fkfP9UH2DfCUhL\n' 'FNl3/nljsziOG9JCuOvgGdH7e46leLC+TUD3HrsACAKwcd0S5TMPrOkmBRkOHv7Lzly5QsNcNX+G\n' 'PpSAlF2o4/7xva+zCQIgns/x3Lt6/qCt3vaf/EXw9ZEqybLiXHNwx3z3i58Sdx+uTCQIAiGREAK/\n' 'Xnr2jqWzNa8+dqeCGkLQPZgX+eLwWdGXP51L0PRaAlmOCIIQW357qzL43Dallrbpb7uy1DoT3X8O\n' 'QRCIkMd2/23zva3z89NDCvyFujbWs9u+zLLaXWQAgOC2yRKFDr3JV4AuGjNvVALCplPwT/6wvPHj\n' 'soaEXRWNSRh2g1Za5C3shcy/dgCZG1Xg3+5DZ0XbvzqSCgBw28KZupuLc015skSHWMDFTv/SxHnr\n' '84OydrWO+ch/fpK7+7XfNwi4/XPHX/zgG9lPlTUiBo3i/cO9KztXzJ1hwrxe5Oj5Ov6n+08lffbj\n' 'aWldm4q14+X/JfcLybwZaWa5QsOsqm3lYV4cGahWlJ2v4/tjOY9X1/NDCUjl1RZehjTeHjxD/eWj\n' '71O+P3FJnJUstr36+F0dBRlSZ61cwfjTh9+l/XjqF7HZ5iC///xDbcH3MVrs6Oa3v8i82qLg0Chk\n' 'fMOqeT2Fmck2iYjndro8pFyZJLCmq2tT0Z/auivHZHOQn/jNcsUDt5boUBIJ/v1Tpeij7yqSn3jr\n' 'X7m7/vp4/cxMaT8z+4lLjZz/8/c9WS4PRpqTm2p+fP0y9YKCDFtnt556/EI978ufz0n8gjNhMwgA\n' 'AEoiwRNr8nvWFct6q+UaVpPayGzrNjMcLn992b4oWx6LPjaRpeQ4N5CFrpDh7kNG84aLEIaga/37\n' 'g8S7gZFlB3a+HXglw+7THY4vDldKvF4ceeLu5YqnNqzsFzd1y8KZJomI1/y7v+zMV2h66V/+dE70\n' '9H2rAuccOnOV91NljYhCRvGdf3qksTArOdAxslISetKTRM6X/vFtZtW1Vv63ZRcE961eYAAAWL0g\n' '37jn6HmJ1e4iV15tYS+dk9NPNTx3rTUQ5nOxoZ3ncLlJDFrf1gKd3XpqR7ee8fDamwJrrjNXmtnf\n' 'n7gkBgDY/tyDrakSoRsAoCgn1f7PF/6j5c4/vl948nJTXJtSqwpWt9776kji1RYFR8BluXf/5+ON\n' 'yQmCIXNo3vrsQGqvxU5ZvSBf/9S9fd/VUxtW9sgVGsax83XCz348lfDusw+0+495MC/yxqc/ylwe\n' 'jJSeJLL/44WH5ezrM15mstiVmSzWPFx6k7b02e0zdUYrNRoz76jTR6VCllsqTHcDwPhnrvFu1kPi\n' '49Nmsex3UNEo5JD686ysFMeMtCRrXZuKvf/k5fin7l3ZQ0IQcHkw5L2vjqQAAKycN8MQLBx+bltU\n' 'aNpXccl0rkbO/+i7Culdy4p7aRQyMS8/3cZnMzxGq4NSdqGOFywgV5o6mXqTlbpiXp6+vLpB6HJj\n' 'pIqLDZzbb5oVSMs9WlXLAwBYNX9G4L0vfz4nBgDIShHb/MLhR5YocicIuK4eg5m25+h54UsbSwO/\n' 'j9vjK4gXx2Vh4YSjrk1Fv9qi4AAArF6QP6gfLSjIMB87XyesuNggsNidnRymL5r627JqgcZgpgEA\n' 'PH3faiU7xDqFTqUQpOuF88bdUTjpYEYy2OqZfX91Q/zV9v1Zg/6cnSPa4XS0BBxU5KFHrvkF6WYA\n' 'gB6DmdbYrqYDAFxt7mL2XP/h1y6eNeR20LctKjQAAOiMVmpDm4oBAEBCECgpzDQBAJy52tKvQHRZ\n' 'tS9I9Pe/Wd6dKOI5AQCOX6jvd87pK808AZflmZMrswMAuD0YUnlVzgcAWDlvRshBMD8jyQoA0KUx\n' '9Mt9CYR4DNMxD56+IgAAoFHJ+Ip5MwYVqfavPTAvjnSo+8oZHTpzRQjgK3Q51PqkXzuiqBY55QsQ\n' '9MN0Ih6MFfGRJ0wN+De72AjZ78gnqrkB82KYxaGQywro+Wq9iTojPclZf72zAwAMHLGDSUmICxxr\n' 'VeloRTmpdgCAlfNmGH+uvCbSGMy0a3Ilw6+3n7nSzEsQcF356UnOJUU5xm/KLviMBzjegZJIYHW4\n' 'SDUtCs7qBfkBh3C7Wkfzf45DZ66KTlxqjAMAgoQggFxf92iNvm3j9Mb+G2X6rxvOQdfZ3Vcu9eFX\n' '/ycXQRACQRBAAALPCHxHOiPF/3kUGl9po1SJ0MFjM4ZU4wO/Q5iBaiiml4BMM7AIHFRsZt/6rFvv\n' 'K0nUptIFRuL4OM6Q+Sc8Vt+mqEpNbyCZbVlxroVGIeMuD0Y6WlXLn5kpdXTrTZSWLg3r7hVzewAA\n' 'Vi3IN31TdkFitjnJ52rk7MVF2daKiw1cD+YlLZ+bF1Cv2pS6QOdNlQgdDNrgraATRTwXAICQ17+t\n' 'fhVzuBlEpfV1dC6LgaUkCEI6Y/3P8FvVbA4XyWC2UQEAZmYmh10r+o1I0XjSYwIyjvhVLEqYkcvt\n' '6TPfErjvtGChaVVqaUXZoTeP6bXYAr+fWNDXORk0Kl6cJzNX1sj5p39p4m357S3qY+fr/GsLIwDA\n' 'goJ0K4/N8JisDsrRqlr+4qJs68lLjTwqhYwvK84NrFs8QdXon75vlbogQxpxsCYWYQyUf4SXJQod\n' '27Y82B7JvYPXE8N1fAyPTFBDMb3WIJGATJ26blgEKoa2t2+/Pr8FKFHEC6hOjR3qIQM8e/R912an\n' '9N+i7ObiXCMAQItCw1JpeymnfmnisZk0bGFhlu16m2DhzOtrlSvNfJwgoKq2lTcnJ9UcbNXKShYH\n' '7mu1jyyWzhuhgy5VInQCADicnojvT6dSCA7Tt6lQU2d32EzXSNsRihtHQOgZAKkvAczcB5D1DgC3\n' 'ZLJbFBRFOvQPE6xOZaf6OnlwZ2/u7BlSQJoVvmM0ChnPSZX0E5BbSmaa/Nse7D/5S9zlhg7ugvwM\n' 'U3BbVl6fTTS9Ftq/D1eKjBY7ZemcnH6F5jKk8S4SyXef2lbliFKuI12kpyfFOwEAunr0DJcHizhc\n' '2q92tSm1TGygEzYI/wxFGe9o3tEzjqHishcB4lYAkCgA7CKAtFcB0LGpFRcNHqxPNRlqcWi2OdAz\n' 'V5vjAADm5qWZ4vm+6unz89Nt2SkJNgCAps6ekJ0SJwg4fLZGCABwz8p5PQNDMUR8NjYjLdEGALD7\n' '8NlElwfrt7YA6FurAADs+K5cCgCwekFBv3OoFDKRIY23AwB8V35xRBsoRTpyF+fJrAAAZpuT/H3F\n' 'pYg3KVq7eJYeAMDlwUi1rcqQ1WO8OB6w00z9GYQyfMxOVLBmAdDT+r9HogII1/Z/jyqZsK2EgwXk\n' '5OUmntHSf1crL47DXz76PsXl9vkKnrxnuTr4+KN3LlUDAPzS1Mn95tiFQVVRdnxbnqAxmGlsJg17\n' '8p4VIYs3LJ3jK7tqtbvIZJRErAzybQD0rVX852SliG2JIt4go8BrT/ymg0JG8a4eA2Pr5weTQj3r\n' 'aksX40pzV7/ZLtJF+rLiXMuakgIdAMCO/1curWtTDersJqsDPXjmCh8PcgLfu3qBnkmnegEA3vhk\n' 'vyzU7FNe3RAYJf3+k5EwsYt0Rq4NjGVjf198iGzgge+zCqIugz9SggXk4Okr8ccv1AtuLs7pzUoW\n' 'O5xujHTyUiO/uauHBQDwxN3LFQsK+sdNrV08y9TRrVd89F158t92HZI1dfYwlszONlvsTrTiYgPv\n' 'aFWtSMRnu7c9+4B8KBPnLSUFxo++q0gGACjKTjWH6iDL5+YZK2t8fo7FRdkh6/gWZEgdT9+7SrH9\n' 'qyOpXx2pSmzq7GHeVJRliudzsHM1ck5VbStPb7JS581IM33yfx9t8V/nvW50iMSD/dffr++6Jlew\n' '1ToT/bHXP8srXVKknZkptat0RurZK8282lYV24vjiDiO2+D3ebAZNPzdZx9o2bLtq6ymzh7WY69/\n' 'mn3nzXN0yQkCd0O7inHkXK2grk3FnpGWaH3uoVsHfceRMMECUjCq0I0hcbQA2OoBWDP63vPaAQxH\n' '+5/HmTM+zw9BsIBsvn91Z0O7mnmsqk74c+W1wPsiPtv91IaVintWzgvpgNt0z4oemUTo/O9vj0u/\n' 'KTsv2XvsvAQAgEGjektmZhhff/LujgRB6CBHAICslARXsjjOaXe60Q2r5oVM9lpTUmD6265DRLJY\n' '4Fy3pGjIaIiNdyzRshg0747vyqUXG9p5FxvaAyErSSK+87mHbu144JaSfgl1I0l1ZTNo+Cd/frTp\n' '7S8OS8urG4R7j52X7D3mO0Yho/jNxTmGJ36zvHtGev8NcG6alWV9//mHmv9r96GUGrmS7ffIC7gs\n' 'T4Y03v7mprvl65bOjnqPQ4QgiOpoL46K7o+lYPxJAgBDV0mMprIiWQggvAMgbhWA9TKA9juf4Pin\n' '5LhVWkh7pXNcP1sQap2Jctsz784CAHj/+YealhXnWowWOypXaGiaXjOlIEPqCOcEHIjZ5kCvNncx\n' '4uO4WHZqgpMUYepvZ7eeKhXHudEw4OU8RgAAAbxJREFUXuR2lY6aliSKqC1eHAdFj4HaqtTSeGym\n' 'NytF7OKyQs9gLg+G4DiOkFGUCGfqHojZ5kDlCg2t12InZyTFO1MkgrDt92O02NH6djUjK0Xs9K/n\n' 'RsvECwjhRaDjT9ngbOGMqYCE86QzMm2Q849GIFEnrIxjV4+Bum7Le4UAAP/94sONi4uyJ2z2ijF2\n' 'TLyZF0EJSH5ZDqy5Q8YYjSmsmWbIeEM+kcIB0F/FGsnoGWNqMTmedDLPCykvt4HpRC/0fJYKXvPY\n' '716FsjFIfLQLRHdMjCAOwB1kUYkJyPRlckNNeMuMwL3JBKbTPDAeE4G9jje6YtYIADPfDHGr9CBY\n' 'bQTS5G1yEzyDRGN/jzE1mPxYLIRCAH+FEfgrjOAxkMF2lQ32OjY4mlng6mKGLRWEUHGgp9mAmWMD\n' 'Zr4V2EU2oAjGZHE2WrCgGKZoPLgxpgaTLyDBUAQY8Jcbgb+8zyzntZHAo6cAZiAD7iYByvICyvEC\n' 'mesFlIsBMjWjZThMulfEZ7t1Ris1pmJNXybeivUrAicIOHulmV2YlRI2XyHG1CUmIDFihGFq6icx\n' 'YkwRYgISI0YYYgISI0YY/j+SFgT3yDrlYgAAAABJRU5ErkJggg==\n', 'text/plain': ''}, 'execution_count': 2, 'metadata': {}, 'output_type': 'execute_result'}], 'source': "Image('python.png')"}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff80390ae0> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709559608.8204887 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 3, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/base.py", line 11, in from prompt_toolkit.formatted_text import AnyFormattedText, StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/__init__.py", line 15, in from .ansi import ANSI File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/ansi.py", line 6, in from prompt_toolkit.output.vt100 import BG_ANSI_COLORS, FG_ANSI_COLORS File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/__init__.py", line 3, in from .base import DummyOutput, Output File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/base.py", line 9, in from prompt_toolkit.cursor_shapes import CursorShape File "/usr/lib/python3.12/site-packages/prompt_toolkit/cursor_shapes.py", line 8, in from prompt_toolkit.key_binding.vi_state import InputMode File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/__init__.py", line 10, in from .key_processor import KeyPress, KeyPressEvent File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/key_processor.py", line 19, in from prompt_toolkit.utils import Event File "/usr/lib/python3.12/site-packages/prompt_toolkit/utils.py", line 18, in from wcwidth import wcwidth File "", line 1354, in _find_and_load File "", line 1316, in _find_and_load_unlocked File "", line 1256, in _find_spec File "", line 1524, in find_spec File "", line 1498, in _get_spec File "", line 1625, in find_spec File "", line 128, in _path_join KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel a120813f-ae1b-4166-99cc-9038008ac644: Kernel didn't respond in 60 seconds ________________ test_run_all_notebooks[Interrupt.ipynb-opts6] _________________ input_name = 'Interrupt.ipynb' opts = {'allow_errors': True, 'interrupt_on_timeout': True, 'kernel_name': 'python', 'timeout': 3} @pytest.mark.parametrize( ["input_name", "opts"], [ ("Other Comms.ipynb", {"kernel_name": "python"}), ("Clear Output.ipynb", {"kernel_name": "python"}), ("Empty Cell.ipynb", {"kernel_name": "python"}), ("Factorials.ipynb", {"kernel_name": "python"}), ("HelloWorld.ipynb", {"kernel_name": "python"}), ("Inline Image.ipynb", {"kernel_name": "python"}), ( "Interrupt.ipynb", { "kernel_name": "python", "timeout": 3, "interrupt_on_timeout": True, "allow_errors": True, }, ), ("JupyterWidgets.ipynb", {"kernel_name": "python"}), ("Skip Exceptions with Cell Tags.ipynb", {"kernel_name": "python"}), ("Skip Exceptions.ipynb", {"kernel_name": "python", "allow_errors": True}), ("Skip Execution with Cell Tag.ipynb", {"kernel_name": "python"}), ("SVG.ipynb", {"kernel_name": "python"}), ("Unicode.ipynb", {"kernel_name": "python"}), ("UnicodePy3.ipynb", {"kernel_name": "python"}), ("update-display-id.ipynb", {"kernel_name": "python"}), ("Check History in Memory.ipynb", {"kernel_name": "python"}), ], ) def test_run_all_notebooks(input_name, opts): """Runs a series of test notebooks and compares them to their actual output""" input_file = os.path.join(current_dir, "files", input_name) > input_nb, output_nb = run_notebook(input_file, opts, notebook_resources()) input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Interrupt.ipynb' input_name = 'Interrupt.ipynb' opts = {'allow_errors': True, 'interrupt_on_timeout': True, 'kernel_name': 'python', 'timeout': 3} tests/test_client.py:351: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'print("done")'} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'while True: continue'}, {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'print("done")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Interrupt.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Interrupt.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'ename': 'KeyboardInterrupt', 'evalue': '', 'output_type': 'error', 'traceback': ['\x1b[0;31m---------------------------------------------------------------------------\x1b[0m', '\x1b[0;31mKeyboardInterrupt\x1b[0m ' 'Traceback (most recent call last)', '\x1b[0;32m\x1b[0m ' 'in ' '\x1b[0;36m\x1b[0;34m\x1b[0m\n' '\x1b[0;32m----> 1\x1b[0;31m ' '\x1b[0;32mwhile\x1b[0m ' '\x1b[0;32mTrue\x1b[0m\x1b[0;34m:\x1b[0m ' '\x1b[0;32mcontinue\x1b[0m\x1b[0;34m\x1b[0m\x1b[0m\n' '\x1b[0m', '\x1b[0;31mKeyboardInterrupt\x1b[0m: ']}], 'source': 'while True: continue'}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'done\n'}], 'source': 'print("done")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} opts = {'allow_errors': True, 'interrupt_on_timeout': True, 'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}, 'timeout': 3} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff80392520> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709559698.2495852 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 3, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/base.py", line 11, in from prompt_toolkit.formatted_text import AnyFormattedText, StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/__init__.py", line 25, in from .html import HTML File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/html.py", line 3, in import xml.dom.minidom as minidom File "/usr/lib64/python3.12/xml/dom/minidom.py", line 23, in from xml.dom.xmlbuilder import DOMImplementationLS, DocumentLS File "/usr/lib64/python3.12/xml/dom/xmlbuilder.py", line 6, in from xml.dom.NodeFilter import NodeFilter File "", line 1351, in _find_and_load File "", line 418, in __enter__ File "", line 311, in acquire File "", line 170, in __enter__ File "", line 132, in setdefault File "", line 74, in __new__ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 0359d75a-86dd-4c48-b6b6-220acacc0edb: Kernel didn't respond in 60 seconds ______________ test_run_all_notebooks[JupyterWidgets.ipynb-opts7] ______________ input_name = 'JupyterWidgets.ipynb', opts = {'kernel_name': 'python'} @pytest.mark.parametrize( ["input_name", "opts"], [ ("Other Comms.ipynb", {"kernel_name": "python"}), ("Clear Output.ipynb", {"kernel_name": "python"}), ("Empty Cell.ipynb", {"kernel_name": "python"}), ("Factorials.ipynb", {"kernel_name": "python"}), ("HelloWorld.ipynb", {"kernel_name": "python"}), ("Inline Image.ipynb", {"kernel_name": "python"}), ( "Interrupt.ipynb", { "kernel_name": "python", "timeout": 3, "interrupt_on_timeout": True, "allow_errors": True, }, ), ("JupyterWidgets.ipynb", {"kernel_name": "python"}), ("Skip Exceptions with Cell Tags.ipynb", {"kernel_name": "python"}), ("Skip Exceptions.ipynb", {"kernel_name": "python", "allow_errors": True}), ("Skip Execution with Cell Tag.ipynb", {"kernel_name": "python"}), ("SVG.ipynb", {"kernel_name": "python"}), ("Unicode.ipynb", {"kernel_name": "python"}), ("UnicodePy3.ipynb", {"kernel_name": "python"}), ("update-display-id.ipynb", {"kernel_name": "python"}), ("Check History in Memory.ipynb", {"kernel_name": "python"}), ], ) def test_run_all_notebooks(input_name, opts): """Runs a series of test notebooks and compares them to their actual output""" input_file = os.path.join(current_dir, "files", input_name) > input_nb, output_nb = run_notebook(input_file, opts, notebook_resources()) input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/JupyterWidgets.ipynb' input_name = 'JupyterWidgets.ipynb' opts = {'kernel_name': 'python'} tests/test_client.py:351: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "# it should also handle custom msg'es\n" "label.send({'msg': 'Hello'})"} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 'import ipywidgets\n' "label = ipywidgets.Label('Hello World')\n" 'display(label)'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "# it should also handle custom msg'es\n" "label.send({'msg': 'Hello'})"}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.6.4'}, 'widgets': {'application/vnd.jupyter.widget-state+json': {'state': {'8273e8fe9d9941a4a63c062158e0a630': {'model_module': '@jupyter-widgets/controls', 'model_module_version': '1.4.0', 'model_name': 'DescriptionStyleModel', 'state': {'description_width': ''}}, 'a72770a4f541425f8fe85833a3dc2a8e': {'model_module': '@jupyter-widgets/controls', 'model_module_version': '1.4.0', 'model_name': 'LabelModel', 'state': {'context_menu': None, 'layout': 'IPY_MODEL_dec20f599109458ca607b1df5959469b', 'style': 'IPY_MODEL_8273e8fe9d9941a4a63c062158e0a630', 'value': 'Hello ' 'World'}}, 'dec20f599109458ca607b1df5959469b': {'model_module': '@jupyter-widgets/base', 'model_module_version': '1.1.0', 'model_name': 'LayoutModel', 'state': {}}}, 'version_major': 2, 'version_minor': 0}}}, 'nbformat': 4, 'nbformat_minor': 2} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/JupyterWidgets.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/JupyterWidgets.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {}, 'outputs': [{'data': {'application/vnd.jupyter.widget-view+json': {'model_id': 'f46f26da84b54255bccc3a69d7eb08de', 'version_major': 2, 'version_minor': 0}, 'text/plain': "Label(value='Hello World')"}, 'metadata': {}, 'output_type': 'display_data'}], 'source': 'import ipywidgets\n' "label = ipywidgets.Label('Hello World')\n" 'display(label)'}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {}, 'outputs': [], 'source': "# it should also handle custom msg'es\n" "label.send({'msg': 'Hello'})"}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.6.4'}, 'widgets': {'application/vnd.jupyter.widget-state+json': {'state': {'8273e8fe9d9941a4a63c062158e0a630': {'model_module': '@jupyter-widgets/controls', 'model_module_version': '1.4.0', 'model_name': 'DescriptionStyleModel', 'state': {'description_width': ''}}, 'a72770a4f541425f8fe85833a3dc2a8e': {'model_module': '@jupyter-widgets/controls', 'model_module_version': '1.4.0', 'model_name': 'LabelModel', 'state': {'context_menu': None, 'layout': 'IPY_MODEL_dec20f599109458ca607b1df5959469b', 'style': 'IPY_MODEL_8273e8fe9d9941a4a63c062158e0a630', 'value': 'Hello ' 'World'}}, 'dec20f599109458ca607b1df5959469b': {'model_module': '@jupyter-widgets/base', 'model_module_version': '1.1.0', 'model_name': 'LayoutModel', 'state': {}}}, 'version_major': 2, 'version_minor': 0}}}, 'nbformat': 4, 'nbformat_minor': 2} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff803909a0> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709559786.809587 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 56, in from prompt_toolkit.key_binding.defaults import load_key_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/defaults.py", line 10, in from prompt_toolkit.key_binding.bindings.basic import load_basic_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/basic.py", line 17, in from .named_commands import get_by_name File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/named_commands.py", line 15, in from prompt_toolkit.layout.controls import BufferControl File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/__init__.py", line 49, in from .containers import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/containers.py", line 34, in from .controls import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/controls.py", line 32, in from .processors import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/processors.py", line 27, in from .utils import explode_text_fragments File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 929, in _load_unlocked File "", line 990, in exec_module File "", line 1075, in get_code File "", line 507, in cache_from_source File "", line 134, in _path_split File "", line 134, in KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel efc650ee-7fd1-4686-b813-91271a4b0966: Kernel didn't respond in 60 seconds ______ test_run_all_notebooks[Skip Exceptions with Cell Tags.ipynb-opts8] ______ input_name = 'Skip Exceptions with Cell Tags.ipynb' opts = {'kernel_name': 'python'} @pytest.mark.parametrize( ["input_name", "opts"], [ ("Other Comms.ipynb", {"kernel_name": "python"}), ("Clear Output.ipynb", {"kernel_name": "python"}), ("Empty Cell.ipynb", {"kernel_name": "python"}), ("Factorials.ipynb", {"kernel_name": "python"}), ("HelloWorld.ipynb", {"kernel_name": "python"}), ("Inline Image.ipynb", {"kernel_name": "python"}), ( "Interrupt.ipynb", { "kernel_name": "python", "timeout": 3, "interrupt_on_timeout": True, "allow_errors": True, }, ), ("JupyterWidgets.ipynb", {"kernel_name": "python"}), ("Skip Exceptions with Cell Tags.ipynb", {"kernel_name": "python"}), ("Skip Exceptions.ipynb", {"kernel_name": "python", "allow_errors": True}), ("Skip Execution with Cell Tag.ipynb", {"kernel_name": "python"}), ("SVG.ipynb", {"kernel_name": "python"}), ("Unicode.ipynb", {"kernel_name": "python"}), ("UnicodePy3.ipynb", {"kernel_name": "python"}), ("update-display-id.ipynb", {"kernel_name": "python"}), ("Check History in Memory.ipynb", {"kernel_name": "python"}), ], ) def test_run_all_notebooks(input_name, opts): """Runs a series of test notebooks and compares them to their actual output""" input_file = os.path.join(current_dir, "files", input_name) > input_nb, output_nb = run_notebook(input_file, opts, notebook_resources()) input_file = ('/builddir/build/BUILD/nbclient-0.9.0/tests/files/Skip Exceptions with Cell ' 'Tags.ipynb') input_name = 'Skip Exceptions with Cell Tags.ipynb' opts = {'kernel_name': 'python'} tests/test_client.py:351: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "print('ok')"} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'tags': ['raises-exception']}, 'outputs': [], 'source': 'import sys\n' 'print("hello")\n' 'print("errorred", file=sys.stderr)\n' '# üñîçø∂é\n' 'raise Exception("message")'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "print('ok')"}], 'metadata': {'kernelspec': {'display_name': 'Python 3 (ipykernel)', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.10.9'}, 'widgets': {'application/vnd.jupyter.widget-state+json': {'state': {}, 'version_major': 2, 'version_minor': 0}}}, 'nbformat': 4, 'nbformat_minor': 4} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Skip Exceptions with Cell Tags.ipynb' mode='r' encoding='UTF-8'> filename = ('/builddir/build/BUILD/nbclient-0.9.0/tests/files/Skip Exceptions with Cell ' 'Tags.ipynb') input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'tags': ['raises-exception']}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'hello\n'}, {'name': 'stderr', 'output_type': 'stream', 'text': 'errorred\n'}, {'ename': 'Exception', 'evalue': 'message', 'output_type': 'error', 'traceback': ['\x1b[0;31m---------------------------------------------------------------------------\x1b[0m', '\x1b[0;31mException\x1b[0m ' 'Traceback (most recent call last)', 'Cell \x1b[0;32mIn[1], line 5\x1b[0m\n' '\x1b[1;32m 3\x1b[0m ' '\x1b[38;5;28mprint\x1b[39m(\x1b[38;5;124m"\x1b[39m\x1b[38;5;124merrorred\x1b[39m\x1b[38;5;124m"\x1b[39m, ' 'file\x1b[38;5;241m=\x1b[39msys\x1b[38;5;241m.\x1b[39mstderr)\n' '\x1b[1;32m 4\x1b[0m ' '\x1b[38;5;66;03m# üñîçø∂é\x1b[39;00m\n' '\x1b[0;32m----> 5\x1b[0m ' '\x1b[38;5;28;01mraise\x1b[39;00m ' '\x1b[38;5;167;01mException\x1b[39;00m(\x1b[38;5;124m"\x1b[39m\x1b[38;5;124mmessage\x1b[39m\x1b[38;5;124m"\x1b[39m)\n', '\x1b[0;31mException\x1b[0m: message']}], 'source': 'import sys\n' 'print("hello")\n' 'print("errorred", file=sys.stderr)\n' '# üñîçø∂é\n' 'raise Exception("message")'}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'ok\n'}], 'source': "print('ok')"}], 'metadata': {'kernelspec': {'display_name': 'Python 3 (ipykernel)', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.10.9'}, 'widgets': {'application/vnd.jupyter.widget-state+json': {'state': {}, 'version_major': 2, 'version_minor': 0}}}, 'nbformat': 4, 'nbformat_minor': 4} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff80393e20> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709559880.4021592 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 56, in from prompt_toolkit.key_binding.defaults import load_key_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/defaults.py", line 10, in from prompt_toolkit.key_binding.bindings.basic import load_basic_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/basic.py", line 17, in from .named_commands import get_by_name File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/named_commands.py", line 15, in from prompt_toolkit.layout.controls import BufferControl File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/__init__.py", line 49, in from .containers import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/containers.py", line 34, in from .controls import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/controls.py", line 26, in from prompt_toolkit.lexers import Lexer, SimpleLexer File "", line 1354, in _find_and_load File "", line 1316, in _find_and_load_unlocked File "", line 1256, in _find_spec File "", line 1524, in find_spec File "", line 1498, in _get_spec File "", line 1612, in find_spec File "", line 126, in _path_join KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel c902ea8e-efdb-42ec-9b08-c9f20f49f46b: Kernel didn't respond in 60 seconds _____________ test_run_all_notebooks[Skip Exceptions.ipynb-opts9] ______________ input_name = 'Skip Exceptions.ipynb' opts = {'allow_errors': True, 'kernel_name': 'python'} @pytest.mark.parametrize( ["input_name", "opts"], [ ("Other Comms.ipynb", {"kernel_name": "python"}), ("Clear Output.ipynb", {"kernel_name": "python"}), ("Empty Cell.ipynb", {"kernel_name": "python"}), ("Factorials.ipynb", {"kernel_name": "python"}), ("HelloWorld.ipynb", {"kernel_name": "python"}), ("Inline Image.ipynb", {"kernel_name": "python"}), ( "Interrupt.ipynb", { "kernel_name": "python", "timeout": 3, "interrupt_on_timeout": True, "allow_errors": True, }, ), ("JupyterWidgets.ipynb", {"kernel_name": "python"}), ("Skip Exceptions with Cell Tags.ipynb", {"kernel_name": "python"}), ("Skip Exceptions.ipynb", {"kernel_name": "python", "allow_errors": True}), ("Skip Execution with Cell Tag.ipynb", {"kernel_name": "python"}), ("SVG.ipynb", {"kernel_name": "python"}), ("Unicode.ipynb", {"kernel_name": "python"}), ("UnicodePy3.ipynb", {"kernel_name": "python"}), ("update-display-id.ipynb", {"kernel_name": "python"}), ("Check History in Memory.ipynb", {"kernel_name": "python"}), ], ) def test_run_all_notebooks(input_name, opts): """Runs a series of test notebooks and compares them to their actual output""" input_file = os.path.join(current_dir, "files", input_name) > input_nb, output_nb = run_notebook(input_file, opts, notebook_resources()) input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Skip Exceptions.ipynb' input_name = 'Skip Exceptions.ipynb' opts = {'allow_errors': True, 'kernel_name': 'python'} tests/test_client.py:351: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': "print('ok')"} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': '# üñîçø∂é\nraise Exception("message")'}, {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': "print('ok')"}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Skip Exceptions.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Skip Exceptions.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'ename': 'Exception', 'evalue': 'message', 'output_type': 'error', 'traceback': ['\x1b[1;31m---------------------------------------------------------------------------\x1b[0m', '\x1b[1;31mException\x1b[0m ' 'Traceback (most recent call last)', '\x1b[1;32m\x1b[0m ' 'in ' '\x1b[0;36m\x1b[1;34m\x1b[0m\n' '\x1b[0;32m 1\x1b[0m \x1b[1;31m# ' 'üñîçø∂é\x1b[0m\x1b[1;33m\x1b[0m\x1b[1;33m\x1b[0m\x1b[0m\n' '\x1b[1;32m----> 2\x1b[1;33m ' '\x1b[1;32mraise\x1b[0m ' '\x1b[0mException\x1b[0m\x1b[1;33m(\x1b[0m\x1b[1;34m"message"\x1b[0m\x1b[1;33m)\x1b[0m\x1b[1;33m\x1b[0m\x1b[0m\n' '\x1b[0m', '\x1b[1;31mException\x1b[0m: message']}], 'source': '# üñîçø∂é\nraise Exception("message")'}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'ok\n'}], 'source': "print('ok')"}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} opts = {'allow_errors': True, 'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff80393ce0> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709559973.7134495 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 15, in from IPython.core.interactiveshell import DummyMod, InteractiveShell File "/usr/lib/python3.12/site-packages/IPython/core/interactiveshell.py", line 71, in from IPython.core.extensions import ExtensionManager File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 929, in _load_unlocked File "", line 990, in exec_module File "", line 1123, in get_code File "", line 752, in _compile_bytecode KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel fcbd31fd-afd4-4edf-ae64-2d88e4e37447: Kernel didn't respond in 60 seconds ______ test_run_all_notebooks[Skip Execution with Cell Tag.ipynb-opts10] _______ input_name = 'Skip Execution with Cell Tag.ipynb' opts = {'kernel_name': 'python'} @pytest.mark.parametrize( ["input_name", "opts"], [ ("Other Comms.ipynb", {"kernel_name": "python"}), ("Clear Output.ipynb", {"kernel_name": "python"}), ("Empty Cell.ipynb", {"kernel_name": "python"}), ("Factorials.ipynb", {"kernel_name": "python"}), ("HelloWorld.ipynb", {"kernel_name": "python"}), ("Inline Image.ipynb", {"kernel_name": "python"}), ( "Interrupt.ipynb", { "kernel_name": "python", "timeout": 3, "interrupt_on_timeout": True, "allow_errors": True, }, ), ("JupyterWidgets.ipynb", {"kernel_name": "python"}), ("Skip Exceptions with Cell Tags.ipynb", {"kernel_name": "python"}), ("Skip Exceptions.ipynb", {"kernel_name": "python", "allow_errors": True}), ("Skip Execution with Cell Tag.ipynb", {"kernel_name": "python"}), ("SVG.ipynb", {"kernel_name": "python"}), ("Unicode.ipynb", {"kernel_name": "python"}), ("UnicodePy3.ipynb", {"kernel_name": "python"}), ("update-display-id.ipynb", {"kernel_name": "python"}), ("Check History in Memory.ipynb", {"kernel_name": "python"}), ], ) def test_run_all_notebooks(input_name, opts): """Runs a series of test notebooks and compares them to their actual output""" input_file = os.path.join(current_dir, "files", input_name) > input_nb, output_nb = run_notebook(input_file, opts, notebook_resources()) input_file = ('/builddir/build/BUILD/nbclient-0.9.0/tests/files/Skip Execution with Cell ' 'Tag.ipynb') input_name = 'Skip Execution with Cell Tag.ipynb' opts = {'kernel_name': 'python'} tests/test_client.py:351: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "print('ok')"} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'tags': ['skip-execution']}, 'outputs': [], 'source': 'print("a long running cell")'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "print('ok')"}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 1} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Skip Execution with Cell Tag.ipynb' mode='r' encoding='UTF-8'> filename = ('/builddir/build/BUILD/nbclient-0.9.0/tests/files/Skip Execution with Cell ' 'Tag.ipynb') input_nb = {'cells': [{'cell_type': 'code', 'execution_count': None, 'metadata': {'tags': ['skip-execution']}, 'outputs': [], 'source': 'print("a long running cell")'}, {'cell_type': 'code', 'execution_count': 1, 'metadata': {}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'ok\n'}], 'source': "print('ok')"}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 1} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff80393100> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709560066.2679303 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 14, in from IPython.core.magic import Magics, magics_class, line_magic File "/usr/lib/python3.12/site-packages/IPython/core/magic.py", line 307, in class MagicsManager(Configurable): File "/usr/lib/python3.12/site-packages/traitlets/traitlets.py", line 989, in __init__ cls.setup_class(classdict) File "/usr/lib/python3.12/site-packages/traitlets/traitlets.py", line 1025, in setup_class for name in dir(cls): ^^^^^^^^ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel a2a16c5b-043a-48c5-a6f4-1e6b272e8c0e: Kernel didn't respond in 60 seconds ___________________ test_run_all_notebooks[SVG.ipynb-opts11] ___________________ input_name = 'SVG.ipynb', opts = {'kernel_name': 'python'} @pytest.mark.parametrize( ["input_name", "opts"], [ ("Other Comms.ipynb", {"kernel_name": "python"}), ("Clear Output.ipynb", {"kernel_name": "python"}), ("Empty Cell.ipynb", {"kernel_name": "python"}), ("Factorials.ipynb", {"kernel_name": "python"}), ("HelloWorld.ipynb", {"kernel_name": "python"}), ("Inline Image.ipynb", {"kernel_name": "python"}), ( "Interrupt.ipynb", { "kernel_name": "python", "timeout": 3, "interrupt_on_timeout": True, "allow_errors": True, }, ), ("JupyterWidgets.ipynb", {"kernel_name": "python"}), ("Skip Exceptions with Cell Tags.ipynb", {"kernel_name": "python"}), ("Skip Exceptions.ipynb", {"kernel_name": "python", "allow_errors": True}), ("Skip Execution with Cell Tag.ipynb", {"kernel_name": "python"}), ("SVG.ipynb", {"kernel_name": "python"}), ("Unicode.ipynb", {"kernel_name": "python"}), ("UnicodePy3.ipynb", {"kernel_name": "python"}), ("update-display-id.ipynb", {"kernel_name": "python"}), ("Check History in Memory.ipynb", {"kernel_name": "python"}), ], ) def test_run_all_notebooks(input_name, opts): """Runs a series of test notebooks and compares them to their actual output""" input_file = os.path.join(current_dir, "files", input_name) > input_nb, output_nb = run_notebook(input_file, opts, notebook_resources()) input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/SVG.ipynb' input_name = 'SVG.ipynb' opts = {'kernel_name': 'python'} tests/test_client.py:351: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': "SVG(data='''\n" '\n' ' \n' "''')"} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'from IPython.display import SVG'}, {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': "SVG(data='''\n" '\n' ' \n' "''')"}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/SVG.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/SVG.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'from IPython.display import SVG'}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {'collapsed': False}, 'outputs': [{'data': {'image/svg+xml': '\n' ' \n' '', 'text/plain': ''}, 'execution_count': 2, 'metadata': {}, 'output_type': 'execute_result'}], 'source': "SVG(data='''\n" '\n' ' \n' "''')"}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff82e48040> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709560157.1048193 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 3, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/base.py", line 11, in from prompt_toolkit.formatted_text import AnyFormattedText, StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/__init__.py", line 15, in from .ansi import ANSI File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/ansi.py", line 6, in from prompt_toolkit.output.vt100 import BG_ANSI_COLORS, FG_ANSI_COLORS File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/__init__.py", line 3, in from .base import DummyOutput, Output File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/base.py", line 9, in from prompt_toolkit.cursor_shapes import CursorShape File "/usr/lib/python3.12/site-packages/prompt_toolkit/cursor_shapes.py", line 8, in from prompt_toolkit.key_binding.vi_state import InputMode File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/__init__.py", line 3, in from .key_bindings import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/key_bindings.py", line 55, in from prompt_toolkit.keys import KEY_ALIASES, Keys File "/usr/lib/python3.12/site-packages/prompt_toolkit/keys.py", line 11, in class Keys(str, Enum): File "/usr/lib64/python3.12/enum.py", line 583, in __new__ enum_class = super().__new__(metacls, cls, bases, classdict, **kwds) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/enum.py", line 266, in __set_name__ enum_member = enum_class._new_member_(enum_class, *args) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ KeyboardInterrupt Error calling __set_name__ on '_proto_member' instance 'ControlF' in 'Keys' ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel b862af19-9e81-4db5-be26-993078875763: Kernel didn't respond in 60 seconds _________________ test_run_all_notebooks[Unicode.ipynb-opts12] _________________ input_name = 'Unicode.ipynb', opts = {'kernel_name': 'python'} @pytest.mark.parametrize( ["input_name", "opts"], [ ("Other Comms.ipynb", {"kernel_name": "python"}), ("Clear Output.ipynb", {"kernel_name": "python"}), ("Empty Cell.ipynb", {"kernel_name": "python"}), ("Factorials.ipynb", {"kernel_name": "python"}), ("HelloWorld.ipynb", {"kernel_name": "python"}), ("Inline Image.ipynb", {"kernel_name": "python"}), ( "Interrupt.ipynb", { "kernel_name": "python", "timeout": 3, "interrupt_on_timeout": True, "allow_errors": True, }, ), ("JupyterWidgets.ipynb", {"kernel_name": "python"}), ("Skip Exceptions with Cell Tags.ipynb", {"kernel_name": "python"}), ("Skip Exceptions.ipynb", {"kernel_name": "python", "allow_errors": True}), ("Skip Execution with Cell Tag.ipynb", {"kernel_name": "python"}), ("SVG.ipynb", {"kernel_name": "python"}), ("Unicode.ipynb", {"kernel_name": "python"}), ("UnicodePy3.ipynb", {"kernel_name": "python"}), ("update-display-id.ipynb", {"kernel_name": "python"}), ("Check History in Memory.ipynb", {"kernel_name": "python"}), ], ) def test_run_all_notebooks(input_name, opts): """Runs a series of test notebooks and compares them to their actual output""" input_file = os.path.join(current_dir, "files", input_name) > input_nb, output_nb = run_notebook(input_file, opts, notebook_resources()) input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Unicode.ipynb' input_name = 'Unicode.ipynb' opts = {'kernel_name': 'python'} tests/test_client.py:351: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': "print('☃')"} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': "print('☃')"}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Unicode.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Unicode.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': '☃\n'}], 'source': "print('☃')"}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff82e48d60> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709560247.3801131 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 929, in _load_unlocked File "", line 990, in exec_module File "", line 1123, in get_code File "", line 752, in _compile_bytecode KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel d36afaac-e6a7-41f2-850a-88b022124671: Kernel didn't respond in 60 seconds _______________ test_run_all_notebooks[UnicodePy3.ipynb-opts13] ________________ input_name = 'UnicodePy3.ipynb', opts = {'kernel_name': 'python'} @pytest.mark.parametrize( ["input_name", "opts"], [ ("Other Comms.ipynb", {"kernel_name": "python"}), ("Clear Output.ipynb", {"kernel_name": "python"}), ("Empty Cell.ipynb", {"kernel_name": "python"}), ("Factorials.ipynb", {"kernel_name": "python"}), ("HelloWorld.ipynb", {"kernel_name": "python"}), ("Inline Image.ipynb", {"kernel_name": "python"}), ( "Interrupt.ipynb", { "kernel_name": "python", "timeout": 3, "interrupt_on_timeout": True, "allow_errors": True, }, ), ("JupyterWidgets.ipynb", {"kernel_name": "python"}), ("Skip Exceptions with Cell Tags.ipynb", {"kernel_name": "python"}), ("Skip Exceptions.ipynb", {"kernel_name": "python", "allow_errors": True}), ("Skip Execution with Cell Tag.ipynb", {"kernel_name": "python"}), ("SVG.ipynb", {"kernel_name": "python"}), ("Unicode.ipynb", {"kernel_name": "python"}), ("UnicodePy3.ipynb", {"kernel_name": "python"}), ("update-display-id.ipynb", {"kernel_name": "python"}), ("Check History in Memory.ipynb", {"kernel_name": "python"}), ], ) def test_run_all_notebooks(input_name, opts): """Runs a series of test notebooks and compares them to their actual output""" input_file = os.path.join(current_dir, "files", input_name) > input_nb, output_nb = run_notebook(input_file, opts, notebook_resources()) input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/UnicodePy3.ipynb' input_name = 'UnicodePy3.ipynb' opts = {'kernel_name': 'python'} tests/test_client.py:351: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': "print('☃')"} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': "print('☃')"}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}}, 'nbformat': 4, 'nbformat_minor': 0} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/UnicodePy3.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/UnicodePy3.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': '☃\n'}], 'source': "print('☃')"}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}}, 'nbformat': 4, 'nbformat_minor': 0} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff82e4a020> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709560339.8139727 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 3, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/base.py", line 11, in from prompt_toolkit.formatted_text import AnyFormattedText, StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/__init__.py", line 15, in from .ansi import ANSI File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/ansi.py", line 9, in from .base import StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/base.py", line 5, in from prompt_toolkit.mouse_events import MouseEvent File "/usr/lib/python3.12/site-packages/prompt_toolkit/mouse_events.py", line 27, in class MouseEventType(Enum): File "/usr/lib64/python3.12/enum.py", line 583, in __new__ enum_class = super().__new__(metacls, cls, bases, classdict, **kwds) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/enum.py", line 249, in __set_name__ def __set_name__(self, enum_class, member_name): KeyboardInterrupt Error calling __set_name__ on '_proto_member' instance 'MOUSE_DOWN' in 'MouseEventType' ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 0c39b5b1-ca35-4555-9433-6e0fdd0804f0: Kernel didn't respond in 60 seconds ____________ test_run_all_notebooks[update-display-id.ipynb-opts14] ____________ input_name = 'update-display-id.ipynb', opts = {'kernel_name': 'python'} @pytest.mark.parametrize( ["input_name", "opts"], [ ("Other Comms.ipynb", {"kernel_name": "python"}), ("Clear Output.ipynb", {"kernel_name": "python"}), ("Empty Cell.ipynb", {"kernel_name": "python"}), ("Factorials.ipynb", {"kernel_name": "python"}), ("HelloWorld.ipynb", {"kernel_name": "python"}), ("Inline Image.ipynb", {"kernel_name": "python"}), ( "Interrupt.ipynb", { "kernel_name": "python", "timeout": 3, "interrupt_on_timeout": True, "allow_errors": True, }, ), ("JupyterWidgets.ipynb", {"kernel_name": "python"}), ("Skip Exceptions with Cell Tags.ipynb", {"kernel_name": "python"}), ("Skip Exceptions.ipynb", {"kernel_name": "python", "allow_errors": True}), ("Skip Execution with Cell Tag.ipynb", {"kernel_name": "python"}), ("SVG.ipynb", {"kernel_name": "python"}), ("Unicode.ipynb", {"kernel_name": "python"}), ("UnicodePy3.ipynb", {"kernel_name": "python"}), ("update-display-id.ipynb", {"kernel_name": "python"}), ("Check History in Memory.ipynb", {"kernel_name": "python"}), ], ) def test_run_all_notebooks(input_name, opts): """Runs a series of test notebooks and compares them to their actual output""" input_file = os.path.join(current_dir, "files", input_name) > input_nb, output_nb = run_notebook(input_file, opts, notebook_resources()) input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/update-display-id.ipynb' input_name = 'update-display-id.ipynb' opts = {'kernel_name': 'python'} tests/test_client.py:351: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'collapsed': True}, 'outputs': [], 'source': "display_with_id(10, 'result', update=True)"} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': True}, 'outputs': [], 'source': 'ip = get_ipython()\n' '\n' 'from IPython.display import display\n' '\n' 'def display_with_id(obj, display_id, update=False, ' 'execute_result=False):\n' ' iopub = ip.kernel.iopub_socket\n' ' session = get_ipython().kernel.session\n' ' data, md = ip.display_formatter.format(obj)\n' " transient = {'display_id': str(display_id)}\n" " content = {'data': data, 'metadata': md, " "'transient': transient}\n" ' if execute_result:\n' " msg_type = 'execute_result'\n" " content['execution_count'] = ip.execution_count\n" ' else:\n' " msg_type = 'update_display_data' if update else " "'display_data'\n" ' session.send(iopub, msg_type, content, ' 'parent=ip.parent_header)\n'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "display('above')\n" "display_with_id(1, 'here')\n" "display('below')"}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "display_with_id(2, 'here')\n" "display_with_id(3, 'there')\n" "display_with_id(4, 'here')"}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "display_with_id(5, 'there')\n" "display_with_id(6, 'there', update=True)"}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "display_with_id(7, 'here')\n" "display_with_id(8, 'here', update=True)\n" "display_with_id(9, 'result', execute_result=True)"}, {'cell_type': 'code', 'metadata': {'collapsed': True}, 'outputs': [], 'source': "display_with_id(10, 'result', update=True)"}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 2} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/update-display-id.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/update-display-id.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': True}, 'outputs': [], 'source': 'ip = get_ipython()\n' '\n' 'from IPython.display import display\n' '\n' 'def display_with_id(obj, display_id, update=False, ' 'execute_result=False):\n' ' iopub = ip.kernel.iopub_socket\n' ' session = get_ipython().kernel.session\n' ' data, md = ip.display_formatter.format(obj)\n' " transient = {'display_id': str(display_id)}\n" " content = {'data': data, 'metadata': md, " "'transient': transient}\n" ' if execute_result:\n' " msg_type = 'execute_result'\n" " content['execution_count'] = ip.execution_count\n" ' else:\n' " msg_type = 'update_display_data' if update else " "'display_data'\n" ' session.send(iopub, msg_type, content, ' 'parent=ip.parent_header)\n'}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {}, 'outputs': [{'data': {'text/plain': "'above'"}, 'metadata': {}, 'output_type': 'display_data'}, {'data': {'text/plain': '8'}, 'metadata': {}, 'output_type': 'display_data'}, {'data': {'text/plain': "'below'"}, 'metadata': {}, 'output_type': 'display_data'}], 'source': "display('above')\n" "display_with_id(1, 'here')\n" "display('below')"}, {'cell_type': 'code', 'execution_count': 3, 'metadata': {}, 'outputs': [{'data': {'text/plain': '8'}, 'metadata': {}, 'output_type': 'display_data'}, {'data': {'text/plain': '6'}, 'metadata': {}, 'output_type': 'display_data'}, {'data': {'text/plain': '8'}, 'metadata': {}, 'output_type': 'display_data'}], 'source': "display_with_id(2, 'here')\n" "display_with_id(3, 'there')\n" "display_with_id(4, 'here')"}, {'cell_type': 'code', 'execution_count': 4, 'metadata': {}, 'outputs': [{'data': {'text/plain': '6'}, 'metadata': {}, 'output_type': 'display_data'}], 'source': "display_with_id(5, 'there')\n" "display_with_id(6, 'there', update=True)"}, {'cell_type': 'code', 'execution_count': 5, 'metadata': {}, 'outputs': [{'data': {'text/plain': '8'}, 'metadata': {}, 'output_type': 'display_data'}, {'data': {'text/plain': '10'}, 'execution_count': 5, 'metadata': {}, 'output_type': 'execute_result'}], 'source': "display_with_id(7, 'here')\n" "display_with_id(8, 'here', update=True)\n" "display_with_id(9, 'result', execute_result=True)"}, {'cell_type': 'code', 'execution_count': 6, 'metadata': {'collapsed': True}, 'outputs': [], 'source': "display_with_id(10, 'result', update=True)"}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 2} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff82e49da0> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709560431.2348838 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 3, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/base.py", line 11, in from prompt_toolkit.formatted_text import AnyFormattedText, StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/__init__.py", line 15, in from .ansi import ANSI File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/ansi.py", line 6, in from prompt_toolkit.output.vt100 import BG_ANSI_COLORS, FG_ANSI_COLORS File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/__init__.py", line 3, in from .base import DummyOutput, Output File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/base.py", line 9, in from prompt_toolkit.cursor_shapes import CursorShape File "/usr/lib/python3.12/site-packages/prompt_toolkit/cursor_shapes.py", line 8, in from prompt_toolkit.key_binding.vi_state import InputMode File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/__init__.py", line 10, in from .key_processor import KeyPress, KeyPressEvent File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/key_processor.py", line 19, in from prompt_toolkit.utils import Event File "/usr/lib/python3.12/site-packages/prompt_toolkit/utils.py", line 18, in from wcwidth import wcwidth File "/usr/lib/python3.12/site-packages/wcwidth/__init__.py", line 12, in from .wcwidth import ZERO_WIDTH # noqa ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/wcwidth/wcwidth.py", line 72, in from .table_zero import ZERO_WIDTH File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 929, in _load_unlocked File "", line 990, in exec_module File "", line 1123, in get_code File "", line 752, in _compile_bytecode KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 61f1ff9a-fcb0-49ae-986f-26d19d07ce92: Kernel didn't respond in 60 seconds _________ test_run_all_notebooks[Check History in Memory.ipynb-opts15] _________ input_name = 'Check History in Memory.ipynb', opts = {'kernel_name': 'python'} @pytest.mark.parametrize( ["input_name", "opts"], [ ("Other Comms.ipynb", {"kernel_name": "python"}), ("Clear Output.ipynb", {"kernel_name": "python"}), ("Empty Cell.ipynb", {"kernel_name": "python"}), ("Factorials.ipynb", {"kernel_name": "python"}), ("HelloWorld.ipynb", {"kernel_name": "python"}), ("Inline Image.ipynb", {"kernel_name": "python"}), ( "Interrupt.ipynb", { "kernel_name": "python", "timeout": 3, "interrupt_on_timeout": True, "allow_errors": True, }, ), ("JupyterWidgets.ipynb", {"kernel_name": "python"}), ("Skip Exceptions with Cell Tags.ipynb", {"kernel_name": "python"}), ("Skip Exceptions.ipynb", {"kernel_name": "python", "allow_errors": True}), ("Skip Execution with Cell Tag.ipynb", {"kernel_name": "python"}), ("SVG.ipynb", {"kernel_name": "python"}), ("Unicode.ipynb", {"kernel_name": "python"}), ("UnicodePy3.ipynb", {"kernel_name": "python"}), ("update-display-id.ipynb", {"kernel_name": "python"}), ("Check History in Memory.ipynb", {"kernel_name": "python"}), ], ) def test_run_all_notebooks(input_name, opts): """Runs a series of test notebooks and compares them to their actual output""" input_file = os.path.join(current_dir, "files", input_name) > input_nb, output_nb = run_notebook(input_file, opts, notebook_resources()) input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Check History in Memory.ipynb' input_name = 'Check History in Memory.ipynb' opts = {'kernel_name': 'python'} tests/test_client.py:351: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'scrolled': True}, 'outputs': [], 'source': 'ip = get_ipython()\n' "assert ip.history_manager.hist_file == ':memory:'"} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 'from IPython import get_ipython'}, {'cell_type': 'code', 'metadata': {'scrolled': True}, 'outputs': [], 'source': 'ip = get_ipython()\n' "assert ip.history_manager.hist_file == ':memory:'"}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 2} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Check History in Memory.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Check History in Memory.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {}, 'outputs': [], 'source': 'from IPython import get_ipython'}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {'scrolled': True}, 'outputs': [], 'source': 'ip = get_ipython()\n' "assert ip.history_manager.hist_file == ':memory:'"}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 2} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff82e4aac0> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709560522.007474 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 48, in from .debugger import TerminalPdb, Pdb File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 929, in _load_unlocked File "", line 990, in exec_module File "", line 1086, in get_code File "", line 1185, in get_data KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 29043fe6-3a3d-4211-8570-cfe38d2b5fbd: Kernel didn't respond in 60 seconds _________________________ test_many_parallel_notebooks _________________________ capfd = <_pytest.capture.CaptureFixture object at 0xffffff8038ade0> @flaky @pytest.mark.skipif(os.name == "nt", reason="warns about event loop on Windows") def test_many_parallel_notebooks(capfd): """Ensure that when many IPython kernels are run in parallel, nothing awful happens.  Specifically, many IPython kernels when run simultaneously would encounter errors due to using the same SQLite history database. """ opts = {"kernel_name": "python", "timeout": 5} input_name = "HelloWorld.ipynb" input_file = os.path.join(current_dir, "files", input_name) res = NBClientTestsBase().build_resources() res["metadata"]["path"] = os.path.join(current_dir, "files")  with warnings.catch_warnings(): # suppress warning from jupyter_client's deprecated cleanup() warnings.simplefilter(action="ignore", category=FutureWarning)  # run once, to trigger creating the original context > run_notebook(input_file, opts, res) capfd = <_pytest.capture.CaptureFixture object at 0xffffff8038ade0> input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' input_name = 'HelloWorld.ipynb' opts = {'kernel_name': 'python', 'timeout': 5} res = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} tests/test_client.py:400: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'print("Hello World")'} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'Hello World\n'}], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}, 'timeout': 5} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff82e4afc0> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709560693.632039 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 3, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/base.py", line 11, in from prompt_toolkit.formatted_text import AnyFormattedText, StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/__init__.py", line 25, in from .html import HTML File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/html.py", line 3, in import xml.dom.minidom as minidom File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 929, in _load_unlocked File "", line 990, in exec_module File "", line 1123, in get_code File "", line 752, in _compile_bytecode KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 06886a40-58fa-4fc6-a2b5-5d0023c4904a: Kernel didn't respond in 60 seconds ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 65717069-fce0-46bb-baee-f99d2ca065ba: Kernel didn't respond in 60 seconds ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 4db2dc94-7d31-481f-85d6-a63ae4f1a435: Kernel didn't respond in 60 seconds ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 48, in from .debugger import TerminalPdb, Pdb File "/usr/lib/python3.12/site-packages/IPython/terminal/debugger.py", line 6, in from IPython.core.completer import IPCompleter File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 929, in _load_unlocked File "", line 990, in exec_module File "", line 1086, in get_code File "", line 1186, in get_data KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel d4cebaca-ea0d-4925-bd2d-b158b102d460: Kernel didn't respond in 60 seconds ________________________ test_async_parallel_notebooks _________________________ capfd = <_pytest.capture.CaptureFixture object at 0xffffff803897f0> tmpdir = local('/tmp/pytest-of-mockbuild/pytest-0/test_async_parallel_notebooks1') @flaky def test_async_parallel_notebooks(capfd, tmpdir): """Two notebooks should be able to be run simultaneously without problems.  The two notebooks spawned here use the filesystem to check that the other notebook wrote to the filesystem."""  opts = {"kernel_name": "python"} input_name = "Parallel Execute {label}.ipynb" input_file = os.path.join(current_dir, "files", input_name) res = notebook_resources()  with modified_env({"NBEXECUTE_TEST_PARALLEL_TMPDIR": str(tmpdir)}):  async def run_tasks(): tasks = [ async_run_notebook(input_file.format(label=label), opts, res) for label in ("A", "B") ] await asyncio.gather(*tasks)  > asyncio.run(run_tasks()) capfd = <_pytest.capture.CaptureFixture object at 0xffffff803897f0> input_file = ('/builddir/build/BUILD/nbclient-0.9.0/tests/files/Parallel Execute ' '{label}.ipynb') input_name = 'Parallel Execute {label}.ipynb' opts = {'kernel_name': 'python'} res = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} run_tasks = .run_tasks at 0xffffff82e4b600> tmpdir = local('/tmp/pytest-of-mockbuild/pytest-0/test_async_parallel_notebooks1') tests/test_client.py:430: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib64/python3.12/asyncio/runners.py:194: in run return runner.run(main) debug = None loop_factory = None main = .run_tasks at 0xffffff82e72350> runner = /usr/lib64/python3.12/asyncio/runners.py:118: in run return self._loop.run_until_complete(task) context = <_contextvars.Context object at 0xffffff6bec3280> coro = .run_tasks at 0xffffff82e72350> self = sigint_handler = functools.partial(>, main_task=.run_tasks() done, defined at /builddir/build/BUILD/nbclient-0.9.0/tests/test_client.py:423> exception=RuntimeError("Kernel didn't respond in 60 seconds")>) task = .run_tasks() done, defined at /builddir/build/BUILD/nbclient-0.9.0/tests/test_client.py:423> exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = .run_tasks() done, defined at /builddir/build/BUILD/nbclient-0.9.0/tests/test_client.py:423> exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = False self = <_UnixSelectorEventLoop running=False closed=True debug=False> tests/test_client.py:428: in run_tasks await asyncio.gather(*tasks) input_file = ('/builddir/build/BUILD/nbclient-0.9.0/tests/files/Parallel Execute ' '{label}.ipynb') opts = {'kernel_name': 'python'} res = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} tasks = [, ] tests/test_client.py:169: in async_run_notebook output_nb = await executor.async_execute() cell = {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 'start = time.time()\n' 'timeout = 5\n' 'end = start + timeout\n' 'target_file = os.path.join(directory, ' "'test_file_{}.txt'.format(other_notebook))\n" 'while time.time() < end:\n' ' time.sleep(0.1)\n' ' if os.path.exists(target_file):\n' " with open(target_file, 'r') as f:\n" ' text = f.read()\n' " if text == 'Hello from {}'.format(other_notebook):\n" ' break\n' 'else:\n' ' assert False, "Timed out –\xa0didn\'t get a message from ' '{}".format(other_notebook)'} cleaned_input_nb = {'cells': [{'cell_type': 'markdown', 'metadata': {}, 'outputs': [], 'source': '# Ensure notebooks can execute in parallel\n' '\n' 'This notebook uses a file system based "lock" to assert ' 'that two instances of the notebook kernel will run in ' 'parallel. Each instance writes to a file in a temporary ' 'directory, and then tries to read the other file from\n' 'the temporary directory, so that running them in ' 'sequence will fail, but running them in parallel will ' 'succeed.\n' '\n' 'Two notebooks are launched, each which sets the ' '`this_notebook` variable. One notebook is set to ' "`this_notebook = 'A'` and the other `this_notebook = " "'B'`."}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 'import os\n' 'import os.path\n' 'import tempfile\n' 'import time'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': '# the variable this_notebook is injectected in a cell ' 'above by the test framework.\n' "this_notebook = 'B'\n" "other_notebook = 'A'\n" 'directory = ' "os.environ['NBEXECUTE_TEST_PARALLEL_TMPDIR']\n" 'with open(os.path.join(directory, ' "'test_file_{}.txt'.format(this_notebook)), 'w') as f:\n" " f.write('Hello from {}'.format(this_notebook))"}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 'start = time.time()\n' 'timeout = 5\n' 'end = start + timeout\n' 'target_file = os.path.join(directory, ' "'test_file_{}.txt'.format(other_notebook))\n" 'while time.time() < end:\n' ' time.sleep(0.1)\n' ' if os.path.exists(target_file):\n' " with open(target_file, 'r') as f:\n" ' text = f.read()\n' " if text == 'Hello from " "{}'.format(other_notebook):\n" ' break\n' 'else:\n' ' assert False, "Timed out –\xa0didn\'t get a message ' 'from {}".format(other_notebook)'}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.6.7'}}, 'nbformat': 4, 'nbformat_minor': 2} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Parallel Execute B.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Parallel Execute B.ipynb' input_nb = {'cells': [{'cell_type': 'markdown', 'metadata': {}, 'source': '# Ensure notebooks can execute in parallel\n' '\n' 'This notebook uses a file system based "lock" to assert ' 'that two instances of the notebook kernel will run in ' 'parallel. Each instance writes to a file in a temporary ' 'directory, and then tries to read the other file from\n' 'the temporary directory, so that running them in ' 'sequence will fail, but running them in parallel will ' 'succeed.\n' '\n' 'Two notebooks are launched, each which sets the ' '`this_notebook` variable. One notebook is set to ' "`this_notebook = 'A'` and the other `this_notebook = " "'B'`."}, {'cell_type': 'code', 'execution_count': None, 'metadata': {}, 'outputs': [], 'source': 'import os\n' 'import os.path\n' 'import tempfile\n' 'import time'}, {'cell_type': 'code', 'execution_count': None, 'metadata': {}, 'outputs': [], 'source': '# the variable this_notebook is injectected in a cell ' 'above by the test framework.\n' "this_notebook = 'B'\n" "other_notebook = 'A'\n" 'directory = ' "os.environ['NBEXECUTE_TEST_PARALLEL_TMPDIR']\n" 'with open(os.path.join(directory, ' "'test_file_{}.txt'.format(this_notebook)), 'w') as f:\n" " f.write('Hello from {}'.format(this_notebook))"}, {'cell_type': 'code', 'execution_count': None, 'metadata': {}, 'outputs': [], 'source': 'start = time.time()\n' 'timeout = 5\n' 'end = start + timeout\n' 'target_file = os.path.join(directory, ' "'test_file_{}.txt'.format(other_notebook))\n" 'while time.time() < end:\n' ' time.sleep(0.1)\n' ' if os.path.exists(target_file):\n' " with open(target_file, 'r') as f:\n" ' text = f.read()\n' " if text == 'Hello from " "{}'.format(other_notebook):\n" ' break\n' 'else:\n' ' assert False, "Timed out –\xa0didn\'t get a message ' 'from {}".format(other_notebook)'}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.6.7'}}, 'nbformat': 4, 'nbformat_minor': 2} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=True debug=False> on_signal = .on_signal at 0xffffff82e58040> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709560872.6353488 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Exception ignored in: .cb at 0xffffffb6dffc40> Traceback (most recent call last): File "", line 446, in cb KeyboardInterrupt: Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 27, in from .shortcuts import PromptSession, print_formatted_text, prompt File "/usr/lib/python3.12/site-packages/prompt_toolkit/shortcuts/__init__.py", line 13, in from .prompt import ( File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 929, in _load_unlocked File "", line 990, in exec_module File "", line 1080, in get_code File "", line 1203, in path_stats File "", line 147, in _path_stat KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 4faaacfc-556a-4a80-ad87-cc1a8593a648: Kernel didn't respond in 60 seconds ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 460d6d73-8384-430d-99e2-b6bb671652ff: Kernel didn't respond in 60 seconds ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell Traceback (most recent call last): File "", line 198, in _run_module_as_main File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from ipykernel import kernelapp as app from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from .application import Application from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 56, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from prompt_toolkit.key_binding.defaults import load_key_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/defaults.py", line 10, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.key_binding.bindings.basic import load_basic_bindings from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 27, in File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/basic.py", line 17, in from .shortcuts import PromptSession, print_formatted_text, prompt File "/usr/lib/python3.12/site-packages/prompt_toolkit/shortcuts/__init__.py", line 3, in from .named_commands import get_by_name from .dialogs import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/named_commands.py", line 15, in File "/usr/lib/python3.12/site-packages/prompt_toolkit/shortcuts/dialogs.py", line 22, in from prompt_toolkit.widgets import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/widgets/__init__.py", line 11, in from prompt_toolkit.layout.controls import BufferControl File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/__init__.py", line 49, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/widgets/base.py", line 923, in from .containers import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/containers.py", line 34, in class HorizontalLine: KeyboardInterrupt from .controls import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/controls.py", line 32, in from .processors import ( File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 929, in _load_unlocked File "", line 990, in exec_module File "", line 1086, in get_code File "", line 1186, in get_data KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 82ebf7cd-3b46-419f-9518-5d06bfa86d3a: Kernel didn't respond in 60 seconds ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 92a958ef-502c-4d27-b214-00a8b55c193b: Kernel didn't respond in 60 seconds ______________________ test_many_async_parallel_notebooks ______________________ capfd = <_pytest.capture.CaptureFixture object at 0xffffff82dfff80> @flaky def test_many_async_parallel_notebooks(capfd): """Ensure that when many IPython kernels are run in parallel, nothing awful happens.  Specifically, many IPython kernels when run simultaneously would encounter errors due to using the same SQLite history database. """ opts = {"kernel_name": "python", "timeout": 5} input_name = "HelloWorld.ipynb" input_file = os.path.join(current_dir, "files", input_name) res = NBClientTestsBase().build_resources() res["metadata"]["path"] = os.path.join(current_dir, "files")  # run once, to trigger creating the original context > run_notebook(input_file, opts, res) capfd = <_pytest.capture.CaptureFixture object at 0xffffff82dfff80> input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' input_name = 'HelloWorld.ipynb' opts = {'kernel_name': 'python', 'timeout': 5} res = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} tests/test_client.py:450: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'print("Hello World")'} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'Hello World\n'}], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}, 'timeout': 5} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff82e4b240> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709561051.001065 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 16, in from .fuzzy_completer import FuzzyCompleter, FuzzyWordCompleter File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/fuzzy_completer.py", line 210, in class _FuzzyMatch(NamedTuple): KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 6e8ee8d1-08e9-4616-ac83-cc65fe92b6ff: Kernel didn't respond in 60 seconds ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 48, in from .debugger import TerminalPdb, Pdb File "/usr/lib/python3.12/site-packages/IPython/terminal/debugger.py", line 6, in from IPython.core.completer import IPCompleter File "/usr/lib/python3.12/site-packages/IPython/core/completer.py", line 250, in import jedi File "/usr/lib/python3.12/site-packages/jedi/__init__.py", line 32, in from jedi.api import Script, Interpreter, set_debug_function, preload_module File "/usr/lib/python3.12/site-packages/jedi/api/__init__.py", line 21, in from jedi.api import classes File "/usr/lib/python3.12/site-packages/jedi/api/classes.py", line 24, in from jedi.inference.utils import unite File "/usr/lib/python3.12/site-packages/jedi/inference/__init__.py", line 70, in from jedi.inference import imports File "/usr/lib/python3.12/site-packages/jedi/inference/imports.py", line 23, in from jedi.inference import compiled File "/usr/lib/python3.12/site-packages/jedi/inference/compiled/__init__.py", line 4, in from jedi.inference.compiled.value import CompiledValue, CompiledName, \ File "/usr/lib/python3.12/site-packages/jedi/inference/compiled/value.py", line 13, in from jedi.inference.filters import AbstractFilter File "/usr/lib/python3.12/site-packages/jedi/inference/filters.py", line 20, in _definition_name_cache: MutableMapping[UsedNamesMapping, List[Name]] ~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/typing.py", line 374, in inner return _caches[func](*args, **kwds) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/typing.py", line 1430, in __getitem__ return self.copy_with(params) ^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/typing.py", line 1433, in copy_with return _GenericAlias(self.__origin__, params, ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/typing.py", line 1222, in __init__ self.__parameters__ = _collect_parameters(args) ^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/typing.py", line 258, in _collect_parameters def _collect_parameters(args): KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 5d939a84-6b67-41b6-b0e6-8cc32facf4cd: Kernel didn't respond in 60 seconds ____________________________ test_execution_timing _____________________________ def test_execution_timing(): """Compare the execution timing information stored in the cell with the actual time it took to run the cell. Also check for the cell timing string format.""" opts = {"kernel_name": "python"} input_name = "Sleep1s.ipynb" input_file = os.path.join(current_dir, "files", input_name) res = notebook_resources() > input_nb, output_nb = run_notebook(input_file, opts, res) input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Sleep1s.ipynb' input_name = 'Sleep1s.ipynb' opts = {'kernel_name': 'python'} res = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} tests/test_client.py:470: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "print(t1.strftime(time_format), end='')"} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 'import time\nimport datetime'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 't0 = datetime.datetime.utcnow()\n' 'time.sleep(1)\n' 't1 = datetime.datetime.utcnow()'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "time_format = '%Y-%m-%dT%H:%M:%S.%fZ'\n" "print(t0.strftime(time_format), end='')"}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "print(t1.strftime(time_format), end='')"}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.8.1'}}, 'nbformat': 4, 'nbformat_minor': 2} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Sleep1s.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Sleep1s.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': None, 'metadata': {}, 'outputs': [], 'source': 'import time\nimport datetime'}, {'cell_type': 'code', 'execution_count': None, 'metadata': {}, 'outputs': [], 'source': 't0 = datetime.datetime.utcnow()\n' 'time.sleep(1)\n' 't1 = datetime.datetime.utcnow()'}, {'cell_type': 'code', 'execution_count': None, 'metadata': {}, 'outputs': [], 'source': "time_format = '%Y-%m-%dT%H:%M:%S.%fZ'\n" "print(t0.strftime(time_format), end='')"}, {'cell_type': 'code', 'execution_count': None, 'metadata': {}, 'outputs': [], 'source': "print(t1.strftime(time_format), end='')"}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.8.1'}}, 'nbformat': 4, 'nbformat_minor': 2} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff82e4aca0> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709561135.7867944 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 48, in from .debugger import TerminalPdb, Pdb File "/usr/lib/python3.12/site-packages/IPython/terminal/debugger.py", line 6, in from IPython.core.completer import IPCompleter File "/usr/lib/python3.12/site-packages/IPython/core/completer.py", line 250, in import jedi File "/usr/lib/python3.12/site-packages/jedi/__init__.py", line 32, in from jedi.api import Script, Interpreter, set_debug_function, preload_module File "/usr/lib/python3.12/site-packages/jedi/api/__init__.py", line 13, in import parso File "/usr/lib/python3.12/site-packages/parso/__init__.py", line 41, in from parso.parser import ParserSyntaxError File "/usr/lib/python3.12/site-packages/parso/parser.py", line 29, in from parso.pgen2.generator import ReservedString File "/usr/lib/python3.12/site-packages/parso/pgen2/__init__.py", line 10, in from parso.pgen2.generator import generate_grammar File "/usr/lib/python3.12/site-packages/parso/pgen2/generator.py", line 32, in from parso.pgen2.grammar_parser import GrammarParser, NFAState File "/usr/lib/python3.12/site-packages/parso/pgen2/grammar_parser.py", line 9, in from parso.python.tokenize import tokenize File "/usr/lib/python3.12/site-packages/parso/python/tokenize.py", line 115, in fstring_string_single_line = _compile( ^^^^^^^^^ File "/usr/lib/python3.12/site-packages/parso/python/tokenize.py", line 102, in _compile return re.compile(expr, re.UNICODE) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/__init__.py", line 228, in compile return _compile(pattern, flags) ^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/__init__.py", line 307, in _compile p = _compiler.compile(pattern, flags) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/_compiler.py", line 747, in compile code = _code(p, flags) ^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/_compiler.py", line 580, in _code _compile(code, p.data, flags) File "/usr/lib64/python3.12/re/_compiler.py", line 119, in _compile _compile(code, av[2], flags) File "/usr/lib64/python3.12/re/_compiler.py", line 174, in _compile _compile(code, av, flags) File "/usr/lib64/python3.12/re/_compiler.py", line 37, in _compile def _compile(code, pattern, flags): KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 087543c2-8da8-402c-9d1e-dfb3ca0b13c2: Kernel didn't respond in 60 seconds ________________________ test_synchronous_setup_kernel _________________________ def test_synchronous_setup_kernel(): nb = nbformat.v4.new_notebook() executor = NotebookClient(nb) > with executor.setup_kernel(): executor = nb = {'cells': [], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 5} tests/test_client.py:495: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib64/python3.12/contextlib.py:137: in __enter__ return next(self.gen) self = nbclient/client.py:603: in setup_kernel self.start_new_kernel_client() cleanup_kc = True kwargs = {} self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib64/python3.12/asyncio/base_events.py:664: in run_until_complete return future.result() future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> new_task = True self = <_UnixSelectorEventLoop running=False closed=False debug=False> nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709561228.250068 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 56, in from prompt_toolkit.key_binding.defaults import load_key_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/defaults.py", line 10, in from prompt_toolkit.key_binding.bindings.basic import load_basic_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/basic.py", line 17, in from .named_commands import get_by_name File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/named_commands.py", line 15, in from prompt_toolkit.layout.controls import BufferControl File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/__init__.py", line 49, in from .containers import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/containers.py", line 34, in from .controls import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/controls.py", line 32, in from .processors import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/processors.py", line 27, in from .utils import explode_text_fragments File "", line 1354, in _find_and_load File "", line 1316, in _find_and_load_unlocked File "", line 1256, in _find_spec File "", line 1524, in find_spec File "", line 1498, in _get_spec File "", line 1629, in find_spec KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 26e27271-9323-464c-999e-579a364ccfd3: Kernel didn't respond in 60 seconds ____________________ test_startnewkernel_with_kernelmanager ____________________ def test_startnewkernel_with_kernelmanager(): nb = nbformat.v4.new_notebook() km = KernelManager() executor = NotebookClient(nb, km=km) executor.start_new_kernel() > kc = executor.start_new_kernel_client() executor = km = nb = {'cells': [], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 5} tests/test_client.py:507: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_client/utils.py:30: in wrapped raise e args = (,) coro = future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> kwargs = {'timeout': 60} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> nest_asyncio = /usr/lib/python3.12/site-packages/jupyter_client/utils.py:27: in wrapped return loop.run_until_complete(future) args = (,) coro = future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> kwargs = {'timeout': 60} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> nest_asyncio = /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709561312.4572277 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 39, in from .validation import ValidationError, Validator File "/usr/lib/python3.12/site-packages/prompt_toolkit/validation.py", line 46, in class Validator(metaclass=ABCMeta): File "", line 107, in __new__ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 91e9f491-a515-4ac9-9328-31a6623175bd: Kernel didn't respond in 60 seconds ________________________ TestExecute.test_allow_errors _________________________ self = def test_allow_errors(self): """ Check that conversion halts if ``allow_errors`` is False. """ filename = os.path.join(current_dir, "files", "Skip Exceptions.ipynb") res = self.build_resources() res["metadata"]["path"] = os.path.dirname(filename) with pytest.raises(CellExecutionError) as exc: > run_notebook(filename, {"allow_errors": False}, res) exc = filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Skip Exceptions.ipynb' res = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} self = tests/test_client.py:720: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': "print('ok')"} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': '# üñîçø∂é\nraise Exception("message")'}, {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': "print('ok')"}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Skip Exceptions.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Skip Exceptions.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'ename': 'Exception', 'evalue': 'message', 'output_type': 'error', 'traceback': ['\x1b[1;31m---------------------------------------------------------------------------\x1b[0m', '\x1b[1;31mException\x1b[0m ' 'Traceback (most recent call last)', '\x1b[1;32m\x1b[0m ' 'in ' '\x1b[0;36m\x1b[1;34m\x1b[0m\n' '\x1b[0;32m 1\x1b[0m \x1b[1;31m# ' 'üñîçø∂é\x1b[0m\x1b[1;33m\x1b[0m\x1b[1;33m\x1b[0m\x1b[0m\n' '\x1b[1;32m----> 2\x1b[1;33m ' '\x1b[1;32mraise\x1b[0m ' '\x1b[0mException\x1b[0m\x1b[1;33m(\x1b[0m\x1b[1;34m"message"\x1b[0m\x1b[1;33m)\x1b[0m\x1b[1;33m\x1b[0m\x1b[0m\n' '\x1b[0m', '\x1b[1;31mException\x1b[0m: message']}], 'source': '# üñîçø∂é\nraise Exception("message")'}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'ok\n'}], 'source': "print('ok')"}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} opts = {'allow_errors': False, 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff82e58cc0> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709561405.243023 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 15, in from IPython.core.interactiveshell import DummyMod, InteractiveShell File "/usr/lib/python3.12/site-packages/IPython/core/interactiveshell.py", line 73, in from IPython.core.history import HistoryManager File "/usr/lib/python3.12/site-packages/IPython/core/history.py", line 11, in import sqlite3 File "/usr/lib64/python3.12/sqlite3/__init__.py", line 57, in from sqlite3.dbapi2 import * File "/usr/lib64/python3.12/sqlite3/dbapi2.py", line 27, in from _sqlite3 import * KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 0eef99ac-e64c-48a6-8983-c6eb3348a2d2: Kernel didn't respond in 60 seconds ____________________ TestExecute.test_async_execution_hook _____________________ self = def test_async_execution_hook(self): filename = os.path.join(current_dir, "files", "HelloWorld.ipynb") with open(filename) as f: input_nb = nbformat.read(f, 4) executor, hooks = get_executor_with_hooks(nb=input_nb) > executor.execute() executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' hooks = {'on_cell_complete': , 'on_cell_error': , 'on_cell_execute': , 'on_cell_executed': , 'on_cell_start': , 'on_notebook_complete': , 'on_notebook_error': , 'on_notebook_start': } input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'Hello World\n'}], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} self = tests/test_client.py:943: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff8013ad40> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709561490.0571134 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- [IPKernelApp] WARNING | debugpy_stream undefined, debugging will not be enabled [IPKernelApp] WARNING | debugpy_stream undefined, debugging will not be enabled Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 3, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/base.py", line 11, in from prompt_toolkit.formatted_text import AnyFormattedText, StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/__init__.py", line 15, in from .ansi import ANSI File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/ansi.py", line 6, in from prompt_toolkit.output.vt100 import BG_ANSI_COLORS, FG_ANSI_COLORS File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/__init__.py", line 3, in from .base import DummyOutput, Output File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/base.py", line 11, in from prompt_toolkit.styles import Attrs File "", line 1354, in _find_and_load File "", line 1316, in _find_and_load_unlocked File "", line 1256, in _find_spec File "", line 1524, in find_spec File "", line 1498, in _get_spec File "", line 1616, in find_spec KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 11e0e9c7-d75e-4f23-b369-9c6b14f26f81: Kernel didn't respond in 60 seconds ____________________ TestExecute.test_cleanup_kernel_client ____________________ self = def test_cleanup_kernel_client(self): filename = os.path.join(current_dir, "files", "HelloWorld.ipynb")  with open(filename) as f: input_nb = nbformat.read(f, 4)  executor = NotebookClient( input_nb, resources=self.build_resources(), )  > executor.execute() executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'Hello World\n'}], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} self = tests/test_client.py:793: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff8013ae80> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709561575.8463964 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 3, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/base.py", line 11, in from prompt_toolkit.formatted_text import AnyFormattedText, StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/__init__.py", line 25, in from .html import HTML File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/html.py", line 3, in import xml.dom.minidom as minidom File "/usr/lib64/python3.12/xml/dom/__init__.py", line 140, in from .domreg import getDOMImplementation, registerDOMImplementation File "", line 1354, in _find_and_load File "", line 1316, in _find_and_load_unlocked File "", line 1250, in _find_spec KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel fcd711a2-6170-4a04-9194-65c66639b888: Kernel didn't respond in 60 seconds ____________________ TestExecute.test_custom_kernel_manager ____________________ self = def test_custom_kernel_manager(self): from .fake_kernelmanager import FakeCustomKernelManager  filename = os.path.join(current_dir, "files", "HelloWorld.ipynb")  with open(filename) as f: input_nb = nbformat.read(f, 4)  cleaned_input_nb = copy.deepcopy(input_nb) for cell in cleaned_input_nb.cells: if "execution_count" in cell: del cell["execution_count"] cell["outputs"] = []  executor = NotebookClient( cleaned_input_nb, resources=self.build_resources(), kernel_manager_class=FakeCustomKernelManager, )  # Override terminal size to standardise traceback format with modified_env({"COLUMNS": "80", "LINES": "24"}): > executor.execute() FakeCustomKernelManager = cell = {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'print("Hello World")'} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'Hello World\n'}], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} self = tests/test_client.py:824: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff8013bba0> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709561658.643497 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 56, in from prompt_toolkit.key_binding.defaults import load_key_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/defaults.py", line 10, in from prompt_toolkit.key_binding.bindings.basic import load_basic_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/basic.py", line 17, in from .named_commands import get_by_name File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/named_commands.py", line 19, in from .completion import display_completions_like_readline, generate_completions File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/completion.py", line 11, in from prompt_toolkit.completion import ( File "", line 1384, in _handle_fromlist KeyboardInterrupt ------------------------------ Captured log call ------------------------------- INFO traitlets:fake_kernelmanager.py:10 FakeCustomKernelManager initialized INFO traitlets:fake_kernelmanager.py:15 FakeCustomKernelManager started a kernel INFO traitlets:fake_kernelmanager.py:20 FakeCustomKernelManager created a client ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel b0e21448-5980-4ab8-9571-0887778d513b: Kernel didn't respond in 60 seconds ________________________ TestExecute.test_disable_stdin ________________________ self = def test_disable_stdin(self): """Test disabling standard input""" filename = os.path.join(current_dir, "files", "Disable Stdin.ipynb") res = self.build_resources() res["metadata"]["path"] = os.path.dirname(filename) > input_nb, output_nb = run_notebook(filename, {"allow_errors": True}, res) filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Disable Stdin.ipynb' res = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} self = tests/test_client.py:616: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'try:\n' ' input = raw_input\n' 'except:\n' ' pass\n' '\n' 'name = input("name: ")'} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'try:\n' ' input = raw_input\n' 'except:\n' ' pass\n' '\n' 'name = input("name: ")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Disable Stdin.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Disable Stdin.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': None, 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'try:\n' ' input = raw_input\n' 'except:\n' ' pass\n' '\n' 'name = input("name: ")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} opts = {'allow_errors': True, 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff68380040> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709561740.4508955 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 48, in from .debugger import TerminalPdb, Pdb File "/usr/lib/python3.12/site-packages/IPython/terminal/debugger.py", line 6, in from IPython.core.completer import IPCompleter File "/usr/lib/python3.12/site-packages/IPython/core/completer.py", line 219, in from IPython.core.guarded_eval import guarded_eval, EvaluationContext File "/usr/lib/python3.12/site-packages/IPython/core/guarded_eval.py", line 41, in class InstancesHaveGetItem(Protocol): KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 18fab30b-142f-42c8-9734-eec87985f5b4: Kernel didn't respond in 60 seconds ______________________ TestExecute.test_empty_kernel_name ______________________ self = @pytest.mark.xfail( "python3" not in KernelSpecManager().find_kernel_specs(), reason="requires a python3 kernelspec", ) def test_empty_kernel_name(self): """Can kernel in nb metadata be found when an empty string is passed?  Note: this pattern should be discouraged in practice. Passing in no kernel_name to NotebookClient is recommended instead. """ filename = os.path.join(current_dir, "files", "UnicodePy3.ipynb") res = self.build_resources() > input_nb, output_nb = run_notebook(filename, {"kernel_name": ""}, res) filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/UnicodePy3.ipynb' res = {'metadata': {}} self = tests/test_client.py:606: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': "print('☃')"} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': "print('☃')"}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}}, 'nbformat': 4, 'nbformat_minor': 0} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/UnicodePy3.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/UnicodePy3.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': '☃\n'}], 'source': "print('☃')"}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}}, 'nbformat': 4, 'nbformat_minor': 0} opts = {'kernel_name': '', 'resources': {'metadata': {}}} resources = {'metadata': {}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff683807c0> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709561823.5036106 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 48, in from .debugger import TerminalPdb, Pdb File "/usr/lib/python3.12/site-packages/IPython/terminal/debugger.py", line 6, in from IPython.core.completer import IPCompleter File "/usr/lib/python3.12/site-packages/IPython/core/completer.py", line 250, in import jedi File "/usr/lib/python3.12/site-packages/jedi/__init__.py", line 32, in from jedi.api import Script, Interpreter, set_debug_function, preload_module File "/usr/lib/python3.12/site-packages/jedi/api/__init__.py", line 13, in import parso File "/usr/lib/python3.12/site-packages/parso/__init__.py", line 41, in from parso.parser import ParserSyntaxError File "/usr/lib/python3.12/site-packages/parso/parser.py", line 29, in from parso.pgen2.generator import ReservedString File "/usr/lib/python3.12/site-packages/parso/pgen2/__init__.py", line 10, in from parso.pgen2.generator import generate_grammar File "/usr/lib/python3.12/site-packages/parso/pgen2/generator.py", line 32, in from parso.pgen2.grammar_parser import GrammarParser, NFAState File "/usr/lib/python3.12/site-packages/parso/pgen2/grammar_parser.py", line 9, in from parso.python.tokenize import tokenize File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 929, in _load_unlocked File "", line 990, in exec_module File "", line 1086, in get_code File "", line 1186, in get_data KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 2aa0147c-2e7e-4de7-a2d1-f32e313106ff: Kernel didn't respond in 60 seconds _________________________ TestExecute.test_empty_path __________________________ self = def test_empty_path(self): """Can the kernel be started when the path is empty?""" filename = os.path.join(current_dir, "files", "HelloWorld.ipynb") res = self.build_resources() res["metadata"]["path"] = "" > input_nb, output_nb = run_notebook(filename, {}, res) filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' res = {'metadata': {'path': ''}} self = tests/test_client.py:591: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'print("Hello World")'} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'Hello World\n'}], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} opts = {'resources': {'metadata': {'path': ''}}} resources = {'metadata': {'path': ''}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff68380d60> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709561905.1062331 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 15, in from IPython.core.interactiveshell import DummyMod, InteractiveShell File "/usr/lib/python3.12/site-packages/IPython/core/interactiveshell.py", line 60, in from IPython.core import magic, oinspect, page, prefilter, ultratb File "/usr/lib/python3.12/site-packages/IPython/core/prefilter.py", line 526, in class PrefilterHandler(Configurable): KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 63b9ff29-bb72-4d29-908e-abfdda6d010a: Kernel didn't respond in 60 seconds _________________ TestExecute.test_error_async_execution_hook __________________ self = def test_error_async_execution_hook(self): filename = os.path.join(current_dir, "files", "Error.ipynb") with open(filename) as f: input_nb = nbformat.read(f, 4) executor, hooks = get_executor_with_hooks(nb=input_nb) with pytest.raises(CellExecutionError): > executor.execute() executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Error.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Error.ipynb' hooks = {'on_cell_complete': , 'on_cell_error': , 'on_cell_execute': , 'on_cell_executed': , 'on_cell_start': , 'on_notebook_complete': , 'on_notebook_error': , 'on_notebook_start': } input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'id': 'd200673b', 'metadata': {}, 'outputs': [{'ename': 'ZeroDivisionError', 'evalue': 'division by zero', 'output_type': 'error', 'traceback': ['\x1b[0;31m---------------------------------------------------------------------------\x1b[0m', '\x1b[0;31mZeroDivisionError\x1b[0m ' 'Traceback (most recent call last)', '\x1b[0;32m/tmp/ipykernel_1277493/182040962.py\x1b[0m ' 'in ' '\x1b[0;36m\x1b[0;34m\x1b[0m\n' '\x1b[0;32m----> 1\x1b[0;31m ' '\x1b[0;36m0\x1b[0m\x1b[0;34m/\x1b[0m\x1b[0;36m0\x1b[0m\x1b[0;34m\x1b[0m\x1b[0;34m\x1b[0m\x1b[0m\n' '\x1b[0m', '\x1b[0;31mZeroDivisionError\x1b[0m: ' 'division by zero']}], 'source': '0/0'}], 'metadata': {'kernelspec': {'display_name': 'Python 3 (ipykernel)', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.9.5'}}, 'nbformat': 4, 'nbformat_minor': 5} self = tests/test_client.py:959: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff68381440> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709561991.4840074 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 56, in from prompt_toolkit.key_binding.defaults import load_key_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/defaults.py", line 10, in from prompt_toolkit.key_binding.bindings.basic import load_basic_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/basic.py", line 17, in from .named_commands import get_by_name File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/named_commands.py", line 15, in from prompt_toolkit.layout.controls import BufferControl File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/__init__.py", line 49, in from .containers import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/containers.py", line 50, in from .screen import _CHAR_CACHE, Screen, WritePosition File "", line 1354, in _find_and_load File "", line 1316, in _find_and_load_unlocked File "", line 1256, in _find_spec File "", line 1524, in find_spec File "", line 1498, in _get_spec File "", line 1597, in find_spec File "", line 147, in _path_stat KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 75a037eb-07e3-44fa-82ea-4f0f77a76786: Kernel didn't respond in 60 seconds _________________ TestExecute.test_error_execution_hook_error __________________ self = def test_error_execution_hook_error(self): filename = os.path.join(current_dir, "files", "Error.ipynb") with open(filename) as f: input_nb = nbformat.read(f, 4) executor, hooks = get_executor_with_hooks(nb=input_nb) with pytest.raises(CellExecutionError): > executor.execute() executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Error.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Error.ipynb' hooks = {'on_cell_complete': , 'on_cell_error': , 'on_cell_execute': , 'on_cell_executed': , 'on_cell_start': , 'on_notebook_complete': , 'on_notebook_error': , 'on_notebook_start': } input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'id': 'd200673b', 'metadata': {}, 'outputs': [{'ename': 'ZeroDivisionError', 'evalue': 'division by zero', 'output_type': 'error', 'traceback': ['\x1b[0;31m---------------------------------------------------------------------------\x1b[0m', '\x1b[0;31mZeroDivisionError\x1b[0m ' 'Traceback (most recent call last)', '\x1b[0;32m/tmp/ipykernel_1277493/182040962.py\x1b[0m ' 'in ' '\x1b[0;36m\x1b[0;34m\x1b[0m\n' '\x1b[0;32m----> 1\x1b[0;31m ' '\x1b[0;36m0\x1b[0m\x1b[0;34m/\x1b[0m\x1b[0;36m0\x1b[0m\x1b[0;34m\x1b[0m\x1b[0;34m\x1b[0m\x1b[0m\n' '\x1b[0m', '\x1b[0;31mZeroDivisionError\x1b[0m: ' 'division by zero']}], 'source': '0/0'}], 'metadata': {'kernelspec': {'display_name': 'Python 3 (ipykernel)', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.9.5'}}, 'nbformat': 4, 'nbformat_minor': 5} self = tests/test_client.py:912: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff68381da0> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709562081.8778322 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 3, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/base.py", line 11, in from prompt_toolkit.formatted_text import AnyFormattedText, StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/__init__.py", line 15, in from .ansi import ANSI File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/ansi.py", line 6, in from prompt_toolkit.output.vt100 import BG_ANSI_COLORS, FG_ANSI_COLORS File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/__init__.py", line 3, in from .base import DummyOutput, Output File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/base.py", line 11, in from prompt_toolkit.styles import Attrs File "/usr/lib/python3.12/site-packages/prompt_toolkit/styles/__init__.py", line 6, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/styles/base.py", line 108, in class BaseStyle(metaclass=ABCMeta): File "", line 106, in __new__ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 2b6dedc9-1cf3-436d-aa5d-67cea5deb32a: Kernel didn't respond in 60 seconds _____________________ TestExecute.test_error_notebook_hook _____________________ self = def test_error_notebook_hook(self): filename = os.path.join(current_dir, "files", "Autokill.ipynb") with open(filename) as f: input_nb = nbformat.read(f, 4) executor, hooks = get_executor_with_hooks(nb=input_nb) with pytest.raises(RuntimeError): executor.execute() > hooks["on_cell_start"].assert_called_once() executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Autokill.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Autokill.ipynb' hooks = {'on_cell_complete': , 'on_cell_error': , 'on_cell_execute': , 'on_cell_executed': , 'on_cell_start': , 'on_notebook_complete': , 'on_notebook_error': , 'on_notebook_start': } input_nb = {'cells': [{'cell_type': 'code', 'execution_count': None, 'metadata': {}, 'outputs': [], 'source': 'import os\n' 'import signal\n' 'pid = os.getpid()\n' 'os.kill(pid, signal.SIGTERM)'}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.8.3'}}, 'nbformat': 4, 'nbformat_minor': 4} self = tests/test_client.py:929: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = def assert_called_once(self): """assert that the mock was called only once. """ if not self.call_count == 1: msg = ("Expected '%s' to have been called once. Called %s times.%s" % (self._mock_name or 'mock', self.call_count, self._calls_repr())) > raise AssertionError(msg) E AssertionError: Expected 'mock' to have been called once. Called 0 times. E Calls: [call.__eq__(None)]. msg = ("Expected 'mock' to have been called once. Called 0 times.\n" 'Calls: [call.__eq__(None)].') self = /usr/lib64/python3.12/unittest/mock.py:923: AssertionError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 56, in from prompt_toolkit.key_binding.defaults import load_key_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/defaults.py", line 10, in from prompt_toolkit.key_binding.bindings.basic import load_basic_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/basic.py", line 17, in from .named_commands import get_by_name File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/named_commands.py", line 70, in @register("beginning-of-buffer") ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/named_commands.py", line 47, in decorator _readline_commands[name] = key_binding()(cast(_Handler, handler)) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/key_bindings.py", line 478, in decorator return Binding( ^^^^^^^^ File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/key_bindings.py", line 117, in __init__ self.filter = to_filter(filter) ^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/prompt_toolkit/filters/utils.py", line 21, in to_filter def to_filter(bool_or_filter: FilterOrBool) -> Filter: KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 971190c3-2b5a-44ed-93d1-955c21860241: Kernel didn't respond in 60 seconds ______________________ TestExecute.test_execute_function _______________________ self = def test_execute_function(self): # Test the execute() convenience API filename = os.path.join(current_dir, "files", "HelloWorld.ipynb")  with open(filename) as f: input_nb = nbformat.read(f, 4)  original = copy.deepcopy(input_nb) > executed = execute(original, os.path.dirname(filename)) f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'Hello World\n'}], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} original = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'Hello World\n'}], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} self = tests/test_client.py:861: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ nbclient/client.py:1314: in execute return NotebookClient(nb=nb, resources=resources, km=km, **kwargs).execute() cwd = '/builddir/build/BUILD/nbclient-0.9.0/tests/files' km = None kwargs = {} nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'Hello World\n'}], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff68382b60> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709562241.691538 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 56, in from prompt_toolkit.key_binding.defaults import load_key_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/defaults.py", line 10, in from prompt_toolkit.key_binding.bindings.basic import load_basic_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/basic.py", line 17, in from .named_commands import get_by_name File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/named_commands.py", line 15, in from prompt_toolkit.layout.controls import BufferControl File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/__init__.py", line 49, in from .containers import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/containers.py", line 34, in from .controls import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/controls.py", line 32, in from .processors import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/processors.py", line 27, in from .utils import explode_text_fragments File "", line 1354, in _find_and_load File "", line 1316, in _find_and_load_unlocked File "", line 1256, in _find_spec File "", line 1524, in find_spec File "", line 1498, in _get_spec File "", line 1631, in find_spec File "", line 1585, in _get_spec File "", line 1152, in __init__ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 38ec0002-1055-4eb2-b48a-9e37667d9d51: Kernel didn't respond in 60 seconds _______________________ TestExecute.test_execution_hook ________________________ self = def test_execution_hook(self): filename = os.path.join(current_dir, "files", "HelloWorld.ipynb") with open(filename) as f: input_nb = nbformat.read(f, 4) executor, hooks = get_executor_with_hooks(nb=input_nb) > executor.execute() executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' hooks = {'on_cell_complete': , 'on_cell_error': , 'on_cell_execute': , 'on_cell_executed': , 'on_cell_start': , 'on_notebook_complete': , 'on_notebook_error': , 'on_notebook_start': } input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'Hello World\n'}], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} self = tests/test_client.py:896: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff68383600> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709562326.0384002 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 56, in from prompt_toolkit.key_binding.defaults import load_key_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/defaults.py", line 18, in from prompt_toolkit.key_binding.bindings.vi import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/vi.py", line 37, in from prompt_toolkit.input.vt100_parser import Vt100Parser File "/usr/lib/python3.12/site-packages/prompt_toolkit/input/vt100_parser.py", line 32, in _mouse_event_prefix_re = re.compile("^" + re.escape("\x1b[") + r"( def test_force_raise_errors(self): """ Check that conversion halts if the ``force_raise_errors`` traitlet on NotebookClient is set to True. """ filename = os.path.join(current_dir, "files", "Skip Exceptions with Cell Tags.ipynb") res = self.build_resources() res["metadata"]["path"] = os.path.dirname(filename) with pytest.raises(CellExecutionError) as exc: > run_notebook(filename, {"force_raise_errors": True}, res) exc = filename = ('/builddir/build/BUILD/nbclient-0.9.0/tests/files/Skip Exceptions with Cell ' 'Tags.ipynb') res = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} self = tests/test_client.py:738: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "print('ok')"} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'tags': ['raises-exception']}, 'outputs': [], 'source': 'import sys\n' 'print("hello")\n' 'print("errorred", file=sys.stderr)\n' '# üñîçø∂é\n' 'raise Exception("message")'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "print('ok')"}], 'metadata': {'kernelspec': {'display_name': 'Python 3 (ipykernel)', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.10.9'}, 'widgets': {'application/vnd.jupyter.widget-state+json': {'state': {}, 'version_major': 2, 'version_minor': 0}}}, 'nbformat': 4, 'nbformat_minor': 4} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Skip Exceptions with Cell Tags.ipynb' mode='r' encoding='UTF-8'> filename = ('/builddir/build/BUILD/nbclient-0.9.0/tests/files/Skip Exceptions with Cell ' 'Tags.ipynb') input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'tags': ['raises-exception']}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'hello\n'}, {'name': 'stderr', 'output_type': 'stream', 'text': 'errorred\n'}, {'ename': 'Exception', 'evalue': 'message', 'output_type': 'error', 'traceback': ['\x1b[0;31m---------------------------------------------------------------------------\x1b[0m', '\x1b[0;31mException\x1b[0m ' 'Traceback (most recent call last)', 'Cell \x1b[0;32mIn[1], line 5\x1b[0m\n' '\x1b[1;32m 3\x1b[0m ' '\x1b[38;5;28mprint\x1b[39m(\x1b[38;5;124m"\x1b[39m\x1b[38;5;124merrorred\x1b[39m\x1b[38;5;124m"\x1b[39m, ' 'file\x1b[38;5;241m=\x1b[39msys\x1b[38;5;241m.\x1b[39mstderr)\n' '\x1b[1;32m 4\x1b[0m ' '\x1b[38;5;66;03m# üñîçø∂é\x1b[39;00m\n' '\x1b[0;32m----> 5\x1b[0m ' '\x1b[38;5;28;01mraise\x1b[39;00m ' '\x1b[38;5;167;01mException\x1b[39;00m(\x1b[38;5;124m"\x1b[39m\x1b[38;5;124mmessage\x1b[39m\x1b[38;5;124m"\x1b[39m)\n', '\x1b[0;31mException\x1b[0m: message']}], 'source': 'import sys\n' 'print("hello")\n' 'print("errorred", file=sys.stderr)\n' '# üñîçø∂é\n' 'raise Exception("message")'}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'ok\n'}], 'source': "print('ok')"}], 'metadata': {'kernelspec': {'display_name': 'Python 3 (ipykernel)', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.10.9'}, 'widgets': {'application/vnd.jupyter.widget-state+json': {'state': {}, 'version_major': 2, 'version_minor': 0}}}, 'nbformat': 4, 'nbformat_minor': 4} opts = {'force_raise_errors': True, 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff68383c40> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709562408.6681554 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 36, in from .search import SearchDirection, SearchState File "/usr/lib/python3.12/site-packages/prompt_toolkit/search.py", line 28, in class SearchDirection(Enum): File "/usr/lib64/python3.12/enum.py", line 583, in __new__ enum_class = super().__new__(metacls, cls, bases, classdict, **kwds) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/enum.py", line 249, in __set_name__ def __set_name__(self, enum_class, member_name): KeyboardInterrupt Error calling __set_name__ on '_proto_member' instance 'FORWARD' in 'SearchDirection' ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 4768967d-2067-46ca-b481-4a895056cf69: Kernel didn't respond in 60 seconds _________________ TestExecute.test_kernel_death_after_timeout __________________ self = @flaky def test_kernel_death_after_timeout(self): """Check that an error is raised when the kernel is_alive is false after a cell timed out""" filename = os.path.join(current_dir, "files", "Interrupt.ipynb") with open(filename) as f: input_nb = nbformat.read(f, 4) res = self.build_resources() res["metadata"]["path"] = os.path.dirname(filename)  executor = NotebookClient(input_nb, timeout=1)  with pytest.raises(TimeoutError): > executor.execute() executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Interrupt.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Interrupt.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'ename': 'KeyboardInterrupt', 'evalue': '', 'output_type': 'error', 'traceback': ['\x1b[0;31m---------------------------------------------------------------------------\x1b[0m', '\x1b[0;31mKeyboardInterrupt\x1b[0m ' 'Traceback (most recent call last)', '\x1b[0;32m\x1b[0m ' 'in ' '\x1b[0;36m\x1b[0;34m\x1b[0m\n' '\x1b[0;32m----> 1\x1b[0;31m ' '\x1b[0;32mwhile\x1b[0m ' '\x1b[0;32mTrue\x1b[0m\x1b[0;34m:\x1b[0m ' '\x1b[0;32mcontinue\x1b[0m\x1b[0;34m\x1b[0m\x1b[0m\n' '\x1b[0m', '\x1b[0;31mKeyboardInterrupt\x1b[0m: ']}], 'source': 'while True: continue'}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'done\n'}], 'source': 'print("done")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} res = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} self = tests/test_client.py:686: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff6bc1cd60> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709562574.0921872 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 27, in from .shortcuts import PromptSession, print_formatted_text, prompt File "/usr/lib/python3.12/site-packages/prompt_toolkit/shortcuts/__init__.py", line 3, in from .dialogs import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/shortcuts/dialogs.py", line 22, in from prompt_toolkit.widgets import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/widgets/__init__.py", line 11, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/widgets/base.py", line 80, in from .toolbars import SearchToolbar File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 929, in _load_unlocked File "", line 990, in exec_module File "", line 1086, in get_code File "", line 1185, in get_data KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 84dba4d6-cf4c-47c2-8043-8af80dac3f0f: Kernel didn't respond in 60 seconds ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 3, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/base.py", line 11, in from prompt_toolkit.formatted_text import AnyFormattedText, StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/__init__.py", line 15, in from .ansi import ANSI File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/ansi.py", line 6, in from prompt_toolkit.output.vt100 import BG_ANSI_COLORS, FG_ANSI_COLORS File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/__init__.py", line 3, in from .base import DummyOutput, Output File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/base.py", line 9, in from prompt_toolkit.cursor_shapes import CursorShape File "/usr/lib/python3.12/site-packages/prompt_toolkit/cursor_shapes.py", line 8, in from prompt_toolkit.key_binding.vi_state import InputMode File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/__init__.py", line 10, in from .key_processor import KeyPress, KeyPressEvent File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/key_processor.py", line 19, in from prompt_toolkit.utils import Event File "/usr/lib/python3.12/site-packages/prompt_toolkit/utils.py", line 18, in from wcwidth import wcwidth File "/usr/lib/python3.12/site-packages/wcwidth/__init__.py", line 12, in from .wcwidth import ZERO_WIDTH # noqa ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/wcwidth/wcwidth.py", line 72, in from .table_zero import ZERO_WIDTH File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 929, in _load_unlocked File "", line 990, in exec_module File "", line 1086, in get_code File "", line 1185, in get_data KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel af424691-1a33-4c78-9bdc-ed306cee38ea: Kernel didn't respond in 60 seconds ___________________ TestExecute.test_populate_language_info ____________________ self = def test_populate_language_info(self): nb = nbformat.v4.new_notebook() # Certainly has no language_info. executor = NotebookClient(nb, kernel_name="python") > nb = executor.execute() executor = nb = {'cells': [], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 5} self = tests/test_client.py:583: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff6bc1d4e0> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709562725.6445758 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 48, in from .debugger import TerminalPdb, Pdb File "/usr/lib/python3.12/site-packages/IPython/terminal/debugger.py", line 6, in from IPython.core.completer import IPCompleter File "/usr/lib/python3.12/site-packages/IPython/core/completer.py", line 250, in import jedi File "/usr/lib/python3.12/site-packages/jedi/__init__.py", line 32, in from jedi.api import Script, Interpreter, set_debug_function, preload_module File "/usr/lib/python3.12/site-packages/jedi/api/__init__.py", line 13, in import parso File "/usr/lib/python3.12/site-packages/parso/__init__.py", line 41, in from parso.parser import ParserSyntaxError File "/usr/lib/python3.12/site-packages/parso/parser.py", line 29, in from parso.pgen2.generator import ReservedString File "/usr/lib/python3.12/site-packages/parso/pgen2/__init__.py", line 10, in from parso.pgen2.generator import generate_grammar File "/usr/lib/python3.12/site-packages/parso/pgen2/generator.py", line 32, in from parso.pgen2.grammar_parser import GrammarParser, NFAState File "/usr/lib/python3.12/site-packages/parso/pgen2/grammar_parser.py", line 9, in from parso.python.tokenize import tokenize File "/usr/lib/python3.12/site-packages/parso/python/tokenize.py", line 123, in fstring_format_spec_multi_line = _compile(r'[^{}]+') ^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/parso/python/tokenize.py", line 102, in _compile return re.compile(expr, re.UNICODE) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/__init__.py", line 228, in compile return _compile(pattern, flags) ^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/__init__.py", line 307, in _compile p = _compiler.compile(pattern, flags) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/_compiler.py", line 743, in compile p = _parser.parse(p, flags) ^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/_parser.py", line 972, in parse p = _parse_sub(source, state, flags & SRE_FLAG_VERBOSE, 0) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/_parser.py", line 453, in _parse_sub itemsappend(_parse(source, state, verbose, nested + 1, ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/_parser.py", line 523, in _parse sourceget() File "/usr/lib64/python3.12/re/_parser.py", line 254, in get def get(self): KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel f85971ee-a943-4fc5-9d39-c53eee237a35: Kernel didn't respond in 60 seconds ___________________ TestExecute.test_process_message_wrapper ___________________ self = def test_process_message_wrapper(self): outputs: list[Any] = []  class WrappedPreProc(NotebookClient): def process_message(self, msg, cell, cell_index): result = super().process_message(msg, cell, cell_index) if result: outputs.append(result) return result  current_dir = os.path.dirname(__file__) filename = os.path.join(current_dir, "files", "HelloWorld.ipynb")  with open(filename) as f: input_nb = nbformat.read(f, 4)  original = copy.deepcopy(input_nb) wpp = WrappedPreProc(input_nb) > executed = wpp.execute() WrappedPreProc = .WrappedPreProc'> current_dir = '/builddir/build/BUILD/nbclient-0.9.0/tests' f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'Hello World\n'}], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} original = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'Hello World\n'}], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} outputs = [] self = wpp = .WrappedPreProc object at 0xffffff6bc9d5b0> tests/test_client.py:849: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (.WrappedPreProc object at 0xffffff6bc9d5b0>,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = .WrappedPreProc object at 0xffffff6bc9d5b0> /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff6bc1c5e0> self = .WrappedPreProc object at 0xffffff6bc9d5b0> nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = .WrappedPreProc object at 0xffffff6bc9d5b0> /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709562808.711739 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 56, in from prompt_toolkit.key_binding.defaults import load_key_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/defaults.py", line 10, in from prompt_toolkit.key_binding.bindings.basic import load_basic_bindings File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/basic.py", line 17, in from .named_commands import get_by_name File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/bindings/named_commands.py", line 19, in from .completion import display_completions_like_readline, generate_completions File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 929, in _load_unlocked File "", line 990, in exec_module File "", line 1084, in get_code KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 193407f3-16cd-49c1-8067-57170143b9af: Kernel didn't respond in 60 seconds _____________________ TestExecute.test_reset_kernel_client _____________________ self = def test_reset_kernel_client(self): filename = os.path.join(current_dir, "files", "HelloWorld.ipynb")  with open(filename) as f: input_nb = nbformat.read(f, 4)  executor = NotebookClient( input_nb, resources=self.build_resources(), )  > executor.execute(cleanup_kc=False) executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/HelloWorld.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'Hello World\n'}], 'source': 'print("Hello World")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} self = tests/test_client.py:768: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {'cleanup_kc': False} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {'cleanup_kc': False} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = False kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff6bc1d940> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709562891.0590177 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 48, in from .debugger import TerminalPdb, Pdb File "/usr/lib/python3.12/site-packages/IPython/terminal/debugger.py", line 6, in from IPython.core.completer import IPCompleter File "/usr/lib/python3.12/site-packages/IPython/core/completer.py", line 250, in import jedi File "/usr/lib/python3.12/site-packages/jedi/__init__.py", line 32, in from jedi.api import Script, Interpreter, set_debug_function, preload_module File "/usr/lib/python3.12/site-packages/jedi/api/__init__.py", line 13, in import parso File "/usr/lib/python3.12/site-packages/parso/__init__.py", line 41, in from parso.parser import ParserSyntaxError File "/usr/lib/python3.12/site-packages/parso/parser.py", line 29, in from parso.pgen2.generator import ReservedString File "/usr/lib/python3.12/site-packages/parso/pgen2/__init__.py", line 10, in from parso.pgen2.generator import generate_grammar File "/usr/lib/python3.12/site-packages/parso/pgen2/generator.py", line 32, in from parso.pgen2.grammar_parser import GrammarParser, NFAState File "/usr/lib/python3.12/site-packages/parso/pgen2/grammar_parser.py", line 9, in from parso.python.tokenize import tokenize File "/usr/lib/python3.12/site-packages/parso/python/tokenize.py", line 119, in fstring_string_multi_line = _compile( ^^^^^^^^^ File "/usr/lib/python3.12/site-packages/parso/python/tokenize.py", line 102, in _compile return re.compile(expr, re.UNICODE) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/__init__.py", line 228, in compile return _compile(pattern, flags) ^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/__init__.py", line 308, in _compile if flags & DEBUG: ~~~~~~^~~~~~~ File "/usr/lib64/python3.12/enum.py", line 1538, in __and__ def __and__(self, other): KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 98c00629-9272-4327-9f9d-5eb8ee013d35: Kernel didn't respond in 60 seconds _____________________ TestExecute.test_sync_kernel_manager _____________________ self = def test_sync_kernel_manager(self): nb = nbformat.v4.new_notebook() # Certainly has no language_info. executor = NotebookClient(nb, kernel_name="python", kernel_manager_class=KernelManager) > nb = executor.execute() executor = nb = {'cells': [], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 5} self = tests/test_client.py:666: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff6bc1dee0> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_client/utils.py:30: in wrapped raise e args = (,) coro = future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> kwargs = {'timeout': 60} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> nest_asyncio = /usr/lib/python3.12/site-packages/jupyter_client/utils.py:27: in wrapped return loop.run_until_complete(future) args = (,) coro = future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> kwargs = {'timeout': 60} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> nest_asyncio = /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = exception=RuntimeError("Kernel didn't respond in 60 seconds")> manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709562972.8891213 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 48, in from .debugger import TerminalPdb, Pdb File "/usr/lib/python3.12/site-packages/IPython/terminal/debugger.py", line 6, in from IPython.core.completer import IPCompleter File "/usr/lib/python3.12/site-packages/IPython/core/completer.py", line 250, in import jedi File "/usr/lib/python3.12/site-packages/jedi/__init__.py", line 32, in from jedi.api import Script, Interpreter, set_debug_function, preload_module File "/usr/lib/python3.12/site-packages/jedi/api/__init__.py", line 13, in import parso File "/usr/lib/python3.12/site-packages/parso/__init__.py", line 42, in from parso.grammar import Grammar, load_grammar File "/usr/lib/python3.12/site-packages/parso/grammar.py", line 10, in from parso.python.diff import DiffParser File "/usr/lib/python3.12/site-packages/parso/python/diff.py", line 34, in from parso.python.parser import Parser File "/usr/lib/python3.12/site-packages/parso/python/parser.py", line 1, in from parso.python import tree File "/usr/lib/python3.12/site-packages/parso/python/tree.py", line 53, in from parso.python.prefix import split_prefix File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 929, in _load_unlocked File "", line 990, in exec_module File "", line 1084, in get_code KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 8b74eb17-7c9f-476c-ab52-d1e8467ffe19: Kernel didn't respond in 60 seconds ___________________________ TestExecute.test_timeout ___________________________ self = def test_timeout(self): """Check that an error is raised when a computation times out""" filename = os.path.join(current_dir, "files", "Interrupt.ipynb") res = self.build_resources() res["metadata"]["path"] = os.path.dirname(filename)  with pytest.raises(TimeoutError) as err: > run_notebook(filename, {"timeout": 1}, res) err = filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Interrupt.ipynb' res = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} self = tests/test_client.py:639: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'print("done")'} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'while True: continue'}, {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'print("done")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Interrupt.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Interrupt.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'ename': 'KeyboardInterrupt', 'evalue': '', 'output_type': 'error', 'traceback': ['\x1b[0;31m---------------------------------------------------------------------------\x1b[0m', '\x1b[0;31mKeyboardInterrupt\x1b[0m ' 'Traceback (most recent call last)', '\x1b[0;32m\x1b[0m ' 'in ' '\x1b[0;36m\x1b[0;34m\x1b[0m\n' '\x1b[0;32m----> 1\x1b[0;31m ' '\x1b[0;32mwhile\x1b[0m ' '\x1b[0;32mTrue\x1b[0m\x1b[0;34m:\x1b[0m ' '\x1b[0;32mcontinue\x1b[0m\x1b[0;34m\x1b[0m\x1b[0m\n' '\x1b[0m', '\x1b[0;31mKeyboardInterrupt\x1b[0m: ']}], 'source': 'while True: continue'}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'done\n'}], 'source': 'print("done")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} opts = {'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}, 'timeout': 1} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff6bc1d6c0> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709563056.4712038 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 48, in from .debugger import TerminalPdb, Pdb File "/usr/lib/python3.12/site-packages/IPython/terminal/debugger.py", line 6, in from IPython.core.completer import IPCompleter File "/usr/lib/python3.12/site-packages/IPython/core/completer.py", line 250, in import jedi File "/usr/lib/python3.12/site-packages/jedi/__init__.py", line 32, in from jedi.api import Script, Interpreter, set_debug_function, preload_module File "/usr/lib/python3.12/site-packages/jedi/api/__init__.py", line 21, in from jedi.api import classes File "/usr/lib/python3.12/site-packages/jedi/api/classes.py", line 24, in from jedi.inference.utils import unite File "/usr/lib/python3.12/site-packages/jedi/inference/__init__.py", line 70, in from jedi.inference import imports File "/usr/lib/python3.12/site-packages/jedi/inference/imports.py", line 23, in from jedi.inference import compiled File "/usr/lib/python3.12/site-packages/jedi/inference/compiled/__init__.py", line 4, in from jedi.inference.compiled.value import CompiledValue, CompiledName, \ File "/usr/lib/python3.12/site-packages/jedi/inference/compiled/value.py", line 13, in from jedi.inference.filters import AbstractFilter File "", line 1354, in _find_and_load File "", line 1316, in _find_and_load_unlocked File "", line 1256, in _find_spec File "", line 1524, in find_spec File "", line 1498, in _get_spec File "", line 1628, in find_spec File "", line 491, in _verbose_message KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel d5791da8-cdd6-485a-b072-45c3e72c6802: Kernel didn't respond in 60 seconds ________________________ TestExecute.test_timeout_func _________________________ self = def test_timeout_func(self): """Check that an error is raised when a computation times out""" filename = os.path.join(current_dir, "files", "Interrupt.ipynb") res = self.build_resources() res["metadata"]["path"] = os.path.dirname(filename)  def timeout_func(source): return 10  with pytest.raises(TimeoutError): > run_notebook(filename, {"timeout_func": timeout_func}, res) filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Interrupt.ipynb' res = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} self = timeout_func = .timeout_func at 0xffffff6bc1efc0> tests/test_client.py:661: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'print("done")'} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'while True: continue'}, {'cell_type': 'code', 'metadata': {'collapsed': False}, 'outputs': [], 'source': 'print("done")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/Interrupt.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Interrupt.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {'collapsed': False}, 'outputs': [{'ename': 'KeyboardInterrupt', 'evalue': '', 'output_type': 'error', 'traceback': ['\x1b[0;31m---------------------------------------------------------------------------\x1b[0m', '\x1b[0;31mKeyboardInterrupt\x1b[0m ' 'Traceback (most recent call last)', '\x1b[0;32m\x1b[0m ' 'in ' '\x1b[0;36m\x1b[0;34m\x1b[0m\n' '\x1b[0;32m----> 1\x1b[0;31m ' '\x1b[0;32mwhile\x1b[0m ' '\x1b[0;32mTrue\x1b[0m\x1b[0;34m:\x1b[0m ' '\x1b[0;32mcontinue\x1b[0m\x1b[0;34m\x1b[0m\x1b[0m\n' '\x1b[0m', '\x1b[0;31mKeyboardInterrupt\x1b[0m: ']}], 'source': 'while True: continue'}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {'collapsed': False}, 'outputs': [{'name': 'stdout', 'output_type': 'stream', 'text': 'done\n'}], 'source': 'print("done")'}], 'metadata': {}, 'nbformat': 4, 'nbformat_minor': 0} opts = {'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}, 'timeout_func': .timeout_func at 0xffffff6bc1efc0>} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff6bc1f2e0> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709563140.663214 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 48, in from .debugger import TerminalPdb, Pdb File "/usr/lib/python3.12/site-packages/IPython/terminal/debugger.py", line 6, in from IPython.core.completer import IPCompleter File "/usr/lib/python3.12/site-packages/IPython/core/completer.py", line 250, in import jedi File "/usr/lib/python3.12/site-packages/jedi/__init__.py", line 32, in from jedi.api import Script, Interpreter, set_debug_function, preload_module File "/usr/lib/python3.12/site-packages/jedi/api/__init__.py", line 21, in from jedi.api import classes File "/usr/lib/python3.12/site-packages/jedi/api/classes.py", line 24, in from jedi.inference.utils import unite File "/usr/lib/python3.12/site-packages/jedi/inference/__init__.py", line 70, in from jedi.inference import imports File "/usr/lib/python3.12/site-packages/jedi/inference/imports.py", line 23, in from jedi.inference import compiled File "/usr/lib/python3.12/site-packages/jedi/inference/compiled/__init__.py", line 4, in from jedi.inference.compiled.value import CompiledValue, CompiledName, \ File "/usr/lib/python3.12/site-packages/jedi/inference/compiled/value.py", line 13, in from jedi.inference.filters import AbstractFilter File "/usr/lib/python3.12/site-packages/jedi/inference/filters.py", line 12, in from jedi.inference import flow_analysis File "", line 1351, in _find_and_load File "", line 420, in __exit__ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel cd136d32-f94e-42c5-bf3f-fff7f0f31bdc: Kernel didn't respond in 60 seconds ___________________________ TestExecute.test_widgets ___________________________ self = def test_widgets(self): """Runs a test notebook with widgets and checks the widget state is saved.""" input_file = os.path.join(current_dir, "files", "JupyterWidgets.ipynb") opts = {"kernel_name": "python"} res = self.build_resources() res["metadata"]["path"] = os.path.dirname(input_file) > input_nb, output_nb = run_notebook(input_file, opts, res) input_file = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/JupyterWidgets.ipynb' opts = {'kernel_name': 'python'} res = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} self = tests/test_client.py:870: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/test_client.py:138: in run_notebook output_nb = executor.execute() cell = {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "# it should also handle custom msg'es\n" "label.send({'msg': 'Hello'})"} cleaned_input_nb = {'cells': [{'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': 'import ipywidgets\n' "label = ipywidgets.Label('Hello World')\n" 'display(label)'}, {'cell_type': 'code', 'metadata': {}, 'outputs': [], 'source': "# it should also handle custom msg'es\n" "label.send({'msg': 'Hello'})"}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.6.4'}, 'widgets': {'application/vnd.jupyter.widget-state+json': {'state': {'8273e8fe9d9941a4a63c062158e0a630': {'model_module': '@jupyter-widgets/controls', 'model_module_version': '1.4.0', 'model_name': 'DescriptionStyleModel', 'state': {'description_width': ''}}, 'a72770a4f541425f8fe85833a3dc2a8e': {'model_module': '@jupyter-widgets/controls', 'model_module_version': '1.4.0', 'model_name': 'LabelModel', 'state': {'context_menu': None, 'layout': 'IPY_MODEL_dec20f599109458ca607b1df5959469b', 'style': 'IPY_MODEL_8273e8fe9d9941a4a63c062158e0a630', 'value': 'Hello ' 'World'}}, 'dec20f599109458ca607b1df5959469b': {'model_module': '@jupyter-widgets/base', 'model_module_version': '1.1.0', 'model_name': 'LayoutModel', 'state': {}}}, 'version_major': 2, 'version_minor': 0}}}, 'nbformat': 4, 'nbformat_minor': 2} executor = f = <_io.TextIOWrapper name='/builddir/build/BUILD/nbclient-0.9.0/tests/files/JupyterWidgets.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/JupyterWidgets.ipynb' input_nb = {'cells': [{'cell_type': 'code', 'execution_count': 1, 'metadata': {}, 'outputs': [{'data': {'application/vnd.jupyter.widget-view+json': {'model_id': 'f46f26da84b54255bccc3a69d7eb08de', 'version_major': 2, 'version_minor': 0}, 'text/plain': "Label(value='Hello World')"}, 'metadata': {}, 'output_type': 'display_data'}], 'source': 'import ipywidgets\n' "label = ipywidgets.Label('Hello World')\n" 'display(label)'}, {'cell_type': 'code', 'execution_count': 2, 'metadata': {}, 'outputs': [], 'source': "# it should also handle custom msg'es\n" "label.send({'msg': 'Hello'})"}], 'metadata': {'kernelspec': {'display_name': 'Python 3', 'language': 'python', 'name': 'python3'}, 'language_info': {'codemirror_mode': {'name': 'ipython', 'version': 3}, 'file_extension': '.py', 'mimetype': 'text/x-python', 'name': 'python', 'nbconvert_exporter': 'python', 'pygments_lexer': 'ipython3', 'version': '3.6.4'}, 'widgets': {'application/vnd.jupyter.widget-state+json': {'state': {'8273e8fe9d9941a4a63c062158e0a630': {'model_module': '@jupyter-widgets/controls', 'model_module_version': '1.4.0', 'model_name': 'DescriptionStyleModel', 'state': {'description_width': ''}}, 'a72770a4f541425f8fe85833a3dc2a8e': {'model_module': '@jupyter-widgets/controls', 'model_module_version': '1.4.0', 'model_name': 'LabelModel', 'state': {'context_menu': None, 'layout': 'IPY_MODEL_dec20f599109458ca607b1df5959469b', 'style': 'IPY_MODEL_8273e8fe9d9941a4a63c062158e0a630', 'value': 'Hello ' 'World'}}, 'dec20f599109458ca607b1df5959469b': {'model_module': '@jupyter-widgets/base', 'model_module_version': '1.1.0', 'model_name': 'LayoutModel', 'state': {}}}, 'version_major': 2, 'version_minor': 0}}}, 'nbformat': 4, 'nbformat_minor': 2} opts = {'kernel_name': 'python', 'resources': {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}}} resources = {'metadata': {'path': '/builddir/build/BUILD/nbclient-0.9.0/tests/files'}} /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:160: in wrapped return loop.run_until_complete(inner) args = (,) coro = inner = kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> name = 'MainThread' /usr/lib/python3.12/site-packages/nest_asyncio.py:98: in run_until_complete return f.result() f = exception=RuntimeError("Kernel didn't respond in 60 seconds")> future = manage_run = .manage_run at 0xffffff82e5a7a0> self = <_UnixSelectorEventLoop running=False closed=False debug=False> /usr/lib64/python3.12/asyncio/futures.py:203: in result raise self._exception.with_traceback(self._exception_tb) self = exception=RuntimeError("Kernel didn't respond in 60 seconds")> /usr/lib64/python3.12/asyncio/tasks.py:304: in __step_run_and_handle_result result = coro.send(None) __class__ = coro = self = None nbclient/client.py:693: in async_execute async with self.async_setup_kernel(**kwargs): kwargs = {} reset_kc = False self = /usr/lib64/python3.12/contextlib.py:204: in __aenter__ return await anext(self.gen) self = nbclient/client.py:651: in async_setup_kernel await self.async_start_new_kernel_client() cleanup_kc = True kwargs = {} loop = <_UnixSelectorEventLoop running=False closed=False debug=False> on_signal = .on_signal at 0xffffff6bc1f7e0> self = nbclient/client.py:566: in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) self = /usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py:172: in ensure_async result = await obj obj = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = timeout = 60 async def _async_wait_for_ready(self, timeout: t.Optional[float] = None) -> None: """Waits for a response when a client is blocked  - Sets future time for timeout - Blocks on shell channel until a message is received - Exit if the kernel has died - If client times out before receiving a message from the kernel, send RuntimeError - Flush the IOPub channel """ if timeout is None: timeout = float("inf") abs_timeout = time.time() + timeout  from .manager import KernelManager  if not isinstance(self.parent, KernelManager): # This Client was not created by a KernelManager, # so wait for kernel to become responsive to heartbeats # before checking for kernel_info reply while not await ensure_async(self.is_alive()): if time.time() > abs_timeout: raise RuntimeError( "Kernel didn't respond to heartbeats in %d seconds and timed out" % timeout ) await asyncio.sleep(0.2)  # Wait for kernel info reply on shell channel while True: self.kernel_info() try: msg = await self.shell_channel.get_msg(timeout=1) except Empty: pass else: if msg["msg_type"] == "kernel_info_reply": # Checking that IOPub is connected. If it is not connected, start over. try: await self.iopub_channel.get_msg(timeout=0.2) except Empty: pass else: self._handle_kernel_info_reply(msg) break  if not await ensure_async(self.is_alive()): raise RuntimeError("Kernel died before replying to kernel_info")  # Check if current time is ready check time plus timeout if time.time() > abs_timeout: > raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) E RuntimeError: Kernel didn't respond in 60 seconds KernelManager = abs_timeout = 1709563224.6430771 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 27, in from .shortcuts import PromptSession, print_formatted_text, prompt File "/usr/lib/python3.12/site-packages/prompt_toolkit/shortcuts/__init__.py", line 3, in from .dialogs import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/shortcuts/dialogs.py", line 22, in from prompt_toolkit.widgets import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/widgets/__init__.py", line 11, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/widgets/base.py", line 80, in from .toolbars import SearchToolbar File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 929, in _load_unlocked File "", line 990, in exec_module File "", line 1123, in get_code File "", line 752, in _compile_bytecode KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 4ce0d77c-ebfc-41f0-907a-d84a7cfe0374: Kernel didn't respond in 60 seconds =============================== warnings summary =============================== ../../../../usr/lib/python3.12/site-packages/jupyter_client/connect.py:27 /usr/lib/python3.12/site-packages/jupyter_client/connect.py:27: DeprecationWarning: Jupyter is migrating its paths to use standard platformdirs given by the platformdirs library. To remove this warning and see the appropriate new directories, set the environment variable `JUPYTER_PLATFORM_DIRS=1` and then run `jupyter --paths`. The use of platformdirs will be the default in `jupyter_core` v6 from jupyter_core.paths import jupyter_data_dir tests/test_client.py: 52 warnings /usr/lib/python3.12/site-packages/jupyter_client/session.py:203: 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). return datetime.utcnow().replace(tzinfo=utc) tests/test_client.py::test_start_new_kernel_history_file_setting /usr/lib64/python3.12/subprocess.py:1127: ResourceWarning: subprocess 3775060 is still running _warn("subprocess %s is still running" % self.pid, Enable tracemalloc to get traceback where the object was allocated. See https://docs.pytest.org/en/stable/how-to/capture-warnings.html#resource-warnings for more info. tests/test_client.py::TestExecute::test_allow_errors /usr/lib64/python3.12/subprocess.py:1127: ResourceWarning: subprocess 3775063 is still running _warn("subprocess %s is still running" % self.pid, Enable tracemalloc to get traceback where the object was allocated. See https://docs.pytest.org/en/stable/how-to/capture-warnings.html#resource-warnings for more info. tests/test_client.py: 38 warnings /builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py:57: 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). return datetime.datetime.utcnow().isoformat() + "Z" tests/test_client.py::TestRunCell::test_cell_hooks tests/test_client.py::TestRunCell::test_deadline_iopub tests/test_client.py::TestRunCell::test_display_data_message tests/test_client.py::TestRunCell::test_error_message_only tests/test_client.py::TestRunCell::test_non_code_cell tests/test_client.py::TestRunCell::test_widget_comm_buffer_messages tests/test_util.py::test_run_hook_sync /usr/lib64/python3.12/asyncio/base_events.py:703: ResourceWarning: unclosed event loop <_UnixSelectorEventLoop running=False closed=False debug=False> _warn(f"unclosed event loop {self!r}", ResourceWarning, source=self) Enable tracemalloc to get traceback where the object was allocated. See https://docs.pytest.org/en/stable/how-to/capture-warnings.html#resource-warnings for more info. -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html ===Flaky Test Report=== test_parallel_notebooks passed 1 out of the required 1 times. Success! test_many_parallel_notebooks failed (1 runs remaining out of 2). Exception in thread Thread-18 (run_notebook) Traceback (most recent call last): File "/usr/lib64/python3.12/threading.py", line 1052, in _bootstrap_inner self.run() File "/usr/lib64/python3.12/threading.py", line 989, in run self._target(*self._args, **self._kwargs) File "/builddir/build/BUILD/nbclient-0.9.0/tests/test_client.py", line 138, in run_notebook output_nb = executor.execute() ^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/base_events.py", line 664, in run_until_complete return future.result() ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 693, in async_execute async with self.async_setup_kernel(**kwargs): File "/usr/lib64/python3.12/contextlib.py", line 204, in __aenter__ return await anext(self.gen) ^^^^^^^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 651, in async_setup_kernel await self.async_start_new_kernel_client() File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 566, in async_start_new_kernel_client await ensure_async(self.kc.wait_for_ready(timeout=self.startup_timeout)) File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 172, in ensure_async result = await obj ^^^^^^^^^ File "/usr/lib/python3.12/site-packages/jupyter_client/client.py", line 206, in _async_wait_for_ready raise RuntimeError("Kernel didn't respond in %d seconds" % timeout) RuntimeError: Kernel didn't respond in 60 seconds [, , , , , ] test_many_parallel_notebooks failed; it passed 0 out of the required 1 times. Kernel didn't respond in 60 seconds [, , , , , , , , , ] test_async_parallel_notebooks failed (1 runs remaining out of 2). Kernel didn't respond in 60 seconds [, , , , , , , , , , , ] test_async_parallel_notebooks failed; it passed 0 out of the required 1 times. Kernel didn't respond in 60 seconds [, , , , , , , , , , , ] test_many_async_parallel_notebooks failed (1 runs remaining out of 2). Kernel didn't respond in 60 seconds [, , , , , , , , , ] test_many_async_parallel_notebooks failed; it passed 0 out of the required 1 times. Kernel didn't respond in 60 seconds [, , , , , , , , , ] test_kernel_death_after_timeout failed (1 runs remaining out of 2). Kernel didn't respond in 60 seconds [, , , , , , , , , , ] test_kernel_death_after_timeout failed; it passed 0 out of the required 1 times. Kernel didn't respond in 60 seconds [, , , , , , , , , , ] ===End Flaky Test Report=== ============================= slowest 10 durations ============================= 84.61s call tests/test_client.py::test_run_all_notebooks[Other Comms.ipynb-opts0] 74.67s call tests/test_client.py::test_run_all_notebooks[Skip Exceptions with Cell Tags.ipynb-opts8] 73.37s call tests/test_client.py::test_synchronous_setup_kernel 72.60s call tests/test_client.py::test_run_all_notebooks[Clear Output.ipynb-opts1] 71.78s call tests/test_client.py::test_run_all_notebooks[Factorials.ipynb-opts3] 70.63s call tests/test_client.py::test_async_parallel_notebooks 70.37s call tests/test_client.py::test_run_all_notebooks[UnicodePy3.ipynb-opts13] 69.21s call tests/test_client.py::TestExecute::test_error_async_execution_hook 68.24s call tests/test_client.py::test_run_all_notebooks[Interrupt.ipynb-opts6] 68.20s call tests/test_client.py::test_run_all_notebooks[Skip Exceptions.ipynb-opts9] =========================== short test summary info ============================ FAILED tests/test_client.py::test_run_all_notebooks[Other Comms.ipynb-opts0] - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_run_all_notebooks[Clear Output.ipynb-opts1] - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_run_all_notebooks[Empty Cell.ipynb-opts2] - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_run_all_notebooks[Factorials.ipynb-opts3] - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_run_all_notebooks[HelloWorld.ipynb-opts4] - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_run_all_notebooks[Inline Image.ipynb-opts5] - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_run_all_notebooks[Interrupt.ipynb-opts6] - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_run_all_notebooks[JupyterWidgets.ipynb-opts7] - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_run_all_notebooks[Skip Exceptions with Cell Tags.ipynb-opts8] - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_run_all_notebooks[Skip Exceptions.ipynb-opts9] - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_run_all_notebooks[Skip Execution with Cell Tag.ipynb-opts10] - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_run_all_notebooks[SVG.ipynb-opts11] - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_run_all_notebooks[Unicode.ipynb-opts12] - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_run_all_notebooks[UnicodePy3.ipynb-opts13] - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_run_all_notebooks[update-display-id.ipynb-opts14] - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_run_all_notebooks[Check History in Memory.ipynb-opts15] - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_many_parallel_notebooks - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_async_parallel_notebooks - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_many_async_parallel_notebooks - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_execution_timing - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_synchronous_setup_kernel - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::test_startnewkernel_with_kernelmanager - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_allow_errors - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_async_execution_hook - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_cleanup_kernel_client - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_custom_kernel_manager - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_disable_stdin - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_empty_kernel_name - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_empty_path - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_error_async_execution_hook - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_error_execution_hook_error - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_error_notebook_hook - AssertionError: Expected 'mock' to have been called once. Called 0 times. FAILED tests/test_client.py::TestExecute::test_execute_function - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_execution_hook - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_force_raise_errors - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_kernel_death_after_timeout - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_populate_language_info - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_process_message_wrapper - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_reset_kernel_client - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_sync_kernel_manager - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_timeout - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_timeout_func - RuntimeError: Kernel didn't respond in 60 seconds FAILED tests/test_client.py::TestExecute::test_widgets - RuntimeError: Kernel didn't respond in 60 seconds =========== 43 failed, 51 passed, 100 warnings in 4516.77s (1:15:16) =========== Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of .WrappedPreProc object at 0xffffff6bc9d5b0>> Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: Exception ignored in atexit callback: .wrapped of > Traceback (most recent call last): File "/usr/lib/python3.12/site-packages/jupyter_core/utils/__init__.py", line 160, in wrapped return loop.run_until_complete(inner) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/nest_asyncio.py", line 98, in run_until_complete return f.result() ^^^^^^^^^^ File "/usr/lib64/python3.12/asyncio/futures.py", line 203, in result raise self._exception.with_traceback(self._exception_tb) File "/usr/lib64/python3.12/asyncio/tasks.py", line 304, in __step_run_and_handle_result result = coro.send(None) ^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/nbclient-0.9.0/nbclient/client.py", line 504, in _async_cleanup_kernel assert self.km is not None AssertionError: error: Bad exit status from /var/tmp/rpm-tmp.9kG3DL (%check) RPM build errors: Bad exit status from /var/tmp/rpm-tmp.9kG3DL (%check) Child return code was: 1 EXCEPTION: [Error('Command failed: \n # bash --login -c /usr/bin/rpmbuild -ba --noprep --noclean --target noarch --nodeps /builddir/build/SPECS/python-nbclient.spec\n', 1)] Traceback (most recent call last): File "/usr/lib/python3.11/site-packages/mockbuild/trace_decorator.py", line 93, in trace result = func(*args, **kw) ^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/mockbuild/util.py", line 597, in do_with_status raise exception.Error("Command failed: \n # %s\n%s" % (command, output), child.returncode) mockbuild.exception.Error: Command failed: # bash --login -c /usr/bin/rpmbuild -ba --noprep --noclean --target noarch --nodeps /builddir/build/SPECS/python-nbclient.spec