Repository navigation
docs: fix Mintlify MDX validation (unescaped '<' breaks the docs check) - #1791
Conversation
The 'validate' (mintlify validate) check fails on every open PR: seven docs files
have a '<' immediately followed by a digit/'-'/autolink ('<90 MB', '<100ms',
'<1s', 'TS <-> ', '<https://…>'), which the MDX parser reads as a malformed JSX
tag. The first parse error per file also cascades into a false 'plans/agent-ui-
hub-publish file does not exist' nav warning (the file exists but can't build).
Escaped each with </> (rendered text unchanged) and converted the bare
autolink to a markdown link. Mintlify reports only the first error per file, so I
swept fence-aware for ALL out-of-code '<digit' occurrences (11 across 8 files),
not just the 7 reported — avoiding a whack-a-mole CI loop. The no-space form
('< 50 lines') is valid MDX and left as-is.
SummaryClean, well-scoped docs fix: escaping 11 bare Issues Found🟡 Important —
|
The first pass fixed the identical <-> at line 827 but missed line 1083 (Mintlify reports only the first parse error per file). Escape it too so the whole tree is parse-clean and the Mintlify deploy render doesn't choke on it.
…bject The generated changelog copies commit subjects verbatim, and #1791's subject contains a bare '<'. MDX reads it as the start of a JSX tag, so the file failed to parse and its docs.json nav entry then looked missing, failing the check.
…did (amd#2133) Cutting v0.22.0 put the release skill through a real run, and five of its instructions turned out to be wrong. Each one caused a failure or a near-miss during that release, so this corrects them against what actually happened rather than what the doc assumed. The next release should not re-hit any of them. The one that cost the most: the skill told the drafter to trust `validate_release_notes.py`, which is not an MDX parser. It passed a release-notes file that `mintlify validate` then rejected in CI — and the failure disguised itself as `"releases/v0.22.0" is referenced in the docs.json navigation but the file does not exist`. The file existed; it just never parsed, because a generated changelog line carried a bare `<` straight out of a commit subject. ## What changed - **Discord template** — rewritten to the format actually posted (`@gaia` mention, backticked version, fenced install block, bold `What's new` with no colon, `- ` bullets). The old template explicitly asserted the opposite on two of those. Boilerplate updated to "beta release of the UI and the Email Agent". - **Changelog generation** — now escapes `<` and `{` and guards the result, instead of piping `git log` in raw. - **Phase 1** — runs `mintlify validate` too, with a note on the misleading error. - **Phase 3/4** — `gh pr view --json mergeCommitOid` is not a field in current `gh`; it silently returned empty and produced a false *"main has moved past the release commit"*. Now `mergeCommit --jq '.mergeCommit.oid'`. - **Phase 4** — tagged lightweight; every prior release tag is annotated. Now `git tag -a` on the verified SHA, with an assertion before the push. - **Phase 2** — staged four files; the real scope is five (`bump-ui-version.mjs` rewrites `package-lock.json`). ## Test plan Every command added here was run against real v0.22.0 data rather than reasoned about: - [x] The escape fixes the actual hazard: `git log v0.21.2..8eb3516 --pretty=format:'- \`%h\` — %s' | sed -e 's/</\\</g' -e 's/{/\\{/g'` turns amd#1791's `'<'` into `'\<'`. (A first attempt at this sed silently did nothing — it assumed `'<…>'` when the real text is a lone `'<'`.) - [x] `\<` passes `mintlify validate` — probed by substituting the escape form into `docs/releases/v0.22.0.mdx` and re-running the check. - [x] The guard flags raw input and clears escaped input; line counts are preserved (198 in / 198 out). - [x] `gh pr view 2128 --json mergeCommit --jq '.mergeCommit.oid'` returns `8eb3516a…`; the old `mergeCommitOid` form errors with `Unknown JSON field`. - [x] `git cat-file -t v0.21.2` → `tag` (annotated), confirming the lightweight-tag instruction was wrong. - [x] The v0.22.0 release commit carries all five files, confirming the four-file scope was wrong. - [x] Markdown fences balance after nesting the install block inside the template (the outer fence had to become ```` — a plain nested ``` silently truncated the template).
The
validate(Mintlify) check is red on every open PR — not because of those PRs, but becausemainhas seven docs files where a<is immediately followed by a digit /-/ autolink (<90 MB,<100ms,<1s,TS <->,<https://…>). The MDX parser reads each as a malformed JSX tag and aborts the build; the first failure per file also cascades into a false "plans/agent-ui-hub-publishdoes not exist" navigation warning (the file is present but never builds). This unblocks docs validation across all branches.Each
<is escaped to<(rendered output unchanged) and the bare autolink converted to a markdown link. Mintlify only surfaces the first parse error per file, so I scanned fence-aware for every out-of-code<digit(11 fixes across 8 files), not just the 7 reported — so the check goes green in one pass instead of whack-a-mole. The valid no-space form (< 50 lines) is correct MDX and left alone.Test plan
mintlify validate(or thevalidateCI job) passes — no parse errors, no missing-file warning.<90 MBshows as<90 MB, the OAuth link is clickable.grep -rn '<[0-9]' docs/ --include='*.mdx' --include='*.md'outside code fences → none.