You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
edit_note replace_section and prepend drop blank lines around headings #1815
edit_note(operation="replace_section", section="## Table", content="| x | y |\n|---|---|\n| 9 | 8 |") produces:
## Table| x | y ||---|---|| 9 | 8 |## Notes
The blank line after the heading and the blank line before the next heading are both lost. prepend similarly writes Prepended line.\n# Rich Markdown with no separating blank line. Edits should keep the section's surrounding blank lines and normalize the replacement content's edges.
Type: Bug. edit_note with replace_section or prepend removes the blank lines that separate headings from content. That changes the Markdown structure, and in the Table example the table's blank-line separation is lost.
Component: MCP tools (edit_note), in the note-editing and content-assembly path. It is not Cloud-specific.
Priority: Medium. The note's content and meaning are kept, but the formatting is damaged. Markdown renderers may handle the result differently, especially tables, and repeated edits make the notes harder to read.
Complexity: Simple to Medium. The fix is to normalize the leading and trailing newlines of the replacement content in the replace_section and prepend branches. It should also keep the blank lines around the section's heading and the next heading. Regression tests should cover:
a table section
prepend before a heading
content that already has leading or trailing blank lines
an empty section
the last section in a file
Duplicates: A search for similar issues found none.
Reproduction: The issue already has a clear repro, so nothing more is needed.
This is triage only. I haven't made any code changes.
Folded into the 1.0 tool surface work: #1831 (tracking #1827). This issue stays open until that lands, with a regression test for the behavior described here.
Activity
claude commentedon Oct 23, 2026
Claude finished @phernandez's task in 15s —— View job
Triage
edit_notewithreplace_sectionorprependremoves the blank lines that separate headings from content. That changes the Markdown structure, and in theTableexample the table's blank-line separation is lost.edit_note), in the note-editing and content-assembly path. It is not Cloud-specific.replace_sectionandprependbranches. It should also keep the blank lines around the section's heading and the next heading. Regression tests should cover:prependbefore a headingThis is triage only. I haven't made any code changes.
phernandez commentedon Oct 23, 2026
Folded into the 1.0 tool surface work: #1831 (tracking #1827). This issue stays open until that lands, with a regression test for the behavior described here.
fix(core): section edits share the read selector and keep blank lines
fix(core): section edits share the read selector and keep blank lines
fix(core): section edits share the read selector and keep blank lines
fix(core): section edits share the read selector and keep blank lines
fix(core): section edits share the read selector and keep blank lines
fix(core): section edits share the read selector and keep blank lines
fix(core): section edits share the read selector and keep blank lines
fix(core): section edits share the read selector and keep blank lines
fix(core): section edits share the read selector and keep blank lines
fix(core): section edits share the read selector and keep blank lines
fix(core): section edits share the read selector and keep blank lines
fix(core): section edits share the read selector and keep blank lines
fix(core): section edits share the read selector and keep blank lines
feat(mcp): add bm_write, bm_edit, bm_move and bm_delete (#1838)