nebari-dev / jupyterlab-launchpad

BSD 3-Clause "New" or "Revised" License
13 stars 2 forks source link

Record "last used" date for kernels that were started without the table #29

Closed krassowski closed 5 months ago

krassowski commented 5 months ago

Currently kernels that are started outside of the extension UI do not get "last used" date updated. This is in particular problematic if user opens a with an already associated kernel as this makes "last used" column value different than what expected by the user.

We can do better by listening to kernels as they get started via services API, regardless of what started them.

krassowski commented 5 months ago

May require a decision on https://github.com/nebari-dev/jupyterlab-new-launcher/issues/2

ericdatakelly commented 5 months ago

More testing in case it helps: I made a new environment, which I assume creates a new kernel, but still I saw no change to the "last used" value (still shows "Never"). Next I selected "Shut down all kernels", stopped JLab, logged out of Nebari, waited 6 minutes, logged back in and restarted JLab with a different server size (small instead of tiny). "Last used"still showed "Never".

krassowski commented 5 months ago

I made a new environment, which I assume creates a new kernel , but still I saw no change to the "last used" value (still shows "Never")

The definition of "used" is that the kernel was created/used (i.e. notebook was opened and kernel was started), not that the environment was used. Detecting when an environment was used would be a much harder problem.

krassowski commented 5 months ago

I can reproduce a bug in that when the kernel is selected in the pop-up dialog it does not get recorded. The launcher itself is not affected.