jupyter / jupyter_client

Jupyter protocol client APIs
https://jupyter-client.readthedocs.io
BSD 3-Clause "New" or "Revised" License
383 stars 283 forks source link

jupyter-run: avoid traceback for NoSuchKernel #994

Closed minrk closed 1 week ago

minrk commented 11 months ago

NoSuchKernel used to raise during KernelManager instantiation, but it is now delayed, so our except NoSuchKernel isn't catching the error when it's raised anymore.

Access kernel_spec to ensure it's raised where it will be caught.

Also removes a redundant warning log immediately before raising, which prevents complete handling of NoSuchError and produces unavoidable duplicate logs.

Test added for runapp, both regression for #993 and simple exercise for everything working correctly.

closes #993

minrk commented 11 months ago

need to investigate why the minimum version test doesn't see any output. Hard to compare, since the test jobs don't show what packages are installed, so I can't easily diff or reproduce the envs.

blink1073 commented 11 months ago

The minimum tests use hatch --v run, you can add that to the standard tests to compare.