Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
✅ Deploy Preview for the-codegen-project canceled.
|
|
Re: Date unmarshal bug Acknowledged. This is a valid bug that will require fixes in two places:
Tracking this for a follow-up fix that spans both repos. |
- Remove 'time' format from isDateFormatModel to prevent Invalid Date (time strings like "14:30:00" are not valid Date constructor args) - Exclude ConstrainedUnionModel from hasItemUnmarshal to prevent undefined Union.unmarshal reference for tuple arrays 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
|
🎉 This PR is included in version 0.64.4 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Note
Medium Risk
Touches TypeScript code generation for primitives/arrays/unions and AJV schema generation/validation, which can change emitted types and runtime behavior (notably date/null handling and union schemas). Risk is mitigated by updated snapshots and added runtime fixtures, but regressions could impact downstream generated clients.
Overview
Improves the TypeScript generator by upgrading
@asyncapi/modelinaand extending the primitives preset to generate correctmarshal/unmarshalfornullschemas anddate/date-timeformatted strings (now producingDateobjects on unmarshal).Tightens array unmarshalling to avoid calling
.unmarshalfor nested arrays and union aliases, and updates validation generation to (1) accept marshalled JSON strings byJSON.parse-ing input before AJV validation and (2) sanitize root-level union schemas by omitting conflictingtype: "object"whenoneOf/anyOfis present.Updates generated test snapshots/runtime outputs accordingly, including new runtime fixtures and scripts for comprehensive payload-type generation/testing, plus minor test comment cleanup.
Written by Cursor Bugbot for commit b2ef5d7. This will update automatically on new commits. Configure here.