fix(eql-docs): strip Doxygen <tt> tags so a stray one can't break the build#52
Merged
Conversation
… build The EQL reference generator fetches the latest release's API.md at build time and passes lowercase-led tags (e.g. `<tt>`) through as real HTML. MDX requires every tag to be balanced, so a mangled SQL-comment source that emits an unclosed `<tt>` fails the whole Vercel build — which is exactly what eql-3.0.0-alpha.3 did (index.mdx:2153, `Expected a closing tag for <tt>`). `<tt>` is Doxygen's teletype tag; MDX doesn't need it. Strip `<tt>`/`</tt>` (non-code text only) before escaping, so malformed upstream docs degrade gracefully instead of taking the deploy down. Verified: regenerated content/stack/reference/eql/index.mdx from the live eql-3.0.0-alpha.3 release and `next build` compiles all 329 pages.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
coderdan
added a commit
that referenced
this pull request
Jul 8, 2026
The `auth regions --json` flag description is "Emit machine-readable
[{ slug, label }] ...". MDX parsed `{ slug, label }` as a JS expression,
so prerendering /reference/cli/auth threw `ReferenceError: slug is not
defined` and failed the build. (The earlier `<tt>` failure masked this;
it surfaced once #52 landed via rebase.)
Escape `{`/`}` (and stray `<`) in manifest-derived prose — flag
descriptions and summaries. Flag names/values stay in code spans, which
are literal, so they're untouched. Verified: `next build` prerenders all
355 pages, including /reference/cli/auth.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Vercel builds started failing on every v2-lineage branch (first seen on PR #45):
scripts/generate-eql-docs.tsregenerates that page duringprebuildfrom the latestencrypt-query-languagerelease'sAPI.md. Its escaper deliberately passes lowercase-led tags (<tt>) through as real HTML, but MDX requires every tag to be balanced.eql-3.0.0-alpha.3(published today) has a mangled SQL comment whose Doxygen output emits a stray, unclosed<tt>at line 2153 — taking down the whole build.This is not specific to #45: any branch (and
main) that rebuilds while alpha.3 is the latest release hits it.Fix
Strip Doxygen's
<tt>/</tt>teletype tags (non-code text only) before escaping. MDX doesn't need the tag, so malformed upstream docs now degrade gracefully instead of failing the deploy. One-line change inescapeMdxSpecials.Verification
content/stack/reference/eql/index.mdxfrom the live eql-3.0.0-alpha.3 release →<tt>count is 0; line 2153 is valid MDX.next buildcompiles cleanly, all 329 static pages generated.scripts/generate-eql-docs.tschanges; the committed page snapshot is left as-is (it's build-regenerated).Notes
mainis exposed too (same generator +generate-docs:eqlin itsprebuild), so a production redeploy would hit this. Recommend porting this fix tomainas well — happy to open that PR.'sel'::textrendered as'seltext); that's a Doxygen/SQL-comment issue for the EQL repo to fix. This PR only stops it from breaking the docs build.