mystmd
mystmd copied to clipboard
Document `stderr` and `stdout` for cell and eval execution
Currently if you execute a notebook and it returns errors, you get a MyST log message like:
⚠️ notebooks-with-markdown.md An exception occurred during expression evaluation, halting further execution
⛔️ notebooks-with-markdown.md An error occurred during kernel execution
📖 Built notebooks-with-markdown.md in 1.39 s.
⚠️ interactive-notebooks.ipynb An exception occurred during code execution, halting further execution
⛔️ interactive-notebooks.ipynb An error occurred during kernel execution
📖 Built interactive-notebooks.ipynb in 2.2 s.
This doesn't give you much information to understand what happened. It would be useful to surface the execution logs so that you can see what's going on.
Two ways you could do this:
- In the MyST build logs (e.g. show the execution errors with
myst build --execute -d. - In the build outputs (e.g. have a
_build/execute/page1_logs.txtfile)
Of the two I think the second would be more user friendly, so that you could surface a link to the logs in the MyST build log, and then the more verbose execution logs could be browsed via a file browser.