🐛 FIX: Spurious newline in generated literal_block nodes by cpitclaudel · Pull Request #541 · executablebooks/MyST-Parser

@cpitclaudel

Closes #407. The details are in the original bug report, but the long story short is that Docutils already adds a newline to its <pre> blocks, so we don't need one more. I opted to fix all literal_blocks, but the most important ones are the ones in create_highlighted_code_block.

@cpitclaudel

@chrisjsewell

@chrisjsewell

@pre-commit-ci

@codecov

@chrisjsewell

Thanks @cpitclaudel this requires fixes for a number of the regression tests (if you didn't know you can run pytest --force-regen

My question would be though; should the behaviour be the same for docutils and sphinx? i.e.does the sphinx builder also require this new line removal?