Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Startup error: kernel file does not exist #34

Open
nokome opened this issue Mar 17, 2021 · 0 comments
Open

Startup error: kernel file does not exist #34

nokome opened this issue Mar 17, 2021 · 0 comments

Comments

@nokome
Copy link
Member

nokome commented Mar 17, 2021

I have noticed that on occasions, an error appears no such file or directory, open '/home/guest/.local/share/jupyter/runtime/kernel-d95255e6-2c60-486a-8fb9-e042abd5697e.json in the first code chunk of a document that is using a Python kernel. e.g. https://elife.stencila.io/article-55650/v23/:

image

I suspect this is a race condition during the startup of the kernel because (a) it does not happen all the time, and (b) on pressing the Run button a second time, the message goes away.

I am unable to replicate the issue locally but seem to get it on CI sometimes. I put a kludge to try to deal with this a few weeks ago:

jupita/src/index.ts

Lines 286 to 290 in f9683d9

// Wait an arbitrary amount of time for the kernel and
// messaging to startup. This is an attempt to resolve issues
// seen on CI where the first test timed out but subsequent tests passed
// and in production occasionally on first code execution.
await new Promise((resolve) => setTimeout(resolve, 1000))
.

Perhaps rather than waiting a second we need to either wait for the file to exist via polling or catch the error and retry.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant