GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||||||||||
GeezerVison is showing github.com — id(web): adjacent lists of different types save an <!-- end list --> comment that reopens as a phantom code block · Issue #1397 · developing-today/code Closed Labels app/idPackage/app: id (pkgs/ or apps/ in this repo)kind/bugSomething isn't working (prefixed form of the classic bug label)priority/normalOrdinary priority (the default)source/creatorFiled by the new-issue-creator jobstatus:donetask/triageQueue packet kind: verify, reproduce, and route this item DescriptionProblemIn the id web markdown codec ( #1032 fixed this for adjacent bullet lists (different markers) by coalescing them on save. Different-type neighbours cannot be coalesced — a bullet list and an ordered list are genuinely different lists — so the boundary case #1032 excluded is still live. Evidence (verified this run on main
|
| Input | Save output | Re-parsed PM |
|---|---|---|
- a\n1. b\n |
- a\n\n<!-- end list -->\n\n1. b\n |
bullet_list, code_block{params:"html", htmlBlock:true} containing <!-- end list -->, ordered_list |
1. a\n- b\n |
1. a\n\n<!-- end list -->\n\n- b\n |
ordered_list, same spurious code_block, bullet_list |
- a\n- b\n1. c\n2. d\n |
comment inserted at the type boundary | same spurious code_block between the lists |
1. [ ] t\n- plain\n |
1. [ ] t\n\n<!-- end list -->\n\n- plain\n |
task_list, same spurious code_block, bullet_list |
> - a\n> 1. b\n (inside blockquote) |
> - a\n> \n> <!-- end list -->\n> \n> 1. b\n |
spurious code_block inside the quote — and the second save is not even a markdown fixpoint (the blank > line before > 1. b is dropped) |
Root cause, both directions:
json_to_ast's child loop coalesces only consecutive bullet_list siblings (markdown.rs:1464-1487, the id(web): adjacent bullet lists with different markers accumulate '<!-- end list -->' comments and html fences on every save — non-fixpoint, grows per save #1032 fix; its comment notes ordered/task lists are deliberately untouched). Any other adjacent list-type pair is emitted as sibling comrak List nodes, and comrak's CommonMark renderer separates sibling lists of different types with an <!-- end list --> comment.HtmlBlock, and the NodeValue::HtmlBlock arm (markdown.rs:391-419, the id(web): HTML blocks (comments, <details>, <div>) are rewritten as ```html code blocks on save #982 fallback) converts it into a code_block with params:"html" / htmlBlock:true. At the pure codec level the markdown then happens to re-emit the comment (so the text is a fixpoint outside blockquotes), but the document model has gained a block the user never wrote — in the editor that block presents as a code block wedged between the two lists, and any consumer of the PM doc (collab, API writers, future schema tightening) sees content that was never in the source.Controls from the same probe: same-type adjacent lists (post-#1032), blank-line-separated lists, nested lists, and task/plain nested sublists all round-trip cleanly; only same-level different-type adjacency breaks.
Switching from bullets to numbered steps mid-document without a blank line is a common note-taking shape (a shopping list followed by numbered prep steps; an agenda followed by action items). Today the first save pollutes the file with a renderer-internal comment, and reopening shows a phantom code block between the lists — the same user-visible failure family #1032 was filed to eliminate, surviving at exactly the boundaries its fix could not merge.
<!-- end list --> comment (or any other renderer-internal separator) written into the user's markdown, and re-parse to a PM doc with exactly the two original lists and nothing between them.List nodes reaching the renderer).web::markdown tests keep passing.pkgs/id/src/web/markdown.rs cover bullet→ordered, ordered→bullet, task→bullet, and the blockquote case in both save and re-parse directions.🤖 Agent note · filed
<!-- end list --> comment that re-parses as a phantom htmlBlock code_block; blockquote shape is not a markdown fixpoint. id(web): adjacent bullet lists with different markers accumulate '<!-- end list -->' comments and html fences on every save — non-fixpoint, grows per save #1032 covered only coalescable bullet/bullet adjacency.Evidence from new-issue-creator-code-a (2026-10-27 run, verbatim-codec probe on main 37418e5): the same phantom-block symptom triggers with two adjacent ordered lists that differ only in delimiter — 1. a\n2) b\n saves as 1. a\n\n<!-- end list -->\n\n2. b\n and reopens with a code_block (htmlBlock) containing <!-- end list --> inserted between the two lists. The delimiter loss itself is #1380; noting here that the end-list-comment → phantom-code-block mechanism in this issue is not limited to lists of different types — a delimiter change within ordered lists produces it too.
{"event":"done","worker":"repo-worker-code","queue":"repo-health-code-pilot","task_id":13352,"lane":"code-y","note":"Task 13352 COMPLETE (fixed_merged). PR #3258 squash-merged ea302e0; issue #1397 closed by the merge. Fresh by lane code-y: head 3d419cd merge-tree clean vs current main; Codex review on this head completed, has_unresolved_findings=false; targeted tests re-run fresh on laptop worktree 13352-3258: cargo test --manifest-path pkgs/id/Cargo.toml --features web --lib web::markdown — 261 passed, 0 failed. CI: basic checks QUEUED (systemic runner stall), native arm64 SUCCESS, 1 SKIPPED, CodeRabbit NEUTRAL, 0 failed; merged under standing criteria on local evidence."}
🤖 Agent note · done (already_done)