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-2412846-60563/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=1708128000 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-2412846-60563/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=1708128000 Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.WRs8Sq + 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.pB21AW + 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-2412846-60563/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=1708128000 Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.ij53nw + 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.40fOiq + 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-2412846-60563/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=1708128000 Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.skiyNr + 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.JVR9ww + 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-2412846-60563/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=1708128000 Executing(%generate_buildrequires): /bin/sh -e /var/tmp/rpm-tmp.hUotIM + 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.lgghQJ + 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=2c66b8c443fd0e02515dfcf3724bf8097014be0507a51881ce28b5906a1f81d4 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.SiI2Rn + 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 ++ ls /builddir/build/BUILD/nbclient-0.9.0/pyproject-wheeldir/nbclient-0.9.0-py3-none-any.whl ++ sed -E 's/([^-]+)-([^-]+)-.+\.whl/\1==\2/' + 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.Hj4ecP + 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 0xffffff7c627880> 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 = 1708207135.8708448 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 22, in from .style_transformation import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/styles/style_transformation.py", line 132, in class AdjustBrightnessStyleTransformation(StyleTransformation): File "", line 105, in __new__ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 950af314-ae5b-4a52-971c-d2b27e5770cf: 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 0xffffff7c52ee80> 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 = 1708207257.093541 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 26, in from .pygments import PygmentsTokens 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 0774db07-5d56-4298-83ca-c6d538c2165d: 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 0xffffff7c52fec0> 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 = 1708207344.0606372 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 6a2e5d0b-8f33-4aa3-9910-90b4d579c0d9: 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 0xffffff7c530b80> 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 = 1708207435.0528584 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 53, in from prompt_toolkit.key_binding.bindings.page_navigation 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 1498, in _get_spec File "", line 1601, in find_spec File "", line 1644, in _fill_cache KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 5373ef91-6dac-489e-8108-ca87770ce0b4: 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 0xffffff7c530c20> 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 = 1708207522.3054342 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 3c427507-f3c0-46f9-954d-54cecb71057f: 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 0xffffff7c530860> 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 = 1708207612.7036428 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 23, in class CursorShape(Enum): File "/usr/lib64/python3.12/enum.py", line 546, in __new__ classdict = dict(classdict.items()) ^^^^^^^^^^^^^^^^^^^^^^^ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 2d8bd252-c01a-43fe-9683-c0f6bc3d13bc: 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 0xffffff7c5304a0> 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 = 1708207701.6948926 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/lib64/python3.12/xml/dom' 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 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 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 1459, in _path_hooks File "", line 75, in __init__ File "", line 147, in _path_stat KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel de6b3bd9-f74b-45b1-89df-4c6d932f650f: 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 0xffffff7c531ee0> 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 = 1708207789.445593 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 "", 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 754, in _compile_bytecode File "", line 491, in _verbose_message KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel ba718323-af71-4bfa-8f6d-e6ac2335b878: 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 0xffffff7c533e20> 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 = 1708207881.4524977 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 20ea59cf-5307-419d-b3f2-b8c89599d75d: 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 0xffffff7c533600> 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 = 1708207968.666756 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 "/usr/lib/python3.12/site-packages/prompt_toolkit/lexers/__init__.py", line 8, in from .pygments import PygmentsLexer, RegexSync, SyncFromStart, SyntaxSync 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 f067e6bd-67cd-4d01-8a32-b505458e909a: 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 0xffffff7c533740> 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 = 1708208057.4236453 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 "", 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 228e96ef-ed5e-4d7f-991f-48834ba27853: 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 0xffffff7c5337e0> 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 = 1708208148.872174 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 72, in from IPython.core.formatters import DisplayFormatter File "/usr/lib/python3.12/site-packages/IPython/core/formatters.py", line 814, in class JSONFormatter(BaseFormatter): 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 1ea7f133-fc3f-4ac3-b7eb-24f77aee10f0: 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 0xffffff79a88cc0> 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 = 1708208235.0545719 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 286, in class InteractiveShell(SingletonConfigurable): File "/usr/lib/python3.12/site-packages/IPython/core/interactiveshell.py", line 760, in InteractiveShell @observe('colors') ^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/traitlets/traitlets.py", line 1126, in observe return ObserveHandler(names, type=type) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/traitlets/traitlets.py", line 1271, in __init__ def __init__(self, names: t.Any, type: t.Any) -> None: KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 8d16f609-77a1-4920-aef1-032daf373689: 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 0xffffff79a8a020> 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 = 1708208325.0608604 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 72, in from IPython.core.formatters import DisplayFormatter File "/usr/lib/python3.12/site-packages/IPython/core/formatters.py", line 779, in class JPEGFormatter(BaseFormatter): 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 1047, in setup_class if name in c.__dict__.get("_trait_default_generators", {}): ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel cc798de3-8083-483a-9ba8-3d1288f15952: 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 0xffffff79a89da0> 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 = 1708208415.1611457 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 84, in from IPython.utils import PyColorize, io, openpy, py3compat File "/usr/lib/python3.12/site-packages/IPython/utils/io.py", line 19, in from .capture import CapturedIO, capture_output File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 940, in _load_unlocked KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 15a905d2-0e73-4e98-98ed-d95615f63180: 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 0xffffff79a8aa20> 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 = 1708208504.064501 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 22, in from .style_transformation import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/styles/style_transformation.py", line 15, in from colorsys import hls_to_rgb, rgb_to_hls 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 2c66567d-0509-4a24-b054-c76a70b0fa84: Kernel didn't respond in 60 seconds _________________________ test_many_parallel_notebooks _________________________ capfd = <_pytest.capture.CaptureFixture object at 0xffffff7c387fe0> @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 0xffffff7c387fe0> 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 0xffffff79a8bc40> 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 = 1708208688.0350986 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 "", 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 431e0064-ef7b-4522-9b05-db1e8c5b5307: Kernel didn't respond in 60 seconds ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 7e308de8-e031-45a9-bbb3-a2cbf0021a1f: Kernel didn't respond in 60 seconds ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel deba2716-c879-464e-b071-2bfe384e55e2: 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 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 13, in from .filters import vi_mode File "/usr/lib/python3.12/site-packages/prompt_toolkit/filters/__init__.py", line 21, in from .app import * File "/usr/lib/python3.12/site-packages/prompt_toolkit/filters/app.py", line 12, in from .base import Condition 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 8541cb5d-e5ec-4654-9739-659b29d807ca: Kernel didn't respond in 60 seconds ________________________ test_async_parallel_notebooks _________________________ capfd = <_pytest.capture.CaptureFixture object at 0xffffff7c387650> 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 0xffffff7c387650> 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 0xffffff79a8b9c0> 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 0xffffff79a08150> runner = /usr/lib64/python3.12/asyncio/runners.py:118: in run return self._loop.run_until_complete(task) context = <_contextvars.Context object at 0xffffff79598940> coro = .run_tasks at 0xffffff79a08150> 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 = 'A'\n" "other_notebook = 'B'\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 A.ipynb' mode='r' encoding='UTF-8'> filename = '/builddir/build/BUILD/nbclient-0.9.0/tests/files/Parallel Execute A.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 = 'A'\n" "other_notebook = 'B'\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 0xffffff79a8b7e0> 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 = 1708208874.7366734 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 Traceback (most recent call last): File "", line 198, in _run_module_as_main from .application import Application File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in 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 from ipykernel import kernelapp as app 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/ipykernel/kernelapp.py", line 19, 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 ( from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/containers.py", line 34, in File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .controls import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/layout/controls.py", line 26, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from prompt_toolkit.lexers import Lexer, SimpleLexer File "/usr/lib/python3.12/site-packages/prompt_toolkit/lexers/__init__.py", line 7, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from .base import DynamicLexer, Lexer, SimpleLexer File "", line 1354, in _find_and_load File "", line 1316, in _find_and_load_unlocked from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "", line 1256, in _find_spec File "", line 1524, in find_spec File "", line 1498, in _get_spec File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in File "", line 1601, in find_spec File "", line 1640, in _fill_cache KeyboardInterrupt 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 10, in from prompt_toolkit.data_structures import Size File "", line 1351, in _find_and_load File "", line 418, in __enter__ File "", line 311, in acquire File "", line 170, in __enter__ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel b609c400-b0aa-4ad6-aee5-256d1ef679e2: Kernel didn't respond in 60 seconds ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 7f434c3b-e506-4345-aec2-9a62713de9b5: 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 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 13, in from .filters import vi_mode File "/usr/lib/python3.12/site-packages/prompt_toolkit/filters/__init__.py", line 21, in from .app import * File "/usr/lib/python3.12/site-packages/prompt_toolkit/filters/app.py", line 10, in from prompt_toolkit.enums import EditingMode 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 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 84, in from IPython.utils import PyColorize, io, openpy, py3compat 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 02c9c639-79bf-45c7-9219-bb9b183a88f9: Kernel didn't respond in 60 seconds ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 32ee5296-82e2-4446-bb9a-a686601c8e1f: Kernel didn't respond in 60 seconds ______________________ test_many_async_parallel_notebooks ______________________ capfd = <_pytest.capture.CaptureFixture object at 0xffffff7c50e270> @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 0xffffff7c50e270> 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 0xffffff79a88540> 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 = 1708209054.5197334 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 5, in from .defaults import create_output File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/defaults.py", line 12, in from .base import DummyOutput, Output File "", line 645, in parent KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel fbb5f479-77a4-4b99-bf0f-4540d251fb4d: 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 14, in from IPython.core.magic import Magics, magics_class, line_magic File "/usr/lib/python3.12/site-packages/IPython/core/magic.py", line 20, in from . import oinspect File "/usr/lib/python3.12/site-packages/IPython/core/oinspect.py", line 37, in from IPython.core import page File "/usr/lib/python3.12/site-packages/IPython/core/page.py", line 28, in from IPython.display import display File "/usr/lib/python3.12/site-packages/IPython/display.py", line 16, in from IPython.core.display 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 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 47822023-ab30-4b14-8a31-ea1302b7bb2e: 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 0xffffff79a88f40> 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 = 1708209143.3127558 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 45, in class Event(Generic[_Sender]): File "/usr/lib64/python3.12/typing.py", line 1072, in _generic_init_subclass def _generic_init_subclass(cls, *args, **kwargs): KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel bee963c4-a14c-45de-ba3f-d07d40dd862e: 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 = 1708209241.486159 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/application' 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 "", 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 1459, in _path_hooks File "", line 1683, in path_hook_for_FileFinder File "", line 168, in _path_isdir File "", line 153, in _path_is_mode_type File "", line 147, in _path_stat KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel f88da9b9-c6b5-4169-bf17-48495eabc3c2: 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 0xffffff79a9e520> 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 0xffffff79a9e520> 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 = 1708209329.2371354 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 "/usr/lib/python3.12/site-packages/prompt_toolkit/output/color_depth.py", line 11, in class ColorDepth(str, Enum): KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel ae7063c2-0688-4822-b2d0-61fc3eda0b4b: 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 0xffffff79a9e520> 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 0xffffff79a9c040> 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 = 1708209424.2489707 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 15, in from .autocall import IPyAutocall 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 678d2870-a5d9-46a5-8441-d3194520428b: 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 0xffffff79a9e520> 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 0xffffff798fa840> 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 = 1708209519.5352294 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 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 17, in app.launch_new_instance() File "/usr/lib/python3.12/site-packages/traitlets/config/application.py", line 1052, in launch_instance app.initialize(argv) File "/usr/lib/python3.12/site-packages/traitlets/config/application.py", line 117, in inner return method(app, *args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 689, in initialize self.init_sockets() File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 328, in init_sockets self.shell_port = self._bind_socket(self.shell_socket, self.shell_port) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 252, in _bind_socket return self._try_bind_socket(s, port) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 228, in _try_bind_socket s.bind("tcp://%s:%i" % (self.ip, port)) File "/usr/lib64/python3.12/site-packages/zmq/sugar/socket.py", line 302, in bind super().bind(addr) File "zmq/backend/cython/socket.pyx", line 564, in zmq.backend.cython.socket.Socket.bind File "zmq/backend/cython/checkrc.pxd", line 28, in zmq.backend.cython.checkrc._check_rc zmq.error.ZMQError: Address already in use (addr='tcp://127.0.0.1:45425') 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 ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 210af22b-291d-45a5-97c6-c70cfac9d4b5: 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 0xffffff79a9e520> 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 0xffffff798fad40> 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 = 1708209609.937164 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 "", 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 fa6cf972-93aa-4b07-a3e6-518c123d8762: 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 0xffffff79a9e520> 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 0xffffff798fb740> 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 = 1708209692.863098 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 "", 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 ------------------------------- 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 74e6262f-a25a-43b0-9038-516c66e4054f: 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 0xffffff79a9e520> 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 0xffffff798fb4c0> 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 = 1708209780.3068607 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 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 1296ed3c-6cef-402c-abe7-8c435eec16c4: 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 0xffffff79a9e520> 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 0xffffff7c388ae0> 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 = 1708209867.675992 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 23, in class CursorShape(Enum): File "/usr/lib/python3.12/site-packages/prompt_toolkit/cursor_shapes.py", line 23, in CursorShape class CursorShape(Enum): File "/usr/lib64/python3.12/enum.py", line 383, in __setitem__ def __setitem__(self, key, value): KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel f3c8ebab-e467-4847-8899-cb1585778301: 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 0xffffff79a9e520> 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 0xffffff7c388a40> 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 = 1708209956.7259676 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): 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 1021, in setup_class super().setup_class(classdict) File "/usr/lib/python3.12/site-packages/traitlets/traitlets.py", line 1004, in setup_class for _, v in getmembers(cls): ^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/traitlets/traitlets.py", line 242, in getmembers value = getattr(object, key) ^^^^^^^^^^^^^^^^^^^^ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 618a63b7-ed2e-4270-8fee-e8e6ff60a957: 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 0xffffff79a9e520> 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 0xffffff7c388f40> 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 = 1708210052.6273887 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 13, in from IPython.core import magic_arguments File "/usr/lib/python3.12/site-packages/IPython/core/magic_arguments.py", line 92, in from IPython.utils.text import dedent File "/usr/lib/python3.12/site-packages/IPython/utils/text.py", line 556, in class DollarFormatter(FullEvalFormatter): File "/usr/lib/python3.12/site-packages/IPython/utils/text.py", line 575, in DollarFormatter _dollar_pattern_ignore_single_quote = re.compile(r"(.*?)\$(\$?[\w\.]+)(?=([^']*'[^']*')*[^']*$)") ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 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 768, in _parse p = _parse_sub(source, state, verbose, nested + 1) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 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 855, in _parse p = _parse_sub(source, state, sub_verbose, nested + 1) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 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 675, in _parse if subpattern: ^^^^^^^^^^ File "/usr/lib64/python3.12/re/_parser.py", line 160, in __len__ def __len__(self): KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 265437d2-caf7-4b69-93fa-7a1e1e7d468b: 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 0xffffff79a9e520> 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 0xffffff7c38a200> 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 = 1708210149.4914334 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 20, in from . import oinspect File "/usr/lib/python3.12/site-packages/IPython/core/oinspect.py", line 37, in from IPython.core import page File "/usr/lib/python3.12/site-packages/IPython/core/page.py", line 30, in from IPython.utils.data import chop 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 317bf6ef-b3ef-4c7c-8372-255d0d409f75: 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 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/lib/python3.12/site-packages/prompt_toolkit/keys.py", line 62, in Keys Control0 = "c-0" ^^^^^^^^ File "/usr/lib64/python3.12/enum.py", line 431, in __setitem__ elif _is_dunder(key): ^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/enum.py", line 48, in _is_dunder def _is_dunder(name): KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 604927db-f587-4568-ac4e-44fa41c793f0: 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 0xffffff79a9e520> 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 0xffffff7c38ac00> 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 = 1708210313.101555 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/lib/python3.12/site-packages/prompt_toolkit/keys.py", line 181, in Keys ScrollDown = "" ^^^^^^^^^^ File "/usr/lib64/python3.12/enum.py", line 442, in __setitem__ elif _is_descriptor(value): ^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/enum.py", line 38, in _is_descriptor def _is_descriptor(obj): KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel fef87df7-fea5-4d59-a68c-c8f9b7e282ac: 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 0xffffff79a9e520> 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 0xffffff7c38b880> 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 = 1708210400.522823 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 130, in class HistoryAccessor(HistoryAccessorBase): 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 1030, in setup_class value = getattr(cls, name) ^^^^^^^^^^^^^^^^^^ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel f645f4f0-dc5f-46f0-8ea6-777c8ad8d81e: Kernel didn't respond in 60 seconds _____________________ TestExecute.test_force_raise_errors ______________________ self = 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 0xffffff79a9e520> 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 0xffffff7c38bd80> 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 = 1708210486.2863982 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 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 4ef64059-7bdd-4916-a79d-a1a6cb6dd6ad: 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 0xffffff79a9e520> 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 0xffffff79730fe0> 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 = 1708210657.2793581 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 "", 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 481, in cache_from_source KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 9d5372b5-54b3-49b8-8c75-8ddbdcfa8de3: 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 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 "", 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 c6f14bb3-321e-4df9-b16f-2a804f16aafe: 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 0xffffff79a9e520> 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 0xffffff79731580> 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 = 1708210810.3548017 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 "", 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 e5e50729-6764-4292-8ef9-c0a6296f9f7f: 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 0xffffff7c35c530> 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 0xffffff7c35c530>,) 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 0xffffff79a9e520> 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 0xffffff7c35c530> /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 0xffffff797313a0> self = .WrappedPreProc object at 0xffffff7c35c530> 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 0xffffff7c35c530> /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 = 1708210893.0712397 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 "", 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 3febc99b-072d-4951-8f57-9c4808c762e5: 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 0xffffff79a9e520> 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 0xffffff79731da0> 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 = 1708210976.3023148 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 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 211aee71-ed49-4bb7-ba8f-b2fa1b02b557: 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 0xffffff79a9e520> 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 0xffffff79731f80> 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 0xffffff79a9e520> 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 = 1708211060.460835 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 21, in from parso.python.token import PythonTokenTypes File "/usr/lib/python3.12/site-packages/parso/python/token.py", line 18, in class PythonTokenTypes(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 254, in __set_name__ delattr(enum_class, member_name) KeyboardInterrupt Error calling __set_name__ on '_proto_member' instance 'ERRORTOKEN' in 'PythonTokenTypes' ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 793b7929-a3f9-454d-8273-3fbc81a67b5e: 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 0xffffff79a9e520> 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 0xffffff79730860> 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 = 1708211145.336657 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 75, in from prompt_toolkit.renderer import Renderer, print_formatted_text File "/usr/lib/python3.12/site-packages/prompt_toolkit/renderer.py", line 269, in class _StyleStringToAttrsCache(Dict[str, Attrs]): File "/usr/lib64/python3.12/typing.py", line 1073, in _generic_init_subclass super(Generic, cls).__init_subclass__(*args, **kwargs) KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 23e7dff9-1b6f-407c-b116-f9e48ae8ab82: 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 0xffffff79733380> 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 0xffffff79733380>} 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 0xffffff79a9e520> 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 0xffffff797331a0> 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 = 1708211234.5410678 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 "", 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 2ccfa2cf-7c4a-4dd0-9519-c1df38f910b6: 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 0xffffff79a9e520> 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 0xffffff79733920> 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 = 1708211322.7780352 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 51, in from prompt_toolkit.input.base import Input 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 634b8a78-f308-4368-8459-f2cd919fe449: 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 2970150 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 2970153 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 ============================= 83.58s call tests/test_client.py::test_run_all_notebooks[Other Comms.ipynb-opts0] 75.03s call tests/test_client.py::test_synchronous_setup_kernel 73.50s call tests/test_client.py::test_run_all_notebooks[Clear Output.ipynb-opts1] 72.39s call tests/test_client.py::test_run_all_notebooks[Skip Exceptions with Cell Tags.ipynb-opts8] 70.94s call tests/test_client.py::test_run_all_notebooks[Factorials.ipynb-opts3] 70.73s call tests/test_client.py::test_async_parallel_notebooks 69.51s call tests/test_client.py::TestExecute::test_allow_errors 69.23s call tests/test_client.py::TestExecute::test_error_async_execution_hook 69.17s call tests/test_client.py::TestExecute::test_error_execution_hook_error 68.97s call tests/test_client.py::test_run_all_notebooks[HelloWorld.ipynb-opts4] =========================== 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 4644.45s (1:17:24) =========== 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 0xffffff7c35c530>> 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.Hj4ecP (%check) Bad exit status from /var/tmp/rpm-tmp.Hj4ecP (%check) RPM build errors: 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