-
Notifications
You must be signed in to change notification settings - Fork 190
Description
Problem
There is a BUG when:
- no blank line is inserted after the header of an admonition
AND - the admonition consists in codeblock containing a pair of brackets that opens on a line and closes on the next ones. (e.g.: a list of JSON metadata).
The python code that removes admonitions formatting for pdf rendering ignores the first line of the admonition content (cf. pdf_build_src/remove_admonitions.py#L41). In this case, this is the beginning of the code block, e.g. ```JSON.
Later, the python code responsible for multi-line markdown links checking (cf. pdf_build_src/process_markdowns.py#L230) -which is supposed to ignore code blocks- interprets the multi-line JSON list as a multi-line link because the header for the code block was removed.
Expected
I would expect that it's allowed to have a codeblock inside a admonition, and no blank line after the header.
I also suppose that this first line removal can remove contents from the spec during the pdf export...
Solution
I'm not sure whether lines 41 to 44 inside pdf_build_src/remove_admonitions.py are really needed for another reason.
If not, I can propose a PR.