-
Notifications
You must be signed in to change notification settings - Fork 349
Rendering notebook to docusaurus-md format removes heading #8961
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Thanks for the report and the reproducible example. Note that this only happens with Jupyter notebook and note with plain text Quarto document such as below. # This is a header
Content of page |
Are you able to provide any pointers about where this bug might be happening? It's blocking my use case so I would love to help unblock if I am able to |
I worked out how to mitigate the issue so I'm not blocked now |
@jackgerrits thanks for the report. The issue here is most likely an interaction between the way that titles can be declared in .ipynb, and how that information is getting relayed to the other renderers. In Ipynb, a level-1 heading is interpreted as the title of the document (because that's often how authors in jupyter denote a document title). In markdown formats, we typically relay that information in a metadata block. Consider this:
Note where the title ended up. To be clear, it's 100% a bug on our side that in docusaurus the H1 title is getting dropped! Let me think about the best way to solve this and I'll follow up. |
I'm more confident that this is indeed the issue. Another way that authors can declare titles in jupyter notebooks is by starting the notebook with a Raw NBconvert block and then use that to write YAML metadata:
This style of title declaration reproduces the behavior above in both
I think a different way to characterize this bug is "titles from jupyter documents are not rendered properly in docusaurus". |
The weird part is that only became a problem for me when migrating from v1.4.549 -> v1.5.23. When I was using v1.4.549 I was getting titles. I know that is a large range but I wonder what changed? |
It's not a large range, and thank you for the bracket. It was easy to bisect from there. The offending commit was d75246d. I'll fix this right away. |
We have a fix on 1.4.551 as well as a fix on |
Thank you so much for quick fix! It is greatly appreciated! |
Bug description
When rending a notebook to the docusaurus format the heading is removed. There is also no front matter added.
This is using the latest quarto version: 1.5.23
Steps to reproduce
Renders:
Expected behavior
I would expect the header to remain and (I think) the front matter including
title
to be added.Actual behavior
Header is removed and no front matter added.
Your environment
MacOS 14.3.1, quarto cli
Quarto check output
The text was updated successfully, but these errors were encountered: