Repository navigation
Description
Summary
The sahajatlas-web Sentry project has received zero events, all time — seven weeks after #108
(closed by #123) wired reportInternalError to it. The widget runs inside other people's pages,
where we have no logs of any kind, so Sentry is our only production signal, and it is silent.
Nothing in the code is broken. reportingDsn() (src/lib/report.ts:254-258) returns null when
VITE_SENTRY_DSN is empty and the SDK is then never fetched — exactly as designed.
The production deploy confirms it: VITE_SENTRY_DSN is unset on the sahajatlas Pages
Production environment, so the seam #123 built has never been live.
Evidence
Unbounded and 14-day windows both return nothing:
curl -s "https://de.sentry.io/api/0/projects/sy-developers/sahajatlas-web/issues/?query=&statsPeriod=" \
-H "Authorization: Bearer $SENTRY_CLAUDE_WORKFLOW_TOKEN" | jq length
# → 0The same call returns 37 for sahajcloud and 1 for wemeditate-web, so the token, the region
host and the project slug are all fine.
The deployed production bundle names no ingest host. Read back on 2026-09-29 from
https://sahajatlas.pages.dev, the standalone eager graph (six /assets/*.js files) plus
embed.js, auto.js and assets/element-*.js contain no ingest substring and no
https://…sentry… literal. The same fetch finds https://cloud.sydevelopers.com/api, so the read
is not vacuous, and it finds report.ts's own literals (Refusing to link to, captcha-blocked),
so the seam ships — only the DSN is missing. This settles the diagnosis without opening a
dashboard.
Reporting is wired at ten call sites (src/App.tsx:101 and :265, src/Widget.tsx:152,
src/config/locale.ts:96, src/components/molecules/Fallbacks/Fallbacks.tsx:1004 and :1063,
src/components/atoms/Link/Link.tsx:111, src/components/atoms/Button/Button.tsx:219,
src/components/molecules/ActionRow/ActionRow.tsx:124,
src/hooks/use-recovery-offer.ts:117), plus reportIntegrationWarning. A failed locale fetch or
any render crash on any host site would report. None has.
Approach
VITE_SENTRY_DSN is build-time — Vite inlines it — so it has to exist in the Cloudflare Pages
dashboard before a build. A run cannot set it: this repo holds no Cloudflare credentials.
Phase 1 is therefore a human dashboard action, and it must land before Phase 2 merges, or the
new assertion is a red gate on every PR.
Phase 1 — provision (dashboard, human)
- Set
VITE_SENTRY_DSNon thesahajatlasPages Production environment, in the modern
public-key formhttps://<key>@o<n>.ingest.de.sentry.io/<project>. The org is DE region
(de.sentry.io), not US. - Set it on Preview too — see Open questions, which the acceptance criteria below already
decide.
Phase 2 — make the silence detectable (this repo)
-
Add the smoke assertion.
tests/smoke/boot-origins.smoke.test.tsalready reads the eager
graph off the deploy and asserts each origin the bundle will request; add the ingest host as a
sibling entry in itsREQUEST_ORIGINSlist. A missing match must fail, not pass vacuously —
that file'srequestOrigins()already enforces exactly that, so follow it rather than writing a
new shape. Verified locally: built with a DSN, the literal lands indist/assets/Spinner-*.js,
which sits in both the standalone and theembedeager graphs, so one read covers both, and
pnpm sizestays green (standalone 301.9/308 KiB, embed 303.7/308 KiB).⚠ This spec can only ever see a preview.
scripts/get-cloudflare-preview-url.mjs:169
refuses the bare project host because "that is PRODUCTION, not any preview". So the assertion
proves Preview carries a DSN and says nothing about Production. That is not a reason to skip it
— Preview and Production are one build config away from each other, and the failure this ticket
is about is a variable absent from an environment — but the acceptance criteria must not claim
more than it proves. -
Name the Sentry environment explicitly.
src/lib/report.ts:332sets
environment: import.meta.env.MODE, which isproductionfor everyvite build, preview
included. With a Preview DSN, preview noise would be indistinguishable from production in the
issue list. Take the environment from a variable Cloudflare can vary per environment instead,
and default it toproduction. This also fixes the cross-repo inconsistency in Notes. -
Correct
docs/environment.md:23. Three claims in that one row are stale:- it says to add the ingest host to "the integrator CSP guidance in
README.md" — the CSP table
lives indocs/embedding.md:796-813; - it gives the regional host as
o….ingest.us.sentry.io— this org is DE; - it says "Hosts can decline it per embed with
error-reporting="false"" — that veto is gone
(src/loader/config.ts:29: "There are no privacy opt-outs"), andsrc/lib/report.ts:247-253
plussrc/lib/report.sentry.test.ts:131both say the DSN is now the only gate.
Record which environments hold the DSN in the same row, and state the Preview posture either
way. Runbook step 1 (docs/environment.md:54) should stop reading "skip if already set" as an
unchecked branch. - it says to add the ingest host to "the integrator CSP guidance in
No CSP change is needed. docs/embedding.md:802 already carries *.sentry.io in the
connect-src row, and :811-813 explains the wildcard is that wide precisely so a regional host
(…de.sentry.io) matches. #123 did this. Delete this step rather than re-doing it.
Open questions
- Should Preview carry a DSN too? Yes, and the acceptance criteria already require it — the
smoke lane is the only automated observer, and it can reach nothing but a preview. Preview
noise is the cost, bounded byMAX_EVENTS_PER_PAGE(src/lib/report.ts:240) and by the
explicit environment tag in Phase 2 step 4. Overturn this only by moving the detection out of
the smoke lane, which nothing currently supports.
Acceptance criteria
- The
sahajatlasPages Production environment holds a non-emptyVITE_SENTRY_DSN, and the
deployed production bundle names its ingest host. - The Preview environment holds one too, so the smoke lane can observe it.
- A deliberately thrown widget-root error arrives in
sahajatlas-webcarrying itsErrorKind
tag. The thrown error must classify toserver,configorunknown:offline,
not-foundandcaptcha-blockedare never reported (src/lib/report.ts:201-212). - Preview events are distinguishable from production ones in the Sentry issue list.
-
boot-origins.smoke.test.tsfails when the deploy under test carries no DSN, and fails —
rather than passing empty — when the pattern stops matching. -
docs/environment.mdrecords which environments hold the DSN, states the Preview posture,
and carries none of the three stale claims listed above.
Verification checklist
-
curl -s "https://de.sentry.io/api/0/projects/sy-developers/sahajatlas-web/issues/?query=&statsPeriod=14d" -H "Authorization: Bearer $SENTRY_CLAUDE_WORKFLOW_TOKEN" | jq lengthreturns more than0after a test error. -
VITE_SENTRY_DSN="https://[email protected]/1" pnpm build && grep -rlF ingest.de.sentry.io dist/assetsnames at least one chunk. Confirmed today: it namesdist/assets/Spinner-*.js. -
pnpm build && grep -rlF ingest dist/assetswithVITE_SENTRY_DSNunset names nothing. -
PREVIEW_URL=<a preview built without the DSN> pnpm test:smokefails onboot origins. -
curl -s https://sahajatlas.pages.dev/embed.jsand itsassets/*.jsimports name the ingest host, after the next production deploy. -
pnpm lint && pnpm typecheck && pnpm test:runpass, andpnpm build && pnpm sizestays inside budget.
Notes
Found by the Tuesday Sentry survey (survey-sentry), 2026-09-29 — by the absence of data, not by an
error.
#108 wired the seam and explicitly left the DSN as a variable to document, not to provision. Its
own summary opens with "there is zero production error signal". That is still true, and this
ticket is the missing step plus the check that would have caught it.
No Sentry: link: there is no Sentry issue to point at, which is the finding.
Incidental: wemeditate-web reports under the environment name production-frontend, while
sahajcloud uses production. A sweep filtered on environment=production silently skips
WeMeditateWeb. Phase 2 step 4 is this repo's half of that; the other two repos are not in scope
here.
🤖 Written by the sydevs autonomous loop — see what this is
Metadata
Metadata
Assignees
Labels
Type
Fields
Priority
Hold Until
Projects
- StatusShow more project fieldsDone
Activity
sydevs-bot commentedon Sep 29, 2026
🤖 no session running
recent dispatches
Written by the sydevs dispatcher. Sessions never edit this comment.
sydevs-bot commentedon Sep 29, 2026
Revised from the code and from the live deploy.
sahajatlas.pages.devnames no ingest host, while it does namecloud.sydevelopers.com/apiandreport.ts's own literals. The seam ships. Only the DSN is missing.docs/embedding.md:802already carries*.sentry.io, and:811says why the wildcard covers…de.sentry.io.scripts/get-cloudflare-preview-url.mjs:169refuses production. So the open question is answered: Preview needs a DSN, or nothing automated observes this.src/lib/report.ts:332usesimport.meta.env.MODE, which isproductionfor everyvite build. Preview events would be indistinguishable.Priority raised Medium → High: this is our only production signal. Effort stays Moderate. Type unchanged.
@sydevs-bot implementstarts the work.🤖 Written by the sydevs autonomous loop — see what this is
Generated by Claude Code
Ardnived commentedon Oct 2, 2026
@sydevs-bot implement
fix(docs): drop the unearned Sentry DSN claim
Merge origin/main into claude/fix-232-sentry-dsn