Skip to content

ci(smoke): read the production domain, not only a preview - #248

Merged
sydevs-bot merged 9 commits into
mainfrom
claude/chore-244-production-smoke
Oct 6, 2026
Merged

sydevs-bot merged 9 commits into
mainfrom
claude/chore-244-production-smoke

Conversation

@sydevs-bot

@sydevs-bot sydevs-bot commented Oct 3, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • The 16 smoke specs now run against sahajatlas.com after each production deploy.
  • A red read opens one issue as sydevs-bot, so a production failure reaches a queue instead of
    one inbox.
  • No spec changes, no src/ changes, and ci.yml's on: block is untouched.
  • The base URL is a bare literal with no expression in it, and ci-workflows.test.ts now pins it
    as one.

Note

The standing red is gone: #148's dashboard half landed, and the lane now reads 16/16. Browser
Cache TTL on the sahajatlas.com zone respects existing headers, and #148 closed 2026-10-06.
Measured on this head 2026-10-06: /auto.js and /embed.js both serve
public, max-age=0, must-revalidate, which is what public/_headers pins, and all 16 specs pass
against sahajatlas.com. Merging leaves no red check. The lane found that defect on its first
run, four hours of freshness on the unhashed files hosts hardcode — a thing no preview could have
shown, since *.pages.dev sits outside the zone.

Note

The merge-order warning this body carried is spent: #247 landed first. That is the order the
warning called reversed, so this branch followed its own instruction and dropped the
scripts/audit-baseline.json commit rather than resolving in its favour. tailwindcss 4 took
every path to braces out of the production graph, so booking GHSA-vfj7-8cjw-p6xm would have
pinned an advisory nobody reports — the one state the weekly audit.yml --strict run fails on.
The baseline is not in this diff. Measured on this head 2026-10-05: pnpm audit:check reports 0
critical, 0 high, 0 new, and --strict is green too.

Change outline

Files — one workflow, one spec, two docs

.github/workflows/production-smoke.yml    NEW  the lane: trigger, filters, the read, the alert
scripts/ci-workflows.test.ts              NEW  pins what the lane names and when it alerts
docs/testing.md                                "The PR gate can only ever read a preview"
AGENTS.md                                      one clause beside the CI gates

Flow — what fires, what it reads, and who hears a red

check_run.completed                             any check run in the repo
  conclusion == success
  app.slug starts with 'cloudflare'
  name == 'Cloudflare Pages: sahajatlas'        # not the -design playground
  head_branch == default_branch
    OR check_suite.head_sha == github.sha       # a null head_branch cannot silence the lane
  → job runs                                    else SKIPPED, never a green run
    PREVIEW_URL: https://sahajatlas.com         # job-level scalar; no input, no expression
      empty → exit 1                            # unreachable today, armed for the edit that isn't
      summary names the host                    # before the specs, so a red run names it too
      pnpm test:smoke                           # the PR lane's own 16 specs
    specs red → open or update ONE issue        # as sydevs-bot, found by the production-red label
      checkout/install red → no issue           # nothing read production, so nothing claims it did

Behaviour — why not what the ticket specified

-trigger: deployment_status, gated on the production environment
+trigger: check_run, gated on the app project and the default branch
   # get-cloudflare-preview-url.mjs: Cloudflare posts neither commit statuses
   # nor GitHub deployments on this repo (PR #120). A workflow on an event that
   # never arrives is invisible — no red check, no annotation, nothing to notice.
-base URL: github.event.deployment_status.environment_url
+base URL: https://sahajatlas.com, a literal
   # The host is what docs/embedding.md tells integrators to use, and it does
   # not vary — so the event is a clock, not a source. A URL out of a payload
   # would re-open #138 (any App with deployments:write posts one) for a constant.
-host read: sahajatlas.pages.dev
+host read: sahajatlas.com
   # public/_headers: the two can differ, and #148 "was invisible on the host
   # every check runs against". Previews are *.pages.dev already.

Preview

No src/ file changes, so the deploy is byte-identical to main's apart from the build id.

