Repository navigation
Commit cf82b21
feat(middleware): Serve production build URLs to the evals pin header (#20225)
## DESCRIBE YOUR PR
Production build URLs (`sentry-docs-<hash>.sentry.dev`) now serve their
own pages to requests that have an `x-sentry-evals-pin` header, instead
of 308ing them to docs.sentry.io. Everyone else is still redirected as
in #19033, and these responses still get `X-Robots-Tag: noindex`.
[sentry-for-ai-evals](https://github.com/getsentry/sentry-for-ai-evals)
compares a docs PR's preview with the docs at the PR's merge base, and
that commit's production build is the only copy of those. The redirect
sends the evals to the live docs instead, so a PR that's behind master
gets everything master gained since counted as its own change. The
evals' docs proxy sends the header, and #20214 points the base at the
merge base's build. Like the redirect, the header isn't a security
boundary: previews are already public, and an old build only has docs
that were once live.
Only builds made after this merges check for the header, so older merge
bases keep reading the live docs.
Refs
[VDY-307](https://linear.app/getsentry/issue/VDY-307/onboarding-evals-ai-evals-label-workflow-in-sentry-docs)
## IS YOUR CHANGE URGENT?
Help us prioritize incoming PRs by letting us know when the change needs
to go live.
Select exactly one option. For deadlines, replace `YYYY-MM-DD` with the
due date. You can update this information later by editing the PR
description.
- [ ] Urgent deadline (GA date, etc.): YYYY-MM-DD
- [ ] Other deadline: YYYY-MM-DD
- [x] No deadline: Not urgent, can wait up to 1 week+
## SLA
- Teamwork makes the dream work, so please add a reviewer to your PRs.
- Please give the docs team up to 1 week to review your PR unless you've
supplied a deadline.
Thanks in advance for your help!
## PRE-MERGE CHECKLIST
_Make sure you've checked the following before merging your changes:_
- [ ] Checked Vercel preview for correctness, including links
- [ ] PR was reviewed and approved by any necessary SMEs (subject matter
experts)
- [ ] PR was reviewed and approved by a member of the [Sentry docs
team](https://github.com/orgs/getsentry/teams/docs)
🤖 Generated with [Claude Code](https://claude.com/claude-code)
---------
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>1 parent 6388344 commit cf82b21
2 files changed
Lines changed: 26 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
113 | 113 | | |
114 | 114 | | |
115 | 115 | | |
116 | | - | |
117 | | - | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
118 | 122 | | |
119 | 123 | | |
120 | 124 | | |
| |||
192 | 196 | | |
193 | 197 | | |
194 | 198 | | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
195 | 210 | | |
196 | 211 | | |
197 | 212 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
22 | 27 | | |
23 | 28 | | |
24 | 29 | | |
| |||
73 | 78 | | |
74 | 79 | | |
75 | 80 | | |
76 | | - | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
77 | 85 | | |
78 | 86 | | |
79 | 87 | | |
| |||
0 commit comments