Skip to content

health module and vite 8 migration - #151

Merged
Friedrich482 merged 4 commits into
mainfrom
chores
Jul 28, 2026
Merged

health module and vite 8 migration#151
Friedrich482 merged 4 commits into
mainfrom
chores

Conversation

@Friedrich482

@Friedrich482 Friedrich482 commented Jul 28, 2026

Copy link
Copy Markdown
Owner

Commits

  • chore: health

    • organized all the health related endpoints in one single health module that covers both the native nest.js implementation using a controller than the trpc way using a router
    • added tests for the health.service, health.router and health.controller
  • chore: vite 8 migration

    • migrated the dashboard to vite 8
  • fix: zod schemas

    • updated the IsoDateStringSchema to use the built-in z.iso.date() instead of a complex regex
    • updated the globalStateInitialDataSchema to use z.iso.datetime()... to validate the fields lastServerSync and updatedAt instead of an union because the dates are serialized into strings when saving the object in memory
    • moved the IsoDateSchema into the dashboard app since it is now only used there
  • chore: extension version

    • bumped the extension version to v0.0.74

Summary by CodeRabbit

  • New Features

    • Added a public health check at /health/ping, returning the service’s operational status.
    • Added health-check support to the API’s RPC interface.
  • Bug Fixes

    • Updated API readiness checks to use the new health endpoint.
    • Improved date validation and parsing across dashboard and extension data.
  • Improvements

    • Updated dashboard build tooling and React compilation.
    • Released VS Code extension version 0.0.74.

- organized all the health related endpoints in one single health module that covers both the native nest.js implementation using a controller than the trpc way using a router
- added tests for the `health.service`, `health.router` and `health.controller`
- migrated the dashboard to vite 8
- updated the `IsoDateStringSchema` to use the built-in z.iso.date() instead of a complex regex
- updated the `globalStateInitialDataSchema` to use `z.iso.datetime()...` to validate the fields `lastServerSync` and `updatedAt` instead of an union because the dates are serialized into strings when saving the object in memory
- moved the `IsoDateSchema` into the dashboard app since it is now only used there
- bumped the extension version to `v0.0.74`
@coderabbitai

coderabbitai Bot commented Jul 28, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

The API adds HTTP and tRPC health ping endpoints. Dashboard tooling moves to Babel and Rolldown configuration. Period schemas export date utilities, while shared and VSCode schemas standardize ISO date parsing.

Changes

API health checks

Layer / File(s) Summary
Health service and endpoints
apps/api/src/health/*
Adds HealthService, an HTTP /health/ping controller, a public tRPC health.ping procedure, and unit tests for each layer.
Health module and application wiring
apps/api/src/app*, apps/api/src/app-router/*, apps/api/package.json
Registers HealthModule, merges HealthRouter into the application router, removes the legacy application health handler, and updates the readiness URL.

Dashboard build and period schemas

Layer / File(s) Summary
Dashboard compiler and bundler configuration
apps/dashboard/package.json, apps/dashboard/vite.config.ts
Replaces SWC with Babel React compilation, adds React Compiler configuration, upgrades Vite, and configures Rolldown code-splitting groups.
Period date schema exports
apps/dashboard/src/stores/period/*
Exports an ISO date transformation schema and inferred Period type, and updates URL parsing imports.

Datetime schema normalization

Layer / File(s) Summary
Shared ISO date validation
packages/common/src/types-schemas.ts
Replaces custom ISO date validation with Zod’s built-in validator while retaining conversion to Date.
Extension state datetime parsing
apps/vscode-extension/src/types-schemas.ts, apps/vscode-extension/package.json
Restricts selected datetime fields to ISO strings transformed into Date values and increments the extension version.

Estimated code review effort: 3 (Moderate) | ~25 minutes

Sequence Diagram(s)

sequenceDiagram
  participant Client
  participant HealthController
  participant HealthRouter
  participant HealthService
  Client->>HealthController: GET /health/ping
  HealthController->>HealthService: ping()
  HealthService-->>HealthController: { status: "OK" }
  Client->>HealthRouter: health.ping query
  HealthRouter->>HealthService: ping()
  HealthService-->>HealthRouter: { status: "OK" }
Loading
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title concisely captures the two main themes of the PR: health module work and the Vite 8 migration.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch chores

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

ESLint install timed out. The project may have too many dependencies for the sandbox.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

@coderabbitai coderabbitai 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.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@apps/dashboard/src/stores/period/types-schemas.ts`:
- Around line 9-11: Update IsoDateSchema to parse date-only strings as local
calendar dates rather than passing them directly to the Date constructor. Split
the YYYY-MM-DD value into numeric year, month, and day components and construct
the local date with those components, preserving the existing transformed Date
output.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 1f69c169-37d1-4eb8-ab38-8a7b30122a41

📥 Commits

Reviewing files that changed from the base of the PR and between ea344fc and e197c5e.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (20)
  • apps/api/package.json
  • apps/api/src/app-router/app-router.module.ts
  • apps/api/src/app-router/providers/app-router.provider.ts
  • apps/api/src/app.controller.ts
  • apps/api/src/app.module.ts
  • apps/api/src/app.service.ts
  • apps/api/src/health/health.controller.test.ts
  • apps/api/src/health/health.controller.ts
  • apps/api/src/health/health.module.ts
  • apps/api/src/health/health.router.test.ts
  • apps/api/src/health/health.router.ts
  • apps/api/src/health/health.service.test.ts
  • apps/api/src/health/health.service.ts
  • apps/dashboard/package.json
  • apps/dashboard/src/stores/period/types-schemas.ts
  • apps/dashboard/src/stores/period/utils/get-period-store-values-from-url.ts
  • apps/dashboard/vite.config.ts
  • apps/vscode-extension/package.json
  • apps/vscode-extension/src/types-schemas.ts
  • packages/common/src/types-schemas.ts
💤 Files with no reviewable changes (2)
  • apps/api/src/app.service.ts
  • apps/api/src/app.controller.ts

Comment thread apps/dashboard/src/stores/period/types-schemas.ts
@Friedrich482
Friedrich482 merged commit b1d3e42 into main Jul 28, 2026
4 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