-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Only 404 lint unique files #15452
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Only 404 lint unique files #15452
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Bundle ReportChanges will decrease total bundle size by 2.68MB (-11.54%) ⬇️. This is within the configured threshold ✅ Detailed changes
Affected Assets, Files, and Routes:view changes for bundle: sentry-docs-server-cjsAssets Changed:
Files in
Files in
App Routes Affected:
view changes for bundle: sentry-docs-client-array-pushAssets Changed:
|
031b627 to
14b3bcf
Compare
e0971c7 to
f9e23b6
Compare
- Extract lightweight frontmatter module to avoid bundling mdx-bundler - Add aggressive outputFileTracingExcludes for build dependencies - Update source-map API route to use lightweight imports
3fc8ae2 to
424c688
Compare
| @@ -1,7 +1,7 @@ | |||
| import type {MetadataRoute} from 'next'; | |||
|
|
|||
| import {getDevDocsFrontMatter, getDocsFrontMatter} from 'sentry-docs/frontmatter'; | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bug: Sitemap excludes critical API documentation.
The sitemap changed its import from sentry-docs/mdx to sentry-docs/frontmatter, but the new frontmatter.ts module doesn't include API-generated pages (like API categories and endpoints) that the original mdx.ts implementation adds. This causes the sitemap to exclude all dynamically-generated API documentation pages that were previously included.
| ) | ||
| ); | ||
|
|
||
| return allFrontMatter; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bug: Frontmatter Collection Incomplete, Pages Vanish
The new getDocsFrontMatterUncached implementation only collects regular documentation files but completely omits the processing of common files for platforms and guides that the original src/mdx.ts implementation includes. This means thousands of pages generated from common source files (the core feature this PR is about) won't be included in the frontmatter collection, breaking the deduplication functionality and causing missing pages in the sitemap and source-map.
DESCRIBE YOUR PR
The 404 link checker GitHub Action was processing over 9,000 pages despite the repository containing only ~2,000 source files. The Sentry docs use a "common files" architecture where a single source file generates multiple URLs across platforms and guides and we were checking every generated page independently.
Also optimized the cache strategy and made moves to what's bundled during the build to avoid Vercel's 250MB limit on serverless function size.
Implemented source-based deduplication using the existing /api/source-map endpoint:
That gets us...
IS YOUR CHANGE URGENT?
Help us prioritize incoming PRs by letting us know when the change needs to go live.
SLA
Thanks in advance for your help!
PRE-MERGE CHECKLIST
Make sure you've checked the following before merging your changes:
LEGAL BOILERPLATE
Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. and is gonna need some rights from me in order to utilize my contributions in this here PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.
EXTRA RESOURCES