Skip to content

fix(hub): log the cause of failures the hub swallowed - #218

Merged
TheGreatAxios merged 1 commit into
mainfrom
cl-12104-stop-the-hub-hiding-its-own-failures
Nov 7, 2026
Merged

TheGreatAxios merged 1 commit into
mainfrom
cl-12104-stop-the-hub-hiding-its-own-failures

Conversation

@TheGreatAxios

@TheGreatAxios TheGreatAxios commented Nov 7, 2026 •

Copy link
Copy Markdown
Contributor

When something failed in seven places in the hub, it was silently ignored and nobody could tell why. Now each failure is logged with its error code. The message is left out, so no secrets leak. What the app does is unchanged.

Links CL-12104.

Verified

  • A new migration test fails on main and passes here. It checks that the error code is printed and the database URL is not.
  • Lint, format, typecheck, 326 tests, pins and vendor checks pass.
  • End-to-end: 9 of 9 pass.

@linear-code

linear-code Bot commented Nov 7, 2026

Copy link
Copy Markdown

CL-12104

@corbits-triage corbits-triage 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.

Triage requests changes:

  • Conventions: added code matches a code pattern
    • apps/hub/src/request-error.ts:16-20 nested-ternary: Nested ternary; use if statements or a lookup.
  • Errors kept: added code matches a code pattern
    • apps/hub/src/builds/posix-sandbox.ts:999-1002 bare-catch: A catch without a binding drops the error; check for the expected failure, or catch it and rethrow the rest.

@corbits-triage corbits-triage 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.

Triage requests changes:

  • Conventions: added code matches a code pattern
    • apps/hub/src/builds/posix-sandbox.ts:1020-1025 promise-chain: Promise chain; use async/await with try/catch.

@corbits-triage

corbits-triage Bot commented Nov 7, 2026 •

Copy link
Copy Markdown

Triage: Unsure

Asking a maintainer about:

  • changes sensitive paths: auth: apps/hub/src/auth-email.ts, auth: apps/hub/src/auth/coordinator-credential-refresh.ts

@corbits-triage
corbits-triage Bot dismissed stale reviews from themself November 7, 2026 04:42

Nothing triage asked to change still fails, so this request no longer stands.

Comment thread apps/hub/src/request-error.ts Resolved
Seven places caught every error and carried on. Each now treats only its
expected failure as normal and logs anything else with its error code:
credential refresh, the pushed ref, the pre-write file check, auth emails,
workflow connection sync, migrations and the preview reload. errorCode
reads a wrapped error's cause, so Drizzle failures carry their code.
@TheGreatAxios
TheGreatAxios force-pushed the cl-12104-stop-the-hub-hiding-its-own-failures branch from a80b333 to 7ef4a80 Compare November 7, 2026 04:52
Comment thread apps/hub/src/request-error.ts Resolved
@TheGreatAxios
TheGreatAxios added this pull request to the merge queue Nov 7, 2026
Merged via the queue into main with commit 2173f0a Nov 7, 2026
9 checks passed
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