-
Notifications
You must be signed in to change notification settings - Fork 875
definition lists containing multi-paragraph ordered lists rendered as code #918
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. This could be a tricky one to fix. I believe the issue is related to the DefListIndentProcessor, which subclasses the ListIndentProcessor and overrides the The problem here is that the second level of nesting is a Alternatively, the entire block parser could be refactored to consume all nested content as a single block, rather than processing each individual sub-block separately. But that would be a major change and isn't likely to happen anytime soon. |
@waylan Thanks for digging and confirming. The ambiguity of four-space indents certainly isn't helping. Is it an indented code block? Maybe. Is it a secondary paragraph of a list item? Maybe! I've restructured our documentation to avoid this problem - the |
Given Markdown with a definition list that contains an ordered list and the ordered list has multi-paragraph elements, each ordered list element is rendered as a separate ordered list and the paragraphs are rendered as code blocks.
This appears specific to definition lists (using
def_list
). It does not appear that other types of lists make a similar formatting decision for multi-paragraph sub-lists.The markdown input:
Expected:
Actual:
Tested with:
/usr/local/bin/markdown_py -x def_list definitions.md /usr/local/bin/markdown_py --version # => markdown_py 3.2.1
The text was updated successfully, but these errors were encountered: