Closed mgeisler closed 10 months ago
I've opened a PR to fix the existing token couting code.
I agree pulldown-cmark-to-cmark should construct an appropriate markdown without workaround. I'll consider about it.
Awesome, thank you very much!
I see the discussion here: https://github.com/Byron/pulldown-cmark-to-cmark/issues/20#issuecomment-1907767535 and that you've opened https://github.com/Byron/pulldown-cmark-to-cmark/pull/65 to fix it.
Thanks also for #153 — I'm happy to merge that and then simplify our code when the fix has been released in the upstream pulldown-cmark-to-cmark crate.
I let it run for a few million iterations on my desktop and it looks rock solid now!
Fixed by #153.
After #129, the
group_events
fuzz test seems to have become flaky. @dalance, would you be able to take a look?An example failure is here, where the failing input can be minimized to
The diff of the failure is
meaning that
reconstruct_markdown(&events, None)
returnedwhereas
reconstruct_markdown(&flattened_groups, None)
returnedMy guess is that this is because the counting of consequetive
`
is slightly off.Indeed, looking at
flattened_groups
in the fuzz test, I seewith lots of lone
`
characters.A related question, is this not something which should be fixed in pulldown-cmark-to-cmark instead of here? @dalance, could you create an issue in that repository and see if you can move the fix from here to there?