joouha / euporie

Jupyter notebooks in the terminal
https://euporie.readthedocs.io
MIT License
1.54k stars 36 forks source link

Timed out #55

Closed ghost closed 5 months ago

ghost commented 1 year ago

Command line: euporie-notebook --kernel-name=ir 2_matching.ipynb

Config file:

{
  "app": {
    "edit_mode": "vi",
    "line_numbers": false
  },
  "notebook": {
    "edit_mode": "vi",
    "line_numbers": true,
    "autocomplete": true,
    "autosuggest": true,
    "autoinspect": true,
    "log_file": "[MY HOME DIRECTORY]/Documents/euporie.log",
    "log_level": "debug"
  }
}

Trying to run two very simple lines (can't yank in system clipboard): image

The execution never ends, the * is shown in the cell forever.

From the logs it looks like it times out waiting for kernel response:

2022-12-23 09:31:07 DEBUG   [euporie.core.terminal.send:115] Sending query '\x1b]10;?\x1b\\\x1b]11;?\x1b\\\x1b]4;0;?\x1b\\\x1b]4;1;?\x1b\\\x1b]4;2;?\x1b\\\x1b]4;3;?\x1b\\\x1b]4;4;?\x1b\\\x1b]4;5;?\x1b\\\x1b]4;6;?\x1b\\\x1b]4;7;?\x1b\\\x1b]4;8;?\x1b\\\x1b]4;9;?\x1b\\\x1b]4;10;?\x1b\\\x1b]4;11;?\x1b\\\x1b]4;12;?\x1b\\\x1b]4;13;?\x1b\\\x1b]4;14;?\x1b\\\x1b]4;15;?\x1b\\' for Colors
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal.send:115] Sending query '\x1b[14t' for PixelDimensions
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal.send:115] Sending query '\x1b[c' for SixelGraphicsStatus
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal.send:115] Sending query '\x1b[s\x1b_Gi=4294967295,s=1,v=1,a=q,t=d,f=24;AAAA\x1b\\\x1b[u\x1b[2K' for KittyGraphicsStatus
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal.send:115] Sending query '\x1b[>q' for ItermGraphicsStatus
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal.send:115] Sending query '\x1b[?1016$p' for SgrPixelStatus
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'Colors'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'KittyGraphicsStatus'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'ItermGraphicsStatus'
2022-12-23 09:31:07 DEBUG   [euporie.core.terminal._handle_response:98] Got terminal response for 'SgrPixelStatus'
2022-12-23 09:31:07 INFO    [euporie.core.app.open_file:554] Opening file 2_matching.ipynb
2022-12-23 09:31:07 DEBUG   [euporie.core.tabs.notebook.__init__:78] Loading notebooks [PATH TO MY NOTEBOOK]
2022-12-23 09:31:07 DEBUG   [euporie.core.kernel.start_:260] Starting kernel
2022-12-23 09:31:07 DEBUG   [euporie.core.kernel.start_:287] Started kernel
2022-12-23 09:31:07 DEBUG   [euporie.core.kernel.start_:306] Waiting for kernel to become ready
2022-12-23 09:31:08 DEBUG   [euporie.core.tabs.notebook.run_cell:298] Queuing running of cell 0
2022-12-23 09:31:08 DEBUG   [euporie.core.kernel.start_:315] Kernel b96350a1-c5ab-4d4c-a722-6a0d651c9a4e ready
2022-12-23 09:31:08 DEBUG   [euporie.core.kernel.poll:363] Waiting for shell messages
2022-12-23 09:31:08 DEBUG   [euporie.core.kernel.poll:363] Waiting for iopub messages
2022-12-23 09:31:08 DEBUG   [euporie.core.kernel.poll:363] Waiting for stdin messages
2022-12-23 09:31:08 DEBUG   [euporie.core.tabs.base.kernel_started:178] Running 1 kernel tasks
2022-12-23 09:31:08 DEBUG   [euporie.core.kernel.history_:803] Timed out waiting for kernel info response
ghost commented 1 year ago

Uhm doesn't work even in Jupyterlab :(

image

joouha commented 1 year ago

There seems to be a problem running the following command in IRkernel:

rm(list = ls(all = TRUE))

There's a bit more information on the kernel's standard output:

image

I think you might need to raise a bug report on the IRkernel repo for this one.

ghost commented 1 year ago

Done it

ghost commented 1 year ago

But still, euporie should detect that the kernel died and throw an error, instead of being stuck on that cell, right?

joouha commented 1 year ago

It does detect the kernel has died, but the only indication of this is that the kernel status icon turns into a sad face 😜

image

It might be worth showing a message box like Jupyter Lab does 👍

ghost commented 1 year ago

oh, nice

joouha commented 5 months ago

I'm just cleaning up old issues - you now do get error messages if the kernel dies:

euporie-notebook

image

euporie-console

image