Skip to content

Enforce async correctness and module boundaries with Biome - #1541

Merged
lovasoa merged 1 commit into
mainfrom
codex/biome-bug-catching-rules
Oct 9, 2026
Merged

lovasoa merged 1 commit into
mainfrom
codex/biome-bug-catching-rules

Conversation

@lovasoa

@lovasoa lovasoa commented Oct 8, 2026

Copy link
Copy Markdown
Collaborator

Enable four focused error-level checks in the frontend lint gate:

  • noMisusedPromises rejects promise-valued conditions and async callbacks used by synchronous array methods.
  • useAwaitThenable rejects awaiting synchronous values, including accidentally awaiting a function instead of calling it.
  • noPlaywrightMissingAwait catches unawaited browser actions and async assertions.
  • noImportCycles prevents runtime module cycles while allowing type-only dependencies.

The Playwright rule closes a confirmed gap: a temporary unawaited toBeVisible() assertion imported through our shared fixture failed this rule but passed the existing noFloatingPromises check. The current code already satisfies these rules; no runtime changes or suppressions are needed. Contributor guidance explains the rules and their nursery status.

Validation: npm run format, npm test (Biome, all TypeScript projects, both JS test files), and npm run build passed. Temporary probes confirmed each new rule rejects its target mistake, and valid awaited assertions, returned assertions, and type-only cycles pass; all probes were removed.

@lovasoa
lovasoa added this pull request to the merge queue Oct 9, 2026
Merged via the queue into main with commit 3ff14e0 Oct 9, 2026
18 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