Test results

  • Lean gate: ✓ pnpm lint, pnpm typecheck, pnpm test:run (1636 passed, 129 files) — re-run on
    this head 2026-10-06
  • Targeted specs: ci-workflows.test.ts 4 passed, each watched failing against its own
    reintroduced defect — the host pointed back at *.pages.dev, the check-run name pointed at
    -design, the alert's token swapped to secrets.GITHUB_TOKEN, and its gate widened to a bare
    failure(). A fifth defect is pinned by the host regex: restoring an expression in PREVIEW_URL
    fails the file at collection, exit 1 with no tests run
  • Alert step: driven locally through a stub gh on all three paths — no open alert (files one),
    an open alert (comments on it), and no PAT (annotates and stays red). Both rendered bodies
    verified, backticks intact
  • Smoke lane, re-measured 2026-10-06 on this head: sahajatlas.com 16/16, run twice.
    sahajatlas.pages.dev 16/16, sahajatlas-design.pages.dev 6/16 — so the lane is still
    not vacuously green on any of the three. The custom domain was 14/16 until chore(build): stop the sahajatlas.com zone overriding the loader's Cache-Control #148's zone fix
  • pnpm audit:check: ✓ 0 critical, 0 high, 0 new, and --strict ✓. The baseline is now main's
    unchanged, since chore(deps): upgrade tailwindcss 3 → 4, which is also the exit from the unpatched braces advisory #247 took the advisory out of the production graph
  • Build: N/A — no src/ file changed, so pnpm size is unaffected
  • Security review: skipped, no path matches securityReview.triggerPattern. Two security-relevant
    decisions are in the outline and the Detail: the base URL is a bare literal, so nothing this job
    does not control chooses the host it reads; and the alert step holds SYDEVS_BOT_PAT while
    permissions: stays contents: read, so the job's own token gains nothing

Manual verification

  1. Set Browser Cache TTL to "Respect existing headers" on the sahajatlas.com zone.
    Done — chore(build): stop the sahajatlas.com zone overriding the loader's Cache-Control #148 closed 2026-10-06, and the lane reads 16/16 against the zone since.
  2. After the first merge to main, check the Actions tab for one Production Smoke run fired
    by Cloudflare Pages: sahajatlas. If none appears, the if is wrong rather than the lane: read
    a real check_run payload and widen it. Nothing in the repo can settle that before a merge.
  3. Confirm SYDEVS_BOT_PAT reaches this workflow and can write issues. Nothing local can: the
    secret is an org secret and the step only runs on a red read. The first red run is the test —
    if the step annotates "No SYDEVS_BOT_PAT", the secret is not exposed to this repo's own
    workflows and the alert needs that fixed before it is worth anything.
  4. Confirm the skipped runs are tolerable. Every check run in the repo now queues one; they consume
    no runner minutes, but they do appear.

Notes for reviewer

  • The red-run alert is new, on your go-ahead in-thread. It is the recommendation from the
    comment above, unchanged: one issue, filed as me, commented on rather than refiled while the red
    persists. I added no issues: write to permissions: — a PAT is not governed by it, and
    contents: read stays as it was.
  • This deviates from chore(ci): nothing automated observes the production deploy, only a preview #244's approach on two points, both stated in the outline: the trigger and
    the base URL. The acceptance criteria asked for a deployment_status run naming the URL "from the
    event — not from a literal". The ticket flagged both as unverified and said to read them off a
    real deployment first; no MCP tool exposes the deployments API, and the repo's own measurement
    says there are none to read. The goal — something automated reads production, and cannot go green
    without having read it — is met. If you want the ticket's mechanism instead, say so and it is a
    small change.
  • The lane reads one host, not both. Previews are *.pages.dev, so the PR gate already covers
    that side; the custom domain is the uncovered one.
  • chore(build): stop the sahajatlas.com zone overriding the loader's Cache-Control #148 is closed, and this lane is what will keep it closed. Its repo half was already in
    main; the zone setting that was overriding it landed 2026-10-06. Nothing in the repo could have
    observed either, which is the argument for the lane.
  • The adversarial review's four findings are all answered in-thread, and every thread is now
    resolved.
    Three are fixed in a commit each. The fourth was the baseline collision, settled by
    chore(deps): upgrade tailwindcss 3 → 4, which is also the exit from the unpatched braces advisory #247 landing first — see the note above.
Detail

