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-2378237-60442/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=1707264000 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-2378237-60442/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=1707264000 Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.8FgRBP + 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.t1fAjC + 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-2378237-60442/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=1707264000 Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.owLnZw + 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.Cx2FYh + 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-2378237-60442/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=1707264000 Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.if3Gt8 + 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.siBYGb + 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-2378237-60442/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=1707264000 Executing(%generate_buildrequires): /bin/sh -e /var/tmp/rpm-tmp.JLCyF2 + 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.XhfQFD + 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=ef877d5314454a373bb9b12929b7900b9078b98516585924091af792bcee0c4d 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.UHtaQv + 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.UBkL5B + 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 0xffffff8b077880> 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 = 1707335765.8220854 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 53, in from pygments.lexers import PythonLexer File "", line 1406, in _handle_fromlist File "/usr/lib/python3.12/site-packages/pygments/lexers/__init__.py", line 350, in __getattr__ _load_lexers(info[0]) File "/usr/lib/python3.12/site-packages/pygments/lexers/__init__.py", line 45, in _load_lexers mod = __import__(module_name, None, None, ['__all__']) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/pygments/lexers/python.py", line 14, in from pygments.lexer import DelegatingLexer, Lexer, RegexLexer, include, \ File "/usr/lib/python3.12/site-packages/pygments/lexer.py", line 16, in from pygments.filters import get_filter_by_name 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 2a979a7d-19f7-43e9-8d79-7897b8f5d8e5: 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 0xffffff8b12ee80> 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 = 1707335899.37475 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 53, in from .core.application import Application File "/usr/lib/python3.12/site-packages/IPython/core/application.py", line 26, in from IPython.core import release, crashhandler File "/usr/lib/python3.12/site-packages/IPython/core/crashhandler.py", line 27, in from IPython.core import ultratb File "/usr/lib/python3.12/site-packages/IPython/core/ultratb.py", line 104, in import stack_data File "/usr/lib/python3.12/site-packages/stack_data/__init__.py", line 1, in from .core import Source, FrameInfo, markers_from_ranges, Options, LINE_GAP, Line, Variable, RangeInLine, \ File "/usr/lib/python3.12/site-packages/stack_data/core.py", line 18, in from pure_eval import Evaluator, is_expression_interesting File "/usr/lib/python3.12/site-packages/pure_eval/__init__.py", line 1, in from .core import Evaluator, CannotEval, group_expressions, is_expression_interesting File "/usr/lib/python3.12/site-packages/pure_eval/core.py", line 9, in from pure_eval.my_getattr_static import getattr_static File "/usr/lib/python3.12/site-packages/pure_eval/my_getattr_static.py", line 3, in from pure_eval.utils import of_type, CannotEval File "/usr/lib/python3.12/site-packages/pure_eval/utils.py", line 4, in from fractions import Fraction File "/usr/lib64/python3.12/fractions.py", line 144, in _FLOAT_FORMAT_SPECIFICATION_MATCHER = re.compile(r""" ^^^^^^^^^^^^^^^ 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 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 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, KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel f5bb3ff7-3d24-4e95-b9e7-157d3f4498db: 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 0xffffff8b12fec0> 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 = 1707335996.159086 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 15, in from IPython.core.interactiveshell import DummyMod, InteractiveShell File "/usr/lib/python3.12/site-packages/IPython/core/interactiveshell.py", line 73, in from IPython.core.history import HistoryManager File "/usr/lib/python3.12/site-packages/IPython/core/history.py", line 11, in import sqlite3 File "/usr/lib64/python3.12/sqlite3/__init__.py", line 57, in from sqlite3.dbapi2 import * File "/usr/lib64/python3.12/sqlite3/dbapi2.py", line 27, in from _sqlite3 import * KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 3deb4fb3-b7f4-442f-b658-c36309f9aa03: 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 0xffffff8af84b80> 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 = 1707336092.8201857 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 21, in from .application.run_in_terminal import run_in_terminal File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/run_in_terminal.py", line 10, in from prompt_toolkit.eventloop import run_in_executor_with_context File "/usr/lib/python3.12/site-packages/prompt_toolkit/eventloop/__init__.py", line 3, in from .async_generator import aclosing, generator_to_async_generator File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 915, in _load_unlocked File "", line 819, in module_from_spec File "", line 798, in _init_module_attrs File "", line 638, in cached File "", line 613, in _get_cached File "", line 518, in cache_from_source KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 804c7768-f346-4a27-b1c9-9edecdcd05cb: 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 0xffffff8af84c20> 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 = 1707336182.8058949 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 22, in from .auto_suggest import AutoSuggest, Suggestion File "/usr/lib/python3.12/site-packages/prompt_toolkit/auto_suggest.py", line 21, in from .document import Document File "/usr/lib/python3.12/site-packages/prompt_toolkit/document.py", line 27, in _FIND_CURRENT_WORD_INCLUDE_TRAILING_WHITESPACE_RE = re.compile( ^^^^^^^^^^^ File "/usr/lib64/python3.12/re/__init__.py", line 228, in compile return _compile(pattern, flags) ^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/__init__.py", line 307, in _compile p = _compiler.compile(pattern, flags) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/_compiler.py", line 747, in compile code = _code(p, flags) ^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/_compiler.py", line 580, in _code _compile(code, p.data, flags) File "/usr/lib64/python3.12/re/_compiler.py", line 128, in _compile _compile(code, p, _combine_flags(flags, add_flags, del_flags)) File "/usr/lib64/python3.12/re/_compiler.py", line 128, in _compile _compile(code, p, _combine_flags(flags, add_flags, del_flags)) File "/usr/lib64/python3.12/re/_compiler.py", line 174, in _compile _compile(code, av, flags) File "/usr/lib64/python3.12/re/_compiler.py", line 111, in _compile _compile(code, av[2], flags) File "/usr/lib64/python3.12/re/_compiler.py", line 86, in _compile charset, hascased = _optimize_charset(av, iscased, tolower, fixes) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/_compiler.py", line 337, in _optimize_charset data = _mk_bitmap(charmap) ^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/_compiler.py", line 386, in _mk_bitmap return [_int(s[i - _CODEBITS: i], 2) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel b5a966d1-f322-49b3-be48-56db9eac1c74: 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 0xffffff8af85b20> 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 = 1707336268.787092 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 491, in class _Proxy(KeyBindingsBase): File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/key_bindings.py", line 510, in _Proxy @property ^^^^^^^^ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 0fe482cd-8b25-4313-8e0f-31930b61d2c2: 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 0xffffff8af849a0> 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 = 1707336360.5866272 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 3, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/base.py", line 11, in from prompt_toolkit.formatted_text import AnyFormattedText, StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/__init__.py", line 15, in from .ansi import ANSI File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/ansi.py", line 6, in from prompt_toolkit.output.vt100 import BG_ANSI_COLORS, FG_ANSI_COLORS File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/__init__.py", line 3, in from .base import DummyOutput, Output File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/base.py", line 9, in from prompt_toolkit.cursor_shapes import CursorShape File "/usr/lib/python3.12/site-packages/prompt_toolkit/cursor_shapes.py", line 8, in from prompt_toolkit.key_binding.vi_state import InputMode File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/__init__.py", line 10, in from .key_processor import KeyPress, KeyPressEvent File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/key_processor.py", line 19, in from prompt_toolkit.utils import Event File "/usr/lib/python3.12/site-packages/prompt_toolkit/utils.py", line 18, in from wcwidth import wcwidth File "/usr/lib/python3.12/site-packages/wcwidth/__init__.py", line 12, in from .wcwidth import ZERO_WIDTH # noqa ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/wcwidth/wcwidth.py", line 71, in from .table_wide import WIDE_EASTASIAN File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 915, in _load_unlocked File "", line 819, in module_from_spec File "", line 798, in _init_module_attrs File "", line 638, in cached File "", line 613, in _get_cached File "", line 507, in cache_from_source File "", line 134, in _path_split File "", line 134, in KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 44fa6b2a-0286-4e0f-b368-97070c1e2a4a: 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 0xffffff8af862a0> 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 = 1707336448.8085496 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 3, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/base.py", line 11, in from prompt_toolkit.formatted_text import AnyFormattedText, StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/__init__.py", line 15, in from .ansi import ANSI File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/ansi.py", line 6, in from prompt_toolkit.output.vt100 import BG_ANSI_COLORS, FG_ANSI_COLORS File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/__init__.py", line 3, in from .base import DummyOutput, Output File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/base.py", line 9, in from prompt_toolkit.cursor_shapes import CursorShape File "/usr/lib/python3.12/site-packages/prompt_toolkit/cursor_shapes.py", line 8, in from prompt_toolkit.key_binding.vi_state import InputMode File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/__init__.py", line 3, in from .key_bindings import ( File "", line 1354, in _find_and_load File "", line 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 1630, in find_spec File "", line 161, in _path_isfile 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 967c0761-0574-4b2a-ac0a-053fad7434ec: 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 0xffffff8af87e20> 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 = 1707336544.216091 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 "", 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 96044f16-575f-42b2-a219-c2549c8def2c: 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 0xffffff8af87420> 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 = 1707336643.2441509 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 KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel bf339f97-f3cc-42fe-9e04-fc79a4eb5f25: 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 0xffffff8af877e0> 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 = 1707336735.377067 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 53, in from .core.application import Application File "/usr/lib/python3.12/site-packages/IPython/core/application.py", line 26, in from IPython.core import release, crashhandler File "/usr/lib/python3.12/site-packages/IPython/core/crashhandler.py", line 27, in from IPython.core import ultratb File "/usr/lib/python3.12/site-packages/IPython/core/ultratb.py", line 1444, in class SyntaxTB(ListTB): File "/usr/lib/python3.12/site-packages/traitlets/traitlets.py", line 984, in __new__ return super().__new__(mcls, name, bases, classdict) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 855a6c93-8fb1-4611-be43-6588c5dde2a7: 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 0xffffff8b0202c0> 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 = 1707336827.6325083 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 53, in from pygments.lexers import PythonLexer File "/usr/lib/python3.12/site-packages/pygments/lexers/__init__.py", line 18, in from pygments.modeline import get_filetype_from_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 1075, in get_code File "", line 507, in cache_from_source File "", line 134, in _path_split KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 981d63e6-fc28-4222-a62c-5fa6899f7ba4: 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 0xffffff8b020d60> 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 = 1707336919.702516 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 53, in from pygments.lexers import PythonLexer File "", line 1406, in _handle_fromlist File "/usr/lib/python3.12/site-packages/pygments/lexers/__init__.py", line 350, in __getattr__ _load_lexers(info[0]) File "/usr/lib/python3.12/site-packages/pygments/lexers/__init__.py", line 45, in _load_lexers mod = __import__(module_name, None, None, ['__all__']) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/pygments/lexers/python.py", line 14, in from pygments.lexer import DelegatingLexer, Lexer, RegexLexer, include, \ File "/usr/lib/python3.12/site-packages/pygments/lexer.py", line 16, in from pygments.filters import get_filter_by_name 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 bc2f496b-4c4d-4b54-8a54-aad39efb1e2d: 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 0xffffff8b0220c0> 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 = 1707337009.8253024 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 446, in class AutoMagicChecker(PrefilterChecker): File "/usr/lib/python3.12/site-packages/traitlets/traitlets.py", line 984, in __new__ return super().__new__(mcls, name, bases, classdict) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 2c424288-a9da-486d-9db2-6d1fe9bda157: 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 0xffffff8b0219e0> 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 = 1707337103.0367105 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 53, in from pygments.lexers import PythonLexer File "", line 1406, in _handle_fromlist File "/usr/lib/python3.12/site-packages/pygments/lexers/__init__.py", line 350, in __getattr__ _load_lexers(info[0]) File "/usr/lib/python3.12/site-packages/pygments/lexers/__init__.py", line 45, in _load_lexers mod = __import__(module_name, None, None, ['__all__']) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "", line 1351, in _find_and_load File "", line 417, in __enter__ File "", line 458, in _get_module_lock KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel c5debf5c-7406-4653-be74-e6bbe60d5a3b: 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 0xffffff8b022de0> 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 = 1707337198.602057 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 0, in KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 76a2aa6b-4148-4925-8b7e-7e66fba1b3db: Kernel didn't respond in 60 seconds _________________________ test_many_parallel_notebooks _________________________ capfd = <_pytest.capture.CaptureFixture object at 0xffffff8ae98b90> @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 0xffffff8ae98b90> 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 0xffffff8b023ba0> 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 = 1707337387.0036612 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 "", 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 6d116504-8edc-4073-83e8-44f519d301d5: Kernel didn't respond in 60 seconds ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 0006bc06-623f-491f-afe9-f2739a46ff7b: Kernel didn't respond in 60 seconds ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 460054cd-ada9-4dca-80da-780ae111dd87: 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 53, in from .core.application import Application File "/usr/lib/python3.12/site-packages/IPython/core/application.py", line 26, in from IPython.core import release, crashhandler File "/usr/lib/python3.12/site-packages/IPython/core/crashhandler.py", line 27, in from IPython.core import ultratb File "/usr/lib/python3.12/site-packages/IPython/core/ultratb.py", line 104, in import stack_data File "/usr/lib/python3.12/site-packages/stack_data/__init__.py", line 1, in from .core import Source, FrameInfo, markers_from_ranges, Options, LINE_GAP, Line, Variable, RangeInLine, \ File "/usr/lib/python3.12/site-packages/stack_data/core.py", line 18, in from pure_eval import Evaluator, is_expression_interesting File "/usr/lib/python3.12/site-packages/pure_eval/__init__.py", line 1, in from .core import Evaluator, CannotEval, group_expressions, is_expression_interesting 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 c081a9ec-a3c8-4c00-85be-b7fe3f53023a: Kernel didn't respond in 60 seconds ________________________ test_async_parallel_notebooks _________________________ capfd = <_pytest.capture.CaptureFixture object at 0xffffff8af613a0> 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 0xffffff8af613a0> 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 0xffffff8b023f60> 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 0xffffff88551e00> runner = /usr/lib64/python3.12/asyncio/runners.py:118: in run return self._loop.run_until_complete(task) context = <_contextvars.Context object at 0xffffff73f8bdc0> coro = .run_tasks at 0xffffff88551e00> 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 0xffffff8b0236a0> 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 = 1707337602.4127178 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 53, in from pygments.lexers import PythonLexer File "", line 1406, in _handle_fromlist File "/usr/lib/python3.12/site-packages/pygments/lexers/__init__.py", line 350, in __getattr__ _load_lexers(info[0]) File "/usr/lib/python3.12/site-packages/pygments/lexers/__init__.py", line 45, in _load_lexers mod = __import__(module_name, None, None, ['__all__']) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/pygments/lexers/python.py", line 14, in from pygments.lexer import DelegatingLexer, Lexer, RegexLexer, include, \ 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 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 53, in from .core.application import Application File "/usr/lib/python3.12/site-packages/IPython/core/application.py", line 26, in from IPython.core import release, crashhandler File "/usr/lib/python3.12/site-packages/IPython/core/crashhandler.py", line 27, in from IPython.core import ultratb File "/usr/lib/python3.12/site-packages/IPython/core/ultratb.py", line 105, in from pygments.formatters.terminal256 import Terminal256Formatter File "/usr/lib/python3.12/site-packages/pygments/formatters/terminal256.py", line 28, in from pygments.style import ansicolors File "/usr/lib/python3.12/site-packages/pygments/style.py", line 170, in class Style(metaclass=StyleMeta): File "/usr/lib/python3.12/site-packages/pygments/style.py", line 96, in __new__ for styledef in obj.styles.get(token, '').split(): ^^^^^^^^^^^^^^^^^^^^^^^^^ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel fd7f6d19-6499-448c-88f5-602d69ffe5d7: Kernel didn't respond in 60 seconds ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel c53780b5-5b00-4a21-ab04-52f199777552: Kernel didn't respond in 60 seconds ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 1481, in _path_importer_cache KeyError: '/usr/lib/python3.12/site-packages/ptyprocess' 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 53, in from .core.application import Application File "/usr/lib/python3.12/site-packages/IPython/core/application.py", line 26, in from IPython.core import release, crashhandler File "/usr/lib/python3.12/site-packages/IPython/core/crashhandler.py", line 27, in from IPython.core import ultratb File "/usr/lib/python3.12/site-packages/IPython/core/ultratb.py", line 115, in from IPython.utils import path as util_path File "/usr/lib/python3.12/site-packages/IPython/utils/path.py", line 16, in from IPython.utils.process import system File "/usr/lib/python3.12/site-packages/IPython/utils/process.py", line 19, in from ._process_posix import system, getoutput, arg_split, check_pid File "/usr/lib/python3.12/site-packages/IPython/utils/_process_posix.py", line 23, in import pexpect File "/usr/lib/python3.12/site-packages/pexpect/__init__.py", line 75, in from .pty_spawn import spawn, spawnu File "/usr/lib/python3.12/site-packages/pexpect/pty_spawn.py", line 10, in import ptyprocess File "/usr/lib/python3.12/site-packages/ptyprocess/__init__.py", line 2, in from .ptyprocess import PtyProcess, PtyProcessUnicode, PtyProcessError 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 1461, in _path_hooks 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 53, in from .core.application import Application File "/usr/lib/python3.12/site-packages/IPython/core/application.py", line 26, in from IPython.core import release, crashhandler File "/usr/lib/python3.12/site-packages/IPython/core/crashhandler.py", line 27, in from IPython.core import ultratb File "/usr/lib/python3.12/site-packages/IPython/core/ultratb.py", line 111, in from IPython.core import debugger 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 49af759d-33f7-476e-b198-f95f0b3a545e: Kernel didn't respond in 60 seconds ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel baab544c-9036-44f7-b446-ff1bd42d6ff2: Kernel didn't respond in 60 seconds ______________________ test_many_async_parallel_notebooks ______________________ capfd = <_pytest.capture.CaptureFixture object at 0xffffff8af81640> @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 0xffffff8af81640> 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 0xffffff8b022a20> 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 = 1707337794.6237476 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 12, in from IPython.core import ultratb, compilerop File "", line 1354, in _find_and_load File "", line 1325, in _find_and_load_unlocked File "", line 915, in _load_unlocked File "", line 819, in module_from_spec File "", line 798, in _init_module_attrs File "", line 638, in cached File "", line 611, in _get_cached KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 8db5b17e-5ca5-4222-823d-1e1e298f2806: 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 13, in from IPython.core import magic_arguments File "/usr/lib/python3.12/site-packages/IPython/core/magic_arguments.py", line 94, in NAME_RE = re.compile(r"[a-zA-Z][a-zA-Z0-9_-]*$") ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 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 556, in _parse negate = sourcematch("^") ^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/_parser.py", line 249, in match def match(self, char): KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 7ce199a7-6845-4abe-aa24-ffa0a0a619b5: 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 0xffffff8b020360> 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 = 1707337892.577221 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 53, in from .core.application import Application File "/usr/lib/python3.12/site-packages/IPython/core/application.py", line 26, in from IPython.core import release, crashhandler File "/usr/lib/python3.12/site-packages/IPython/core/crashhandler.py", line 27, in from IPython.core import ultratb File "/usr/lib/python3.12/site-packages/IPython/core/ultratb.py", line 111, in from IPython.core import debugger File "/usr/lib/python3.12/site-packages/IPython/core/debugger.py", line 121, in from pdb import Pdb as OldPdb 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 412fbd3a-3f41-444a-86ee-09f98078236b: 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 = 1707337995.4056726 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/__init__.py", line 5, in from .connect import * # noqa ^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/ipykernel/connect.py", line 11, in import jupyter_client File "/usr/lib/python3.12/site-packages/jupyter_client/__init__.py", line 13, in from .manager import AsyncKernelManager # noqa ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/jupyter_client/manager.py", line 32, in from .provisioning import KernelProvisionerBase File "/usr/lib/python3.12/site-packages/jupyter_client/provisioning/__init__.py", line 1, in from .factory import KernelProvisionerFactory # noqa ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 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 2c31bdf0-8b57-40b7-a421-5948dd4896f0: 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 0xffffff884628e0> 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 0xffffff884628e0> 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 = 1707338091.630031 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/__init__.py", line 5, in from .connect import * # noqa ^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/ipykernel/connect.py", line 11, in import jupyter_client File "/usr/lib/python3.12/site-packages/jupyter_client/__init__.py", line 8, in from .asynchronous import AsyncKernelClient # noqa ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/jupyter_client/asynchronous/__init__.py", line 1, in from .client import AsyncKernelClient # noqa ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/jupyter_client/asynchronous/client.py", line 8, in from jupyter_client.client import KernelClient File "/usr/lib/python3.12/site-packages/jupyter_client/client.py", line 22, in from .connect import ConnectionFileMixin File "/usr/lib/python3.12/site-packages/jupyter_client/connect.py", line 187, in path: Optional[Union[str, List[str]]] = None, ~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/typing.py", line 374, in inner return _caches[func](*args, **kwds) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/typing.py", line 489, in __getitem__ return self._getitem(self, parameters) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/typing.py", line 723, in Optional return Union[arg, type(None)] ~~~~~^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/typing.py", line 374, in inner return _caches[func](*args, **kwds) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/typing.py", line 489, in __getitem__ return self._getitem(self, parameters) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/typing.py", line 708, in Union return _UnionGenericAlias(self, parameters) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/typing.py", line 1220, in __init__ self.__args__ = tuple(... if a is _TypingEllipsis else ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel a5fed5b8-2f9f-49fb-adeb-ece54cc11da1: 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 0xffffff884628e0> 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 0xffffff88460540> 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 = 1707338201.4726326 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 53, in from .core.application import Application File "/usr/lib/python3.12/site-packages/IPython/core/application.py", line 26, in from IPython.core import release, crashhandler File "/usr/lib/python3.12/site-packages/IPython/core/crashhandler.py", line 27, in from IPython.core import ultratb File "/usr/lib/python3.12/site-packages/IPython/core/ultratb.py", line 104, in import stack_data File "/usr/lib/python3.12/site-packages/stack_data/__init__.py", line 1, in from .core import Source, FrameInfo, markers_from_ranges, Options, LINE_GAP, Line, Variable, RangeInLine, \ File "/usr/lib/python3.12/site-packages/stack_data/core.py", line 15, in import executing File "/usr/lib/python3.12/site-packages/executing/__init__.py", line 14, in from .version import __version__ # type: ignore[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 1630, in find_spec File "", line 161, in _path_isfile 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 d8143430-cfd4-472e-b0ae-c7a29827e106: 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 0xffffff884628e0> 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 0xffffff882ef240> 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 = 1707338298.4395404 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- [IPKernelApp] WARNING | debugpy_stream undefined, debugging will not be enabled [IPKernelApp] WARNING | debugpy_stream undefined, debugging will not be enabled Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 53, in from .core.application import Application File "/usr/lib/python3.12/site-packages/IPython/core/application.py", line 26, in from IPython.core import release, crashhandler File "/usr/lib/python3.12/site-packages/IPython/core/crashhandler.py", line 27, in from IPython.core import ultratb File "/usr/lib/python3.12/site-packages/IPython/core/ultratb.py", line 111, in from IPython.core import debugger 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 62ddd061-1575-4887-a31b-567127b07e08: 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 0xffffff884628e0> 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 0xffffff882ef420> 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 = 1707338386.6248772 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 12, in from IPython.core import ultratb, compilerop 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 235cac65-94cc-460a-b432-f58dd2cacbb9: 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 0xffffff884628e0> 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 0xffffff882eff60> 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 = 1707338477.0468972 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 53, in from .core.application import Application File "/usr/lib/python3.12/site-packages/IPython/core/application.py", line 26, in from IPython.core import release, crashhandler File "/usr/lib/python3.12/site-packages/IPython/core/crashhandler.py", line 27, in from IPython.core import ultratb File "/usr/lib/python3.12/site-packages/IPython/core/ultratb.py", line 115, in from IPython.utils import path as util_path File "/usr/lib/python3.12/site-packages/IPython/utils/path.py", line 16, in from IPython.utils.process import system File "/usr/lib/python3.12/site-packages/IPython/utils/process.py", line 19, in from ._process_posix import system, getoutput, arg_split, check_pid File "/usr/lib/python3.12/site-packages/IPython/utils/_process_posix.py", line 23, in import pexpect File "/usr/lib/python3.12/site-packages/pexpect/__init__.py", line 75, in from .pty_spawn import spawn, spawnu File "/usr/lib/python3.12/site-packages/pexpect/pty_spawn.py", line 10, in import ptyprocess File "/usr/lib/python3.12/site-packages/ptyprocess/__init__.py", line 2, in from .ptyprocess import PtyProcess, PtyProcessUnicode, PtyProcessError File "/usr/lib/python3.12/site-packages/ptyprocess/ptyprocess.py", line 7, in import resource File "", line 1351, in _find_and_load File "", line 420, in __exit__ 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 f903cac0-e03b-464b-8476-a813195ce201: 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 0xffffff884628e0> 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 0xffffff8ae489a0> 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 = 1707338568.4574845 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "", line 1354, in _find_and_load File "", line 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 1003bade-af5e-454f-90ae-bfc8db3bb430: 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 0xffffff884628e0> 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 0xffffff8ae48fe0> 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 = 1707338658.4415002 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 59, in import IPython.core.hooks 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 a9096cf3-a5e6-4dcb-a70d-bb370fc39209: 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 0xffffff884628e0> 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 0xffffff8ae48680> 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 = 1707338748.253426 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 335, in ini_spaces_re = re.compile(r'^(\s+)') ^^^^^^^^^^^^^^^^^^^^^ 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 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 523, in _parse sourceget() File "/usr/lib64/python3.12/re/_parser.py", line 254, in get def get(self): KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 87ea0d22-7d83-4976-a69f-324cc1df276b: 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 0xffffff884628e0> 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 0xffffff8ae48e00> 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 = 1707338840.8573542 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 446, in class AutoMagicChecker(PrefilterChecker): 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 8d537be1-e3c8-4600-962e-82cdce2cb24f: 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 0xffffff884628e0> 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 0xffffff8ae49ee0> 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 = 1707338935.469713 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 3, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/base.py", line 11, in from prompt_toolkit.formatted_text import AnyFormattedText, StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/__init__.py", line 15, in from .ansi import ANSI File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/ansi.py", line 6, in from prompt_toolkit.output.vt100 import BG_ANSI_COLORS, FG_ANSI_COLORS File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/__init__.py", line 3, in from .base import DummyOutput, Output File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/base.py", line 9, in from prompt_toolkit.cursor_shapes import CursorShape File "/usr/lib/python3.12/site-packages/prompt_toolkit/cursor_shapes.py", line 8, in from prompt_toolkit.key_binding.vi_state import InputMode File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/__init__.py", line 10, in from .key_processor import KeyPress, KeyPressEvent File "/usr/lib/python3.12/site-packages/prompt_toolkit/key_binding/key_processor.py", line 19, in from prompt_toolkit.utils import Event File "/usr/lib/python3.12/site-packages/prompt_toolkit/utils.py", line 18, in from wcwidth import wcwidth File "/usr/lib/python3.12/site-packages/wcwidth/__init__.py", line 12, in from .wcwidth import ZERO_WIDTH # noqa ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/wcwidth/wcwidth.py", line 73, in from .unicode_versions import list_versions File "", line 1354, in _find_and_load File "", line 1316, in _find_and_load_unlocked File "", line 1256, in _find_spec File "", line 1524, in find_spec File "", line 1498, in _get_spec File "", line 1631, in find_spec File "", line 1584, in _get_spec KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel ac5c7c85-10a4-4068-98e6-c98f6ff22e7e: 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 48, in from .debugger import TerminalPdb, Pdb File "/usr/lib/python3.12/site-packages/IPython/terminal/debugger.py", line 6, in from IPython.core.completer import IPCompleter File "/usr/lib/python3.12/site-packages/IPython/core/completer.py", line 219, in from IPython.core.guarded_eval import guarded_eval, EvaluationContext File "/usr/lib/python3.12/site-packages/IPython/core/guarded_eval.py", line 655, in *[method for numeric_cls in NUMERICS for method in _list_methods(numeric_cls)], ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.12/site-packages/IPython/core/guarded_eval.py", line 625, in _list_methods return [getattr(cls, k) for k in (source if source else dir(cls))] ^^^^^^^^ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 5a333e69-044a-4a9e-bd2c-77056259d6ca: 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 0xffffff884628e0> 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 0xffffff8ae4ade0> 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 = 1707339096.8863504 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 24, in from .splitinput import LineInfo 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 21304bbc-b3ca-4422-b720-6d1cae1825fd: 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 0xffffff884628e0> 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 0xffffff8ae4b6a0> 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 = 1707339192.2901232 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 53, in from .core.application import Application File "/usr/lib/python3.12/site-packages/IPython/core/application.py", line 26, in from IPython.core import release, crashhandler File "/usr/lib/python3.12/site-packages/IPython/core/crashhandler.py", line 27, in from IPython.core import ultratb File "/usr/lib/python3.12/site-packages/IPython/core/ultratb.py", line 104, in import stack_data File "/usr/lib/python3.12/site-packages/stack_data/__init__.py", line 1, in from .core import Source, FrameInfo, markers_from_ranges, Options, LINE_GAP, Line, Variable, RangeInLine, \ File "/usr/lib/python3.12/site-packages/stack_data/core.py", line 511, in class FrameInfo(object): File "/usr/lib/python3.12/site-packages/stack_data/core.py", line 783, in FrameInfo def scope(self) -> Optional[ast.AST]: ~~~~~~~~^^^^^^^^^ File "/usr/lib64/python3.12/typing.py", line 374, in inner return _caches[func](*args, **kwds) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/typing.py", line 489, in __getitem__ return self._getitem(self, parameters) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/typing.py", line 723, in Optional return Union[arg, type(None)] ~~~~~^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/typing.py", line 374, in inner return _caches[func](*args, **kwds) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel fe346ccf-b7be-4939-9ba9-bd0fe58262b9: 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 0xffffff884628e0> 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 0xffffff8ae4be20> 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 = 1707339292.4947865 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 55, in esc_re = re.compile(r"(\x1b[^m]+m)") ^^^^^^^^^^^^^^^^^^^^^^^^^^^ 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 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 537, in _parse code = _escape(source, this, state) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/_parser.py", line 377, in _escape escape += source.getwhile(2, HEXDIGITS) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/re/_parser.py", line 258, in getwhile def getwhile(self, n, charset): KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 352209c6-6cd1-4da1-8854-6cd6a24fd0f1: 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 0xffffff884628e0> 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 0xffffff88148220> 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 = 1707339483.8372428 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 28, in from IPython.display import display 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 45ae15f0-d2c7-4005-9bb6-3b27ecd76199: Kernel didn't respond in 60 seconds ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 25, in from .completion import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/__init__.py", line 3, in from .base import ( File "/usr/lib/python3.12/site-packages/prompt_toolkit/completion/base.py", line 11, in from prompt_toolkit.formatted_text import AnyFormattedText, StyleAndTextTuples File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/__init__.py", line 15, in from .ansi import ANSI File "/usr/lib/python3.12/site-packages/prompt_toolkit/formatted_text/ansi.py", line 6, in from prompt_toolkit.output.vt100 import BG_ANSI_COLORS, FG_ANSI_COLORS File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/__init__.py", line 3, in from .base import DummyOutput, Output File "/usr/lib/python3.12/site-packages/prompt_toolkit/output/base.py", line 9, in from prompt_toolkit.cursor_shapes import CursorShape File "/usr/lib/python3.12/site-packages/prompt_toolkit/cursor_shapes.py", line 23, in class CursorShape(Enum): File "/usr/lib/python3.12/site-packages/prompt_toolkit/cursor_shapes.py", line 35, in CursorShape BEAM = "BEAM" ^^^^ File "/usr/lib64/python3.12/enum.py", line 442, in __setitem__ elif _is_descriptor(value): ^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/enum.py", line 43, in _is_descriptor hasattr(obj, '__get__') or ^^^^^^^^^^^^^^^^^^^^^^^ KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 277a7b90-7d0f-4760-b6c3-9c82c2a44f74: 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 0xffffff884628e0> 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 0xffffff88149800> 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 = 1707339638.875568 self = timeout = 60 /usr/lib/python3.12/site-packages/jupyter_client/client.py:206: RuntimeError ----------------------------- Captured stderr call ----------------------------- Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/usr/lib/python3.12/site-packages/ipykernel_launcher.py", line 15, in from ipykernel import kernelapp as app File "/usr/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 19, in from IPython.core.application import ( # type:ignore[attr-defined] File "/usr/lib/python3.12/site-packages/IPython/__init__.py", line 54, in from .terminal.embed import embed File "/usr/lib/python3.12/site-packages/IPython/terminal/embed.py", line 16, in from IPython.terminal.interactiveshell import TerminalInteractiveShell File "/usr/lib/python3.12/site-packages/IPython/terminal/interactiveshell.py", line 31, in from prompt_toolkit.auto_suggest import AutoSuggestFromHistory File "/usr/lib/python3.12/site-packages/prompt_toolkit/__init__.py", line 25, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/__init__.py", line 3, in from .application import Application File "/usr/lib/python3.12/site-packages/prompt_toolkit/application/application.py", line 36, in from prompt_toolkit.buffer import Buffer File "/usr/lib/python3.12/site-packages/prompt_toolkit/buffer.py", line 22, in from .auto_suggest import AutoSuggest, Suggestion File "/usr/lib/python3.12/site-packages/prompt_toolkit/auto_suggest.py", line 21, in from .document import Document File "/usr/lib/python3.12/site-packages/prompt_toolkit/document.py", line 12, in from .clipboard import ClipboardData File "/usr/lib/python3.12/site-packages/prompt_toolkit/clipboard/__init__.py", line 3, in from .base import Clipboard, ClipboardData, DummyClipboard, DynamicClipboard File "/usr/lib/python3.12/site-packages/prompt_toolkit/clipboard/base.py", line 9, in from prompt_toolkit.selection import SelectionType File "/usr/lib/python3.12/site-packages/prompt_toolkit/selection.py", line 30, in class PasteMode(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 264, in __set_name__ enum_member = enum_class._new_member_(enum_class) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ KeyboardInterrupt Error calling __set_name__ on '_proto_member' instance 'EMACS' in 'PasteMode' ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 03fbd816-41a0-4c7a-bc06-95cda0fb620e: 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 0xffffff8810a1b0> 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 0xffffff8810a1b0>,) 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 0xffffff884628e0> 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 0xffffff8810a1b0> /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 0xffffff88148f40> self = .WrappedPreProc object at 0xffffff8810a1b0> 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 0xffffff8810a1b0> /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 = 1707339727.4486508 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 "", line 1354, in _find_and_load File "", line 1316, in _find_and_load_unlocked File "", line 1250, in _find_spec KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel c37422a7-0d75-458b-b5ee-09b84c210fdf: 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 0xffffff884628e0> 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 0xffffff8814a020> 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 = 1707339817.8781734 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 53, in from .core.application import Application File "/usr/lib/python3.12/site-packages/IPython/core/application.py", line 26, in from IPython.core import release, crashhandler File "/usr/lib/python3.12/site-packages/IPython/core/crashhandler.py", line 27, in from IPython.core import ultratb File "/usr/lib/python3.12/site-packages/IPython/core/ultratb.py", line 105, in from pygments.formatters.terminal256 import Terminal256Formatter File "/usr/lib/python3.12/site-packages/pygments/formatters/terminal256.py", line 34, in class EscapeSequence: File "/usr/lib/python3.12/site-packages/pygments/formatters/terminal256.py", line 34, in EscapeSequence class EscapeSequence: KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel 1ce1c37b-a246-46d2-9a1e-07f3423f69f8: 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 0xffffff884628e0> 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 0xffffff88149f80> 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 0xffffff884628e0> 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 = 1707339915.1138904 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 53, in from .core.application import Application File "/usr/lib/python3.12/site-packages/IPython/core/application.py", line 26, in from IPython.core import release, crashhandler File "/usr/lib/python3.12/site-packages/IPython/core/crashhandler.py", line 27, in from IPython.core import ultratb File "/usr/lib/python3.12/site-packages/IPython/core/ultratb.py", line 96, in import pydoc 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 b748a5e0-48f2-405b-a9fd-edde461eb018: 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 0xffffff884628e0> 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 0xffffff88148ea0> 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 = 1707340016.0955038 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 53, in from .core.application import Application File "/usr/lib/python3.12/site-packages/IPython/core/application.py", line 26, in from IPython.core import release, crashhandler File "/usr/lib/python3.12/site-packages/IPython/core/crashhandler.py", line 27, in from IPython.core import ultratb File "/usr/lib/python3.12/site-packages/IPython/core/ultratb.py", line 104, in import stack_data File "/usr/lib/python3.12/site-packages/stack_data/__init__.py", line 1, in from .core import Source, FrameInfo, markers_from_ranges, Options, LINE_GAP, Line, Variable, RangeInLine, \ File "/usr/lib/python3.12/site-packages/stack_data/core.py", line 18, in from pure_eval import Evaluator, is_expression_interesting File "/usr/lib/python3.12/site-packages/pure_eval/__init__.py", line 1, in from .core import Evaluator, CannotEval, group_expressions, is_expression_interesting File "/usr/lib/python3.12/site-packages/pure_eval/core.py", line 9, in from pure_eval.my_getattr_static import getattr_static File "/usr/lib/python3.12/site-packages/pure_eval/my_getattr_static.py", line 3, in from pure_eval.utils import of_type, CannotEval File "", line 1354, in _find_and_load File "", line 1316, in _find_and_load_unlocked File "", line 1250, in _find_spec KeyboardInterrupt ------------------------------ Captured log call ------------------------------- ERROR traitlets:client.py:568 Error occurred while starting new kernel client for kernel b886de6d-8c94-4a2a-8044-f1f2d2682b64: 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 0xffffff8814b4c0> 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 0xffffff8814b4c0>} 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 0xffffff884628e0> 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 0xffffff8814b2e0> 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 = 1707340115.7584224 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 53, in from .core.application import Application File "/usr/lib/python3.12/site-packages/IPython/core/application.py", line 26, in from IPython.core import release, crashhandler File "/usr/lib/python3.12/site-packages/IPython/core/crashhandler.py", line 27, in from IPython.core import ultratb File "/usr/lib/python3.12/site-packages/IPython/core/ultratb.py", line 104, in import stack_data File "/usr/lib/python3.12/site-packages/stack_data/__init__.py", line 1, in from .core import Source, FrameInfo, markers_from_ranges, Options, LINE_GAP, Line, Variable, RangeInLine, \ File "/usr/lib/python3.12/site-packages/stack_data/core.py", line 15, in import executing File "/usr/lib/python3.12/site-packages/executing/__init__.py", line 12, in from .executing import Source, Executing, only, NotOneValueFound, cache, future_flags 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 3e7a04fe-204c-4497-8184-7b307a276dbb: 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 0xffffff884628e0> 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 0xffffff8814b920> 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 = 1707340215.5252552 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 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 "/usr/lib/python3.12/site-packages/IPython/core/display.py", line 11, in import mimetypes 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 1630, in find_spec File "", line 161, in _path_isfile 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 fc8d74df-9b53-4156-8888-24d10b48388c: 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 135149 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 135152 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_display_data_message tests/test_client.py::TestRunCell::test_display_data_same_id_message tests/test_client.py::TestRunCell::test_eventual_deadline_iopub tests/test_client.py::TestRunCell::test_non_code_cell_hooks tests/test_client.py::TestRunCell::test_widget_comm_message tests/test_util.py::test_nested_asyncio_with_tornado /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-17 (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 ============================= 81.57s call tests/test_client.py::test_run_all_notebooks[Other Comms.ipynb-opts0] 76.61s call tests/test_client.py::test_synchronous_setup_kernel 76.33s call tests/test_client.py::test_run_all_notebooks[Skip Exceptions with Cell Tags.ipynb-opts8] 74.48s call tests/test_client.py::test_run_all_notebooks[Clear Output.ipynb-opts1] 74.46s call tests/test_client.py::test_run_all_notebooks[Factorials.ipynb-opts3] 73.52s call tests/test_client.py::test_async_parallel_notebooks 73.29s call tests/test_client.py::TestExecute::test_force_raise_errors 71.70s call tests/test_client.py::TestExecute::test_timeout_func 71.16s call tests/test_client.py::TestExecute::test_sync_kernel_manager 70.14s call tests/test_client.py::TestExecute::test_timeout =========================== 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 5013.31s (1:23:33) =========== 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 0xffffff8810a1b0>> 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.UBkL5B (%check) RPM build errors: Bad exit status from /var/tmp/rpm-tmp.UBkL5B (%check) Child return code was: 1 EXCEPTION: [Error('Command failed: \n # bash --login -c /usr/bin/rpmbuild -ba --noprep --noclean --target noarch --nodeps /builddir/build/SPECS/python-nbclient.spec\n', 1)] Traceback (most recent call last): File "/usr/lib/python3.11/site-packages/mockbuild/trace_decorator.py", line 93, in trace result = func(*args, **kw) ^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/mockbuild/util.py", line 597, in do_with_status raise exception.Error("Command failed: \n # %s\n%s" % (command, output), child.returncode) mockbuild.exception.Error: Command failed: # bash --login -c /usr/bin/rpmbuild -ba --noprep --noclean --target noarch --nodeps /builddir/build/SPECS/python-nbclient.spec