jackdewinter / pymarkdown

MIT License
73 stars 17 forks source link

Rehydration: Extra block quote character added at end of document #1156

Closed jackdewinter closed 2 months ago

jackdewinter commented 3 months ago

Prerequisites

Bug Report

Bug Type

Description

When the document is rehydrated, there is a new > character at the end of the document.

Specifics

What operating system and version are you running into this behavior on?

Win11

What version are you seeing this behavior in? (Run pip list or pipenv run pip list and look for the entry beside pymarkdownlnt.)

latest, main

Are there any extra steps that need to be taken before executing the application?

No

What is the command line you invoke to get this behavior?

test_extra_044ldb0

Are you using a configuration file? Either on the command line or one of the implicit configuration files? If so, attach that file to this issue.

No

What Markdown document causes this behavior to manifest? Attach that file to this issue.

> + + -----
>     > block 1
>     > block 2
>     # before
>     ```block
>     A code block
>     ```
>     # after
> + another list

Actual Behavior

The document renders back to its original markdown, but has an extra > at the end.

Expected Behavior

The document should be rehydrated exactly as it started.

jackdewinter commented 2 months ago

fix