Improve error messages surrounding notebooks #8920
Closed
nickvigilante
started this conversation in
Feature Requests
Replies: 1 comment
-
Thanks for the feedback. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Description
This isn't so much a bug but a request to improve the error messages surrounding notebooks. The common thread between the two issues is to make it easier to identify the file (and the line in the file) that causes issues when running
quarto preview
orquarto render
.Issue 1
I'm new to Jupyter notebooks and Quarto in general, so I thought I'd be able to get away with running
touch notebook.ipynb
to create a new notebook that I know I'll need to write later.I recognize that running
touch notebook.ipynb && jupyter execute notebook.ipynb
throws an error, and now I know I can't create notebooks usingtouch
.Despite that, here's what I get when running
quarto preview
:If this one notebook is buried among several other notebook files, it's not clear which one is the problematic notebook just by looking at this error message alone. What might be nice is a message like this:
That way, I know exactly which notebook is malformed and can take steps to fix it, hopefully speeding up my own troubleshooting.
This is also applicable to a case where there might have been an unexplained issue when saving the notebook, or if someone manually edited the notebook JSON. Just giving the user a clue about the file where the issue is happening would be immensely helpful.
Issue 2
I created a notebook with two cells. The label of the first cell is
test-1
, and the second cell has no label (a forced typo for illustrative purposes).I used the
embed
shortcode to embed the two cells in a document:When I run
quarto preview
, I get the following message:Here are the things that tripped me up:
[1/1] index.qmd
does not mean that the document rendered correctly. I didn't assume the error message applied to index.qmd. I had assumed that[X/Y] path/to/file.qmd
meant thatpath/to/file.qmd
had successfully rendered.In this situation, I think the following could benefit others:
Something like this:
Having the above would have made (and will continue to make, if implemented) troubleshooting easier.
Thanks for your consideration!
Beta Was this translation helpful? Give feedback.
All reactions