Multi thread julia kernel (jupyter) fails to start under vscode (insiders)

Dear all …

As discussed in, it seems that I am not able to run a multi-julia thread kernel under VSCODE using Jupyer app of VSCODE Insiders.

  • VS Code version: 1.59.0-insider (Universal)
  • Jupyter Extension version (available under the Extensions sidebar): v2021.8.1055544705
  • Python Extension version (available under the Extensions sidebar): v2021.7.1060902895
  • OS (Windows | Mac | Linux distro) and version: MAC OS X BigSur
  • Python and/or Anaconda version: Python 3.8.8 (default, Apr 13 2021, 12:59:45)

The step to reproduce the problem are the following:

using IJulia
installkernel("Julia_8_threads", env=Dict("JULIA_NUM_THREADS"=>"8"))

Jupyter: Create new blank notebook (from VSCODE) → set kernel to Julia_8_threads.

The kernel does not start: Timed out waiting to get a heartbeat from kernel process.
Single threaded notebooks are ok.
Finally please note that if I run the kernel in chrome (with IJulia) the 8 thread kernel works perfectly

From a discussion with @rchiodo,

According to the kernel API, they should return a heartbeat whenever we [ping ]( heartbeat port. And it does with single threaded mode. I don't know why it's not in multithreaded mode. Might be a bug in the kernel.

Is this something worth reporting as an IJulia issue?


Not entirely sure, but we’re shipping our native integrated Jupyter Notebook support today that completely circumvents IJulia.jl. In principle that should be more stable, but in practice it doesn’t support multi threading yet.

Thank you @davidanthoff

I’ll try the new release. Thanks for your work!