Controlling output of long-running process?
My code creates a long-running thread in the background and I'd like to have all the output of the thread go to a single cell. Currently just the first message goes to the cell. Demo code:
Is there any way to capture the output from my thread in a specific cell?
(side note: this code also seems to cause auto export to raise an exception)
3 Replies
Someone will reply to you shortly. In the meantime, this might help:
seems like a duplicate of: https://github.com/marimo-team/marimo/issues/2642
GitHub
Thread-local runtime context makes I/O methods not work in notebook...
Describe the bug The runtime context is a threadlocal, which was convenient for us when running marimo notebooks as apps (each session runs in its own thread). This however means that I/O doesn'...
apparently the AI is better at finding related issues than I am 😉
I take it back, even
mo.Thread
doesn't capture the output