Skip to content

fix(api): detect OpenAPI route drift - #591

Open
sa-salami wants to merge 1 commit into
arflexx:mainfrom
sa-salami:fix/issue-483
Open

sa-salami wants to merge 1 commit into
arflexx:mainfrom
sa-salami:fix/issue-483

Conversation

@sa-salami

Copy link
Copy Markdown
Contributor

Summary

  • Add a TypeScript-AST route coverage check that combines mounted router paths with handler methods and compares them with server/openapi.json.
  • Include the check in server CI and document the route/spec update requirement.
  • Add coverage operations for registered paths that were missing from the generated OpenAPI file, then regenerate it from server/src/openapi.ts.
  • Declare ts-node directly in the server package so its existing OpenAPI scripts work in a clean install.

Fixes #483

Validation

  • pnpm check:openapi passed.
  • pnpm check:route-spec passed: 87 registered operations covered.
  • Frontend Navbar tests for issue [Frontend] - Add Keyboard Navigation Support for Navbar Menu #456 passed separately.
  • Server lint and the full server suite still report unrelated notification-template, migration, request-ID, and trade-tracing errors; results are included in the PR checks.

@sa-salami
sa-salami requested a review from dark-sarge as a code owner October 25, 2026 19:49
@zeemscript

Copy link
Copy Markdown
Contributor

@arflexx I checked this failure against the default-branch CI run 40304749221 (Oct 26): server TypeScript and frontend type-check failures are already present on main and do not come from this PR’s OpenAPI drift checker. The PR is currently reported mergeable; its new route-drift workflow may run separately, but the shared TypeScript failures need to be repaired on the base branch before these checks can pass.

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.

[Backend] - Add OpenAPI Spec Drift Detection for Route Handlers

2 participants