mirror of
https://github.com/HKUDS/DeepTutor.git
synced 2026-12-02 16:19:28 +08:00
split_markdown_by_headings remembered only the fence character, so any line starting with that character toggled the fence. A ```` fence showing a ``` example closed at the inner ```, and a "```py" line inside a block also closed it, so "#" lines inside code became outline sections, or the rest of the document was swallowed and the outline fell back to flat. Remember the whole opening run and close only on a bare run of the same character that is at least as long, as CommonMark does. A backtick line whose info string contains a backtick no longer opens a fence. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>