Skip to content

refactor(api): cover the generator scripts with effect lint (CLI-2842) - #7310

Open
7ttp wants to merge 1 commit into
7ttp/cli-2841-src-coveragefrom
7ttp/cli-2842-scripts-coverage
Open

7ttp wants to merge 1 commit into
7ttp/cli-2841-src-coveragefrom
7ttp/cli-2842-scripts-coverage

Conversation

@7ttp

@7ttp 7ttp commented Oct 23, 2026

Copy link
Copy Markdown
Member

TL;DR

brings the packages/api generator scripts and their tests under the effect lint, which completes the package

whats introduced?

  • the allow list entry widens to packages/api/**
  • download-openapi.ts and generate.ts run as effect programs on FileSystem, HttpClient, Config and Console, with the same requests, console output, generated files and exit codes
  • a failed run still prints the original error and exits 1, with effect frames in the stack, and an empty SUPABASE_API_URL now reports effect's UrlError
  • the scripts tests move to effect, spawning turbo and oxfmt through ChildProcess, and the openapi.json sync test now checks the generator's own serializer

ref

@7ttp 7ttp self-assigned this Oct 23, 2026
@7ttp
7ttp added this pull request to stack #7311 October 23, 2026 16:30
@7ttp
7ttp requested a review from a team as a code owner October 23, 2026 16:30

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🤖 AI Review

Reviewed both findings against the checked-out code and trusted conventions. Confirmed the missing workflow spans. The stdout workaround was removed, but whether the asynchronous replacement suffers Bun truncation remains uncertain. Exact reproduction was unavailable because dependencies are absent and installed Bun differs from the pinned version.

Findings

Severity Location Category Sources Claim
🟡 MINOR packages/api/scripts/dependent-types-check-cache.unit.test.ts:37 test-reliability claude Replacing file-backed turbo output with piped stdout may reintroduce Bun/Linux truncation, causing dry-run JSON decoding to fail.
🟡 MINOR packages/api/scripts/generate.ts:1208 observability codex The rewritten generation and download workflows omit the named spans required for changed I/O and millisecond-scale work.

Stats

Claude findings: 1 · Codex findings: 1 · Confirmed: 1 · Refuted: 0 · Uncertain: 1


Models: claude-opus-5-5 + gpt-6.1-sol · Trigger: auto · Workflow run

This review runs once per PR. A maintainer can request another with a /ai-review comment.

Comment thread packages/api/scripts/dependent-types-check-cache.unit.test.ts
Comment thread packages/api/scripts/generate.ts

This branch has not been deployed

No deployments
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