Why the gap is structural, not a coverage hole. VITE_* values inline at build time, and Pages
builds Preview and Production from separate dashboard environments, so the bundle the PR gate reads
can never carry Production's values. boot-origins.smoke.test.ts records that hole one way round:
VITE_HOST set in Production, unset in Preview, every preview a blank page while all six specs
stayed green. Running the PR gate more often closes neither direction.

Why the alert is an issue, and why it files as me. No handler is reachable from this lane by
any route: workflow-state.yml subscribes workflow_run to CI alone, and the dispatcher maps a
CI event to open PRs whose head is that commit — a merge commit on main has none. So the lane
writes the target itself. It uses SYDEVS_BOT_PAT rather than the job's token because the
dispatcher's worklist labels key on the author: an issue from github-actions[bot] would be filed
and still reach nobody's queue, a failure invisible from this repo because the issue exists. One
alert, not one per deploy, because a production red outlives the deploy that found it — #148 lasted
days. The open alert is found by its production-red label, not its title or body, because a
bot-filed ticket has both rewritten before a human reads it. Nothing closes the alert: a green
hand-run, or one green read of a flaky spec, would close a real one.

Why no schedule:. The lane reads deployed file content, which changes only at deploy. A
daily cron re-reads an unchanged artifact about 364 times a year for one real signal per merge, and
is still up to 24 hours late. A push trigger fires before the deploy exists, and nothing here can
wait for it. Discovery exists for exactly that wait and refuses the production host by construction.

Why no concurrency group. Two production reads at once cost a few dozen CDN requests.
cancel-in-progress would instead throw away a verdict already paid for — and with a constant
group, any skipped run entering it could cancel a live read.

Why every filter is in the job's if. A non-production event skips the job, so there is no
conditional step inside and no path by which the job reports green having read nothing. The empty-URL
guard shares its step with pnpm test:smoke for the same reason. The alert step is the one if:
in the job, and it narrows rather than widens: steps.smoke.conclusion == 'failure', so a checkout
or install failure files nothing.

No workflow_dispatch input, and that is the security line. An input is the one thing that can
make the base URL something other than the literal — it hands the choice of host to anyone who can
dispatch a workflow, and a green Production Smoke check is worth forging for exactly the reason
#138 records: pages.dev subdomains are first-come-first-served. The hand-run Manual verification 1
asks for still works, and reads production like every other run. The empty-URL guard stays, now
honestly labelled: it cannot fire against a literal, and exists for the edit that would make it
able to.

Rejected: a resolver script. The first draft took the URL from the event and spent a 120-line
script plus 15 specs deciding whether the deploy was production, with pick() imported as a host
gate. Reviewing it turned up two defects of its own — a newline in environment_url clears the host
gate and then forges a second target_url= line in $GITHUB_OUTPUT, and an environment name merely
containing "production" would have reported a preview as the production read. Both existed only
because an untrusted URL was being accepted for a value that does not vary. The literal deletes the
script, both defects, and the hedge.

What ci-workflows.test.ts buys. The lane's logic is a workflow expression no local run can
evaluate, so the spec pins the four things that fail silently. Two live elsewhere: the host against
docs/embedding.md's "the production domain" row, and the check-run title against ci.yml's
CF_PROJECT slug — otherwise the lane reads a host nobody embeds from, or waits on a check run
nobody posts again. Two live in another repo's rules: the alert's token, because the wrong one
still files an issue, and its gate, because a widened one claims production is red when nothing
read it. Its host regex matches a bare scalar, so it also pins the absence of an expression.
PREVIEW_URL moved to the job for the same reason — the alert names the host the specs read, and
two spellings of a constant drift while the spec pins exactly one.

Dropped: a Sentry DSN bullet in docs/environment.md. It claimed Production Smoke checks the
Production DSN. boot-origins.smoke.test.ts's REQUEST_ORIGINS holds one entry, the SahajCloud
API, so there is no ingest origin to miss until #232 (PR #245) adds one — and a reader following
that runbook would have skipped the only check there is. The bullet belongs in #245. The file now
leaves this diff entirely.

The lane's header was 27 lines and is 10. It restated the docs/testing.md section its own
second line points at — the #148 max-age measurement, the deployment_status deviation, the
filters-in-if reason. Two copies of one argument drift apart. What stayed is what a reader of the
workflow alone cannot get from the pointer: the absent concurrency group, and the two-condition
branch gate, moved down to the if: it explains. Every #NNN cut from the header is live at the
file it now points at.

