fix(api): regen for typed TimingPhasesDto in HTTP check details#18
Merged
Conversation
Picks up the upstream mono fix (devhelmhq/mono#271) that replaces the misleading `Map<String, Object>` timing field on `Http` check details with a typed `TimingPhasesDto`. Before this regen the generated zod schema had: timing: z.record(z.object({}).partial().strict().nullable()).nullish() which would reject the actual snake_case integer payload (`dns_ms`, `tcp_ms`, …) coming from the API. After regen `timing` correctly references `TimingPhasesDto` with nullable int fields. Diff is fully mechanical (typegen + zodgen + descgen). All 870 unit tests pass. Made-with: Cursor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
src/lib/api{,-zod}.generated.tsanddocs/openapi/monitoring-api.jsonfrom the upstream spec to pick up devhelmhq/mono#271.Http.timing's erroneousMap<String, Object>schema with a typedTimingPhasesDto(nullable ints fordns_ms,tcp_ms,tls_ms,ttfb_ms,download_ms,total_ms).details.checkDetails.timingagainst the strict zod schema would have been rejected — the schema expected an object map of objects, but the wire format is a flat snake_case object of integers.Diff scope
Pure regen — no hand edits:
docs/openapi/monitoring-api.json— spec drop-insrc/lib/api.generated.ts—Http.timingnow referencesTimingPhasesDto; newTimingPhasesDtotyped schema addedsrc/lib/api-zod.generated.ts— matching zod schema added + wired inTest plan
make check(lint + typecheck + 870 vitest tests) passes locallyTimingPhasesDtomodelMade with Cursor