release runner: read Communique Markdown as CommonMark, not line by line

Open
#589 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
56/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
javascript, node.js
Domain
release

Research direction

Start with scripts/release-please-runner.js, especially normalizeCommuniqueBody and findLineOutsideFences, then inspect the existing draft check that uses pinned commonmark.js. Reproduce the listed setext, ATX, CR-only, and HTML-comment cases with the real Communique binary, and check the frozen historical entries. Done means the cases pass and those historical outputs remain byte-identical.

Written by the indexing model from the issue text.

Description

needs-triage

The release runner reads Communique Markdown line by line, not as CommonMark.

Verified on main with require("./scripts/release-please-runner.js").normalizeCommuniqueBody(body):

  1. A setext heading (Features over -------- or ========) and an ATX H1 (# Features) are not demoted, because the code demotes only lines that start with ## . Body "Features\n--------\n\n- A\n".
  2. The leading version-heading regex /^#{1,3} \[?v?\d[^\n]*\n*/ is LF-only. Body "## 0.4.0\r- A\r- B\r" comes back as "", so the entry becomes the placeholder "Maintenance release with no user-facing changes." and the notes are lost.
  3. A ## note line inside a multi-line HTML comment is rewritten to ### note. Body "<!--\n## note\n-->\n\n- A\n".

Also check the title finder findLineOutsideFences and CR-only heading handling in the same pass.

Planned fix. Parse the body with commonmark.js (already a pinned devDependency used by the draft check). Drop the leading version heading and demote headings by block, setext and H1 included. Replace the line-based title finder the same way. Test each case with the real Communique binary, and keep the output of the frozen historical entries byte-identical.

Owner: the next change to the release runner, with the second-pass issue filed next to this one. Deferred from the README verification run with the maintainer's agreement.


Generated with xum • Model: anthropic:claude-opus-5-5 • Thinking: high

Dominant language
Lua
Stars
3.2k
Forks
223
Avg merge
6h 7m
Merged PRs (30d)
210

Getting set up

Open in Codespaces

Starts the project's dev container in your browser, under your own GitHub account.

  • No Dockerfile or Docker Compose file
  • No pull request template
  • No contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from coder/claudecode.nvim

All issues in coder/claudecode.nvim

Similar issues

More Lua issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.