Reviewed with /simplify (four lenses) plus /code-review high; pr-review-toolkit is not
installed here. comment-lint.mjs clean. The code review's two findings — the wrong host, and an
overclaim in docs/environment.md about typo detection that boot-origins.smoke.test.ts does not
do — are both fixed rather than dismissed.

Closes #244

🤖 Written by the sydevs autonomous loop — see what this is


🤖 Generated with Claude Code

https://claude.ai/code/session_0185rnixqGMn3BApUyF34Ka2

Every automated check in this repo read a preview. `ci.yml` fires on
`pull_request` and `merge_group` only, and `provenanceOf` demotes the bare
project host to `loose`, which `pickPreview` never selects — so discovery
cannot name production even by accident.

The gap is structural, not a coverage hole. `VITE_*` values inline at build
time and Pages builds Preview and Production from separate dashboard
environments, so the bundle the PR gate reads can never carry Production's.
`boot-origins.smoke.test.ts` records that hole one way round: `VITE_HOST` set
in Production, unset in Preview, every preview a blank page while all six
specs stayed green.

The specs are the PR lane's own, unchanged.

It reads `sahajatlas.com`, the custom domain, because that is the host
`docs/embedding.md` tells integrators to use and the one whose headers
nothing has ever checked. The two hosts serve one build and two sets of
headers: `public/_headers` records `max-age=14400` on the custom domain
against `max-age=0` on `*.pages.dev`, and says that #148 defect "was
invisible on the host every check runs against". Previews are `*.pages.dev`
already, so a production lane there would inherit the same blindness. The
host is a constant, which is also why the event is a clock rather than a
source of a URL: a URL out of a payload would re-open #138's question for a
value that does not vary.

The trigger is Cloudflare's check run, not the deployment status #244
specified. That is the one Cloudflare signal this repo has measured as
present — `get-cloudflare-preview-url.mjs`'s header records both the
commit-status and the deployment query coming back empty here (PR #120) — and
a workflow on an event that never arrives is invisible: no red check, no
annotation, nothing to notice. The cost is a skipped workflow run per check
run in the repo, the shape `workflow-state.yml` already accepts.

Every filter sits in the job's `if`, so a non-production event skips the job
instead of reaching a step that would report green having read nothing. The
one guard left inside shares its step with the specs: an empty base URL makes
every spec skip itself, so it must fail the job rather than hide.

Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01Lz6pvBpM7yy6xwr7i7FMKn
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Oct 3, 2026 •

Copy link
Copy Markdown

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Oct 3, 2026 •

Copy link
Copy Markdown

Deploying sahajatlas with  Cloudflare Pages  Cloudflare Pages

Latest commit: 735b93a
Status: ✅  Deploy successful!
Preview URL: https://07dceab2.sahajatlas.pages.dev
Branch Preview URL: https://claude-chore-244-production.sahajatlas.pages.dev

View logs

@sydevs-bot sydevs-bot added the bot:working Lock: a cloud session is running on this item. Removed when it ends. label Oct 3, 2026
@sydevs-bot

sydevs-bot commented Oct 3, 2026 •

Copy link
Copy Markdown
Contributor Author

🤖 no session running
CI fix 1

recent dispatches
  • 19:36Z address-review · attempt 1 · session · done
  • 19:36Z address-review · attempt 1 · session
  • 19:22Z address-review · attempt 1 · session · done
  • 19:22Z address-review · attempt 1 · session
  • 05:32Z address-review · attempt 1 · session · done

Written by the sydevs dispatcher. Sessions never edit this comment.

GHSA-vfj7-8cjw-p6xm (high, 7.5) landed against `braces` and failed the
Dependency Audit gate. It is not this PR's: the branch touches one workflow,
one spec and three docs, and no dependency file, so `main` reports the same
finding against the same lockfile. It is still fixed here, because the gate
is per-PR and nothing else will see it first.

There is nothing to update to. The advisory covers `<=3.0.3` with
`patched_versions: <0.0.0`, and 3.0.3 is braces' latest release — so an
in-range `pnpm update`, a pin, and a `pnpm.overrides` entry all have no
target. That leaves the gate's own documented escape hatch: the id, the
package, and the ticket that owns the fix. #246 already owns it, since
tailwindcss 4 drops all three dependents (chokidar, fast-glob, micromatch).

`pnpm.auditConfig.ignoreGhsas` would also have gone green. check-audit.mjs
rejects it by name: it suppresses at the source and records no owner, which
is the thing the baseline exists not to be.

Watched the entry fail before trusting it — a wrong GHSA id in the baseline
leaves the gate red, so the match is on the id and not on the file merely
being non-empty. `--strict` (the weekly run) stays green too, and prunes
this line the day a patch ships.

Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01Gm5XE7MmgGzempcsgTopxw
@sydevs-bot sydevs-bot added bot:working Lock: a cloud session is running on this item. Removed when it ends. and removed bot:working Lock: a cloud session is running on this item. Removed when it ends. labels Oct 3, 2026

@sydevs-bot sydevs-bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧐 Adversarial review

Right shape, and smaller than #244 asked for. Both deviations improve on the ticket: the check run is the signal this repo has measured, and a literal host closes #138's question for a constant. One scope problem — the braces booking is #246's, and PR #247 is open on the same lines.

Decide the merge order first. Merging today leaves Production Smoke standing red until the sahajatlas.com zone stops overriding _headers.

Findings:

  • should-fix — audit-baseline.json:28 collides with PR #247.
  • should-fix — environment.md:92 claims a check that does not exist.
  • should-fix — the workflow header restates docs/testing.md.
  • consider — the url input weakens the literal-host invariant.

Checked: all 6 files of origin/main...06f7c06; #244, #246, #247's baseline patch; whole production-smoke.yml, ci-workflows.test.ts, boot-origins.smoke.test.ts, vitest.config.ts, _headers, ci.yml. The new spec does run in the unit lane, its regexes match their sources, and REQUEST_ORIGINS holds one entry.

🤖 Written by the sydevs autonomous loop — see what this is


Generated by Claude Code

Comment thread scripts/audit-baseline.json Resolved
Comment thread docs/environment.md Resolved
Comment thread .github/workflows/production-smoke.yml Resolved
Comment thread .github/workflows/production-smoke.yml Resolved
@sydevs-bot sydevs-bot added bot:working Lock: a cloud session is running on this item. Removed when it ends. and removed bot:working Lock: a cloud session is running on this item. Removed when it ends. labels Oct 3, 2026
claude added 3 commits October 3, 2026 22:35
`boot-origins.smoke.test.ts`'s `REQUEST_ORIGINS` holds one entry, the
SahajCloud API. No ingest origin exists until #232 (PR #245) adds one, so
`Production Smoke` checks nothing about the DSN today. A reader following the
runbook would have skipped the only check there is.

The rewording above it existed to make room for the bullet, so both hunks go
and `docs/environment.md` leaves the diff. The bullet lands with #245, where
the origin it names is real.

Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_0185rnixqGMn3BApUyF34Ka2
The 27-line header repeated the section its own second line points the reader
at: the #148 `max-age` measurement, the `deployment_status` deviation, and the
filters-in-`if` reason each appeared in both. Two copies of one argument drift
apart, and the pointer is what makes the duplicate pointless rather than
merely long.

What stays is what a reader of this file alone cannot get from `docs/testing.md`:
the absent `concurrency` group, and — moved down to the `if:` it explains —
why two conditions gate the branch rather than one. Every `#NNN` breadcrumb cut
from here is live at the file it now points at: PR #120 in `docs/testing.md`
and in `get-cloudflare-preview-url.mjs`'s header, #148 and #244 still named
above.

Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_0185rnixqGMn3BApUyF34Ka2
The input was the one thing that could make the base URL something other
than `https://sahajatlas.com`. That literal is the whole reason this lane does
not re-open #138's question — any App with `deployments: write` posts one, and
`pages.dev` subdomains are first-come-first-served — and an input hands the
same choice to anyone who can dispatch a workflow, for a value that does not
vary. `workflow_dispatch:` with no inputs still gives the hand-run a zone
change wants.

Its value also duplicated the `||` fallback, which was all the spec's second
assertion pinned, so that assertion goes with it. What replaces it is stronger:
`PREVIEW_URL: (\S+)$` matches a bare scalar only, so reintroducing an
expression fails the spec at collection — exit 1, no tests run. Watched all
three ways round: the host back at `*.pages.dev`, the check-run name at
`-design`, and the expression restored.

The empty-URL guard stays and now says what it is for. It cannot fire against
a literal; it is there for the edit that would make it fire, since
`skipWithoutPreview` turns an empty value into sixteen self-skipping specs and
a green check.

Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_0185rnixqGMn3BApUyF34Ka2
@sydevs-bot

Copy link
Copy Markdown
Contributor Author

Addressed the adversarial review — three fixed, one answered. Pushed a278222. Lean gate green: 1630 tests, 129 files.

  • Sentry DSN bullet — adopted, 64326b8. REQUEST_ORIGINS holds one entry, so the claim was false. docs/environment.md leaves the diff.
  • Header restated docs/testing.md — adopted, c5720cd. 27 lines to 10.
  • The url input — adopted, a278222. PREVIEW_URL is a bare scalar, and the spec's regex pins it as one: an expression now fails the file at collection.
  • audit-baseline.json collides with #247 — answered, left open. Merge this PR first; the body says why, and what to do otherwise. origin/main's baseline fails the audit gate on the same advisory, so the booking is not this PR's to drop unprompted.

🤖 Written by the sydevs autonomous loop — see what this is


Generated by Claude Code

@sydevs-bot sydevs-bot removed the bot:working Lock: a cloud session is running on this item. Removed when it ends. label Oct 3, 2026
@sydevs-bot
sydevs-bot marked this pull request as ready for review October 3, 2026 22:45
@sydevs-bot
sydevs-bot requested a review from Ardnived October 3, 2026 22:45
@sydevs-bot
sydevs-bot enabled auto-merge October 3, 2026 22:45
@sydevs-bot sydevs-bot added bot:working Lock: a cloud session is running on this item. Removed when it ends. and removed awaiting labels Oct 4, 2026
#247 landed first, which is the order this PR's body warned about. Its one
conflict is `scripts/audit-baseline.json`, and the resolution takes main's
side whole: the booking this branch added for GHSA-vfj7-8cjw-p6xm is dead.

#247 upgraded tailwindcss 3 → 4, and tailwindcss 4 declares zero
dependencies, so all six paths to `braces` left the production graph.
A baseline entry for an advisory no longer reported is the single state the
weekly `audit.yml --strict` run fails on. Keeping this branch's side would
have re-armed exactly that.

Measured on the merge result: `pnpm audit:check` reports 0 critical, 0 high,
0 new, and `check-audit.mjs --strict` is green as well. Main's own note text
already carries the braces chapter and names #246 as the exit, so nothing in
the dropped prose survives unrecorded.

The conflict was confined to that file. The other four the branch touches
(.github/workflows/production-smoke.yml, scripts/ci-workflows.test.ts,
docs/testing.md, AGENTS.md) merged clean and are unchanged by this commit.

Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WyV8BqCadb5ceVGrfN9Cab
@sydevs-bot

Copy link
Copy Markdown
Contributor Author

Resolved against main at 6b77d95. One conflicted file: scripts/audit-baseline.json, taken from main whole.

#247 landed first — the order this PR's warning calls reversed — so I followed its instruction and dropped this branch's booking rather than resolving in its favour. tailwindcss 4 took every path to braces out of the production graph, so GHSA-vfj7-8cjw-p6xm now books an advisory nobody reports. That is the one state the weekly audit.yml --strict run fails on.

Measured on the merge result: pnpm audit:check reports 0 critical, 0 high, 0 new, and --strict is green too. Lean gate green, 1634 tests. The net diff against main is now this PR's four intended files.

Main's note already carries the braces chapter and names #246 as the exit, so no dropped prose goes unrecorded. The warning block above is now spent — keep it as the record of why the baseline is not in this diff.

🤖 Written by the sydevs autonomous loop — see what this is


Generated by Claude Code

@sydevs-bot sydevs-bot added awaiting and removed bot:working Lock: a cloud session is running on this item. Removed when it ends. labels Oct 4, 2026
@Ardnived

Ardnived commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

@sydevs-bot #247 has already been merged. Revise this ticket as needed.

@Ardnived

Ardnived commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

@sydevs-bot Is it still the case that this CI check would be red after merging? If yes, what can we do to avoid that?

@sydevs-bot sydevs-bot added bot:working Lock: a cloud session is running on this item. Removed when it ends. and removed awaiting labels Oct 6, 2026
#148's dashboard half landed — Browser Cache TTL on the `sahajatlas.com`
zone now respects existing headers, and the ticket closed 2026-10-06. So the
two measurements this section carried are false.

Measured today on this head: 16/16 against `sahajatlas.com`, 16/16 against
`sahajatlas.pages.dev`, 6/16 against `sahajatlas-design.pages.dev`. The
custom domain serves `public, max-age=0, must-revalidate` on both `/auto.js`
and `/embed.js`, which is what `public/_headers` pins.

The 2026-10-03 split stays, moved into its own paragraph, because it is the
evidence for reading the custom domain rather than a preview: no
`*.pages.dev` host could have shown that defect. Losing it would leave the
host choice looking arbitrary the next time someone asks.

The bullet above it claimed the two hosts serve "two sets of headers",
present tense. They no longer do. What the argument needs is that they CAN
diverge and once did, so that is what it says now.

Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01RqcUy4SR8AqEqZra7ZnCtz
@sydevs-bot

Copy link
Copy Markdown
Contributor Author

No — not any more. Nothing needs doing. #148's dashboard half landed while this PR sat: Browser Cache TTL on the sahajatlas.com zone now respects existing headers, and you closed #148 at 00:43 UTC today.

Measured on this head just now, twice: 16/16 against sahajatlas.com. Both /auto.js and /embed.js serve public, max-age=0, must-revalidate, which is what public/_headers pins. The lane is not vacuously green either — sahajatlas-design.pages.dev still fails 10 of the 16.

Adopted in 2fffa06: the docs/testing.md section this PR adds claimed the opposite, so it was wrong twice. Its measurement paragraph said 14/16 with the defect "still live on the custom domain". A bullet above it said the two hosts serve "two sets of headers", present tense. Both now read as the past, and the 2026-10-03 split stays as the evidence for reading the custom domain rather than a preview — no *.pages.dev host could have shown that defect.

The PR body's red-on-merge warning is replaced by the same measurement.

🤖 Written by the sydevs autonomous loop — see what this is


Generated by Claude Code

@sydevs-bot sydevs-bot added awaiting and removed bot:working Lock: a cloud session is running on this item. Removed when it ends. labels Oct 6, 2026
@Ardnived

Ardnived commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

@sydevs-bot What is the intended path for resolution if this CI fails? Does it require manual intervention, or will it automatically refer the issue to the Claude Workflow to raise a ticket to address the issue? What do you recommend?

@sydevs-bot sydevs-bot added bot:working Lock: a cloud session is running on this item. Removed when it ends. and removed awaiting labels Oct 6, 2026
The lane's section said nothing about its own failure path, and a reviewer
had to ask. Nothing watches the default branch: workflow-state.yml
subscribes workflow_run to CI alone, and the dispatcher maps a CI event to
an open PR at that sha, which a merge commit has none of. So a red run is
hand-worked, and the doc now says so rather than leaving the reader to
derive it from two repos.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01SbJfSZPshR2mJC7vRhfvhD
@sydevs-bot

Copy link
Copy Markdown
Contributor Author

Manual today. Nothing refers a red production run to the loop.

  • workflow-state.yml subscribes workflow_run to workflows: [CI], so Production Smoke completing never reaches the dispatcher.
  • check_suite.completed does reach it, but dispatcher/resolve.mjs maps a CI event to open PRs whose head sha is that commit. A merge commit on main has none, so it yields zero targets — no fix-ci, no ticket.
  • fix-ci is the only skill that reads a failing job log, and it is dispatched per PR. No survey reads Actions runs.

The whole alert is GitHub's failed-run email to whoever merged.

Adopted in 3d353cc: docs/testing.md now says so.

Recommended, and it needs your call. Give the lane a failure step that opens one issue as me — issues.opened then sets proposal and awaiting on its own, no dispatcher change. It must comment on an existing open issue rather than file one per deploy, since a production red persists across deploys (#148 lasted days). It adds issues: write to a workflow on main, so I am not adding it unasked.

🤖 Written by the sydevs autonomous loop — see what this is


Generated by Claude Code

@sydevs-bot sydevs-bot added awaiting and removed bot:working Lock: a cloud session is running on this item. Removed when it ends. labels Oct 6, 2026
@Ardnived

Ardnived commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

@sydevs-bot Go ahead with your recommendation

@sydevs-bot sydevs-bot added bot:working Lock: a cloud session is running on this item. Removed when it ends. and removed awaiting labels Oct 6, 2026
A red run on `main` reached nobody. `workflow-state.yml` subscribes
`workflow_run` to CI alone, and the dispatcher maps a CI event to open PRs
whose head is that commit — a merge commit has none — so no handler is
reachable from this lane by any route. GitHub's failed-run email to whoever
merged was the entire alert, and #148 shows what that is worth: it lasted
days.

The lane's last step files an issue instead.

It files as sydevs-bot through SYDEVS_BOT_PAT, not as the workflow: the
dispatcher's worklist labels key on the author, so an issue from
github-actions[bot] would be filed and still reach nobody's queue. That is
why `permissions:` stays `contents: read` — a PAT carries its own scopes.

One open alert, not one per deploy. A production red outlives the deploy
that found it, so the step finds the open alert by its `production-red`
label and comments on it. The label is the identity because a bot-filed
ticket has its title and body rewritten before a human reads it, and only a
label survives that. Nothing closes the alert; a human does.

It is gated on the smoke step rather than the job. A checkout or install
failure is not a production read, and a ticket claiming production is red
when nothing read it is worse than none.

`PREVIEW_URL` moves to the job so the alert names the host the specs read.
Two spellings of a constant drift, and the spec pins exactly one.

`ci-workflows.test.ts` gains the two assertions whose failures are silent
from here — the token and the gate — each watched failing against its own
reintroduced defect.

Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01Fq7YiwFhssGNbhMCLQDjDs
@sydevs-bot

Copy link
Copy Markdown
Contributor Author

Adopted in 735b93a — the alert you approved, unchanged from the recommendation.

A red read now opens one issue as me, found by a production-red label and commented on rather than refiled while the red persists. permissions: stays contents: read: SYDEVS_BOT_PAT is not governed by it, and the job's own token gains nothing. The step is gated on the smoke step, not the job, so a checkout or install failure files nothing — it never read production.

ci-workflows.test.ts gains two assertions, each watched failing against its own reintroduced defect: the token (the wrong one files an issue that reaches nobody's queue) and the gate. The alert shell is driven locally on all three paths — no alert, an open alert, no PAT. Lean gate green, 1636 passed.

One thing you have to check after the first red run: that SYDEVS_BOT_PAT reaches this repo's own workflows. Nothing local can — Manual verification 3 says what a failure looks like.

I did not add an auto-close on green. A hand-run or one green read of a flaky spec would close a real alert.

🤖 Written by the sydevs autonomous loop — see what this is


Generated by Claude Code

@sydevs-bot sydevs-bot added awaiting and removed bot:working Lock: a cloud session is running on this item. Removed when it ends. labels Oct 6, 2026
@sydevs-bot
sydevs-bot added this pull request to the merge queue Oct 6, 2026
Merged via the queue into main with commit 7b27e82 Oct 6, 2026
25 checks passed
@sydevs-bot
sydevs-bot deleted the claude/chore-244-production-smoke branch October 6, 2026 20:24
Ardnived added a commit that referenced this pull request Oct 10, 2026
…ile (#268)

The Dependency Audit job audited every production dependency in the
lockfile, so a new advisory against one already on main failed every
open PR. From 2026-09-30 to 10-03 it failed #233, #237, #243 and #248,
none of which touched a dependency, and fix-ci rewrote overrides and the
baseline on those unrelated PRs.

The shared Dependency Review job from sydevs/claude-workflow fails only
when a PR adds a high or critical runtime advisory. Advisories already
on main are the loop's daily Dependabot check's to fix. audit.yml, the
baseline and check-audit.mjs go with the old gate.

Co-authored-by: Claude Opus 5.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Development

Successfully merging this pull request may close these issues.

chore(ci): nothing automated observes the production deploy, only a preview

3 participants