[TOC] Fix 56 rendered-heading scrape failures from deprecated container renderer imports - #32580
Open
mvvmm wants to merge 1 commit into
Open
[TOC] Fix 56 rendered-heading scrape failures from deprecated container renderer imports#32580mvvmm wants to merge 1 commit into
mvvmm wants to merge 1 commit into
Conversation
Contributor
|
This pull request requires reviews from CODEOWNERS as it changes files that match the following patterns:
|
kodster28
approved these changes
Aug 6, 2026
Contributor
Author
|
/rebase |
Contributor
Review✅ No issues found in commit Code ReviewThis code review is in beta and may not always be helpful — use your judgment. No code review issues found. ConventionsNo convention issues found. Style Guide ReviewNo style-guide issues found. CommandsOnly codeowners can run commands. Post a comment with the command to trigger it.
|
…renderer imports
Replace deprecated loadRenderers([getContainerRenderer()]) +
AstroContainer.create({ renderers }) with AstroContainer.create({}) +
container.addServerRenderer() using direct server.js imports, matching
the pattern already used in src/util/container.ts.
The deprecated loadRenderers/getContainerRenderer API path failed with
ERR_UNSUPPORTED_ESM_URL_SCHEME (protocol 'astro:') for 56 pages using
AnchorHeading. The addServerRenderer approach properly registers
renderers without triggering the astro: virtual import resolution failure.
Results:
- TOC scrape failures: 56 → 0
- Deprecated renderer import type hints: 4 → 0
- No new build warnings, 8802 pages built successfully
cloudflare-docs-bot
Bot
force-pushed
the
fix/toc-scrape-renderer-imports
branch
from
August 6, 2026 22:30
6610f1e to
399aae8
Compare
mvvmm
marked this pull request as ready for review
August 6, 2026 22:31
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.
What changed
src/util/rendered-toc.tsused the deprecatedloadRenderers([getContainerRenderer()])+AstroContainer.create({ renderers })API to render MDX pages at build time for TOC heading extraction. This path failed withERR_UNSUPPORTED_ESM_URL_SCHEME: Received protocol 'astro:'for 56 pages that useAnchorHeading(which emits headings at runtime viaset:html).Replaced with
AstroContainer.create({})+container.addServerRenderer()using directserver.jsimports — the same pattern already used insrc/util/container.ts.Results
Checklist
pnpm run check— 0 errorspnpm run build— 8,802 pages, no new warningspnpm exec prettier— clean