This hot patch does what I want... immediate send instead of accumulation.
Not sure I can recommend it for general inclusion since it raises the
spectre of how to handle an error that happens after some of the body has
already been sent.
sed -i "$(fgrep -n
"result_accumulator['stream'].append((msg['content']['text']))"
/usr/local/lib/python3.8/dist-packages/kernel_gateway/notebook_http/handlers.py
| cut -d: -f1)s/[^ ].*/self.write(msg['content']['text']); self.flush()/"
/usr/local/lib/python3.8/dist-packages/kernel_gateway/notebook_http/handlers.py
On Friday, September 23, 2022 at 3:00:41 PM UTC-5 John Muehlhausen wrote:
> Can notebook-http return the cell result as it is printed? For example,
> immediately return
>
> [
>
> then periodically return
>
> {...},
>
> and finally
>
> {...}]
>
> ?
>
> For a long-running cell this might be required to keep something from
> timing out, such as a proxy. It would also be useful for generating a
> "stream."
>
> -John
>
--
You received this message because you are subscribed to the Google Groups
"Project Jupyter" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jupyter/b621f81f-f69f-4836-853f-af0a4156fea6n%40googlegroups.com.