Skip to content

Render Kino.JS component outside Livebook process. Output data no longer available. #1395

Answered by jonatanklosko
BrooklinJazz asked this question in Q&A
Discussion options

You must be logged in to vote

This happens is because Kino.JS(.Live) needs to be garbage collected, so its lifetime is usually tied to the process that creates it (or the cell).

I assume there is a place/function you call in the notebook to run the tests, right? You should create and render the output from that function. Maybe add a receive and make the formatter so that it sends a message back, or something like that?

Sidenote: one way to render an output from a temporary process would be to spawn another process that creates and renders the output, then sleeps forever, and then we kill that process when the output is no longer needed. But this requires thinking carefully where the output should be garbage collected …

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@BrooklinJazz
Comment options

Answer selected by BrooklinJazz
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants