Skip to content

fix(triage): make main's CI green again after the triage gate - #964

Merged
Makisuo merged 1 commit into
mainfrom
fix/ci-triage-gate
Sep 21, 2026
Merged

Makisuo merged 1 commit into
mainfrom
fix/ci-triage-gate

Conversation

@Makisuo

@Makisuo Makisuo commented Sep 21, 2026 •

Copy link
Copy Markdown
Collaborator

Why

#960 merged with CI red, so the deployment gate has refused every deploy since (Nothing was deployed: CI did not pass). Prod is still on the commit before it: the Jev triage gate, #959 and #962 are all undeployed.

What

  • Stale generated list. IncidentTriageUnauthorizedError is 4xx-annotated, so anticipated-errors.test.ts expected it in generated/anticipated-error-identifiers.ts. Regenerated with gen:anticipated-errors.
  • Binding fetch type. typecheck-api resolves typeof globalThis.fetch to a type that carries preconnect, so the classifier's fetchOverBinding failed TS2741 there. IncidentClassifier now builds its HttpClient directly over the AI_WORKER binding with fromCloudflareFetcher + toHttpClient, the adapter apps/api already uses to forward to maple-ai. The FetchHttpClient.Fetch detour and the layer's FetchHttpClient.layer dependency go away.

Verified

  • IncidentClassifier.test.ts and anticipated-errors.test.ts pass.
  • typecheck green for packages/backend, apps/api (the failing job) and apps/alerting.
  • oxlint / oxfmt clean on the changed files.

Devin Review


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.

Two things #960 left behind that only CI saw:

- `IncidentTriageUnauthorizedError` is a 4xx error, so it belongs in the
  generated anticipated-error list; the drift test caught the stale output.
  Regenerated.
- `typecheck-api` sees a `fetch` type with `preconnect` on it, so a binding
  fetch annotated as `typeof globalThis.fetch` does not typecheck there. The
  classifier now builds its HttpClient straight over the service binding with
  alchemy's `fromCloudflareFetcher` + `toHttpClient`, the same adapter the api
  Worker forwards to maple-ai with, and drops the Fetch-service detour.
@coderabbitai

coderabbitai Bot commented Sep 21, 2026

Copy link
Copy Markdown

Review Change StackReview Change Stack

Note

Currently processing new changes in this PR. This may take a few minutes, please wait...

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Advanced

Run ID: 5c97b0ae-4957-482c-93a5-ef76f0548f38

📥 Commits

Reviewing files that changed from the base of the PR and between 987237c and ca9a76c.

⛔ Files ignored due to path filters (1)
  • packages/domain/src/generated/anticipated-error-identifiers.ts is excluded by !**/generated/**
📒 Files selected for processing (1)
  • packages/backend/src/services/errors/IncidentClassifier.ts
 ______________________________
< Here's looking at you, code. >
 ------------------------------
  \
   \   \
        \ /\
        ( )
      .( o ).
✨ Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR

Comment @coderabbitai help to get the list of available commands.

@Makisuo
Makisuo merged commit 51439b2 into main Sep 21, 2026
39 of 41 checks passed
@Makisuo
Makisuo deleted the fix/ci-triage-gate branch September 21, 2026 10:03

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no bugs or issues to report.

Devin Review

Makisuo added a commit that referenced this pull request Sep 21, 2026
…tics-integration

Takes main's #964 fixes for the triage gate: its binding transport replaces
the fetch shim this branch had typed, and its regenerated error identifiers
match ours.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant