chore: upgrade @kubb/* to alpha.56, fix barrel middleware bugs, update requestBody snapshots#58
Conversation
Update all test files to use the new OperationNode requestBody structure
where schema and keysToOmit are nested inside a content array.
OLD: requestBody: { schema: X, contentType: 'Y' }
NEW: requestBody: { content: [{ contentType: 'Y', schema: X }] }
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: stijnvanhulle <5904681+stijnvanhulle@users.noreply.github.com>
…cture Update all usages across plugin-client, plugin-mcp, plugin-zod, plugin-react-query, plugin-vue-query, and tanstack-query internals to use the new nested content array structure introduced in alpha.55: - node.requestBody?.schema → node.requestBody?.content?.[0]?.schema - node.requestBody?.contentType → node.requestBody?.content?.[0]?.contentType - node.requestBody?.keysToOmit → node.requestBody?.content?.[0]?.keysToOmit Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Co-authored-by: stijnvanhulle <5904681+stijnvanhulle@users.noreply.github.com>
Agent-Logs-Url: https://github.com/kubb-labs/plugins/sessions/0b1bbb5e-e46d-4529-b5d5-6376795f3e53 Co-authored-by: stijnvanhulle <5904681+stijnvanhulle@users.noreply.github.com>
Review or Edit in CodeSandboxOpen the branch in Web Editor • VS Code • Insiders |
|
… upstream) Agent-Logs-Url: https://github.com/kubb-labs/plugins/sessions/3721bfa6-f2a4-4b65-8120-112b32fbb9a2 Co-authored-by: stijnvanhulle <5904681+stijnvanhulle@users.noreply.github.com>
📊 Dependency Size ChangesNote 🎉 This PR removes 138.2 kB of dependencies.
Total size change: -138.2 kB |
More templates
@kubb/plugin-client
@kubb/plugin-cypress
@kubb/plugin-faker
@kubb/plugin-mcp
@kubb/plugin-msw
@kubb/plugin-react-query
@kubb/plugin-redoc
@kubb/plugin-ts
@kubb/plugin-vue-query
@kubb/plugin-zod
commit: |
|
@copilot resolve test issues by updating test cases to follow the changes we did for requestBody in ast and adapter-oas. Also run format en lint:fix and commit those changes |
Agent-Logs-Url: https://github.com/kubb-labs/plugins/sessions/d751c5a7-5b3a-4dc7-96d7-5b9f8271057b Co-authored-by: stijnvanhulle <5904681+stijnvanhulle@users.noreply.github.com>
Updated all 3 failing snapshots in fd3c5f6:
All 819 tests now pass. Lint and format don't touch |
Agent-Logs-Url: https://github.com/kubb-labs/plugins/sessions/74178c1d-06e5-48e7-9543-9a694cc769f3 Co-authored-by: stijnvanhulle <5904681+stijnvanhulle@users.noreply.github.com>
…snapshots Agent-Logs-Url: https://github.com/kubb-labs/plugins/sessions/04bc86bc-4141-4faf-85f5-4b6d170bfdeb Co-authored-by: stijnvanhulle <5904681+stijnvanhulle@users.noreply.github.com>
Agent-Logs-Url: https://github.com/kubb-labs/plugins/sessions/fab22cab-b95a-4083-8d70-099e1ccea185 Co-authored-by: stijnvanhulle <5904681+stijnvanhulle@users.noreply.github.com>
|
@copilot why does it fail on windows? |
Looked at the failing Windows job ( The The reason we can't see the actual TS error is that Two ways forward, both small and not really part of this PR's scope:
Want me to switch the petstore CI step to run typecheck explicitly so we can see the actual TS errors and fix them in this PR? Otherwise the Windows log can't tell us which file/line is failing. |
Agent-Logs-Url: https://github.com/kubb-labs/plugins/sessions/857e00eb-b81a-4bfc-9473-266ad0e8a6aa Co-authored-by: stijnvanhulle <5904681+stijnvanhulle@users.noreply.github.com>
|
@copilot yes please |
…Windows Agent-Logs-Url: https://github.com/kubb-labs/plugins/sessions/f9124c5d-49b1-4317-8112-c2f10116a2cf Co-authored-by: stijnvanhulle <5904681+stijnvanhulle@users.noreply.github.com>
Done in 1dc36b9 — moved |
…ha-version' into copilot/update-kubb-packages-alpha-version
🎯 Changes
Upgrades
@kubb/*dependencies to alpha.56 and resolves the resulting typecheck and example-generation breakages.examples/client/src/generators/clientStaticGenerator.tsxfor the newrequestBody.content[]shape.barrelType:examples/clientusesbarrelType: 'all'.examples/cypress,examples/fetch,examples/react-query, andexamples/simple-singleusebarrelType: 'named'(preferred default).examples/mcpkeepsbarrelType: 'all'because its tsconfig enablesverbatimModuleSyntax, which is incompatible with the mixed value+type re-exports produced by'named'(TS1205).examples/advanceddisables the root barrel (barrelType: false) due to multi-plugin name collisions, andsrc/index.tsis updated accordingly.requestBody.content[]AST:caseSensitivity/types/CreateOrder.ts—$ref-based requestBody now resolves todata?: never.issue2619/zod/createReturnTypeASchema.ts— removedtypeARequestSchemaimport andcreateReturnTypeADataSchema.issue2619/zod/createReturnTypeBSchema.ts— removedtypeBRequestSchemaimport andcreateReturnTypeBDataSchema.npm run typecheckout of the kubbdone:hook intests/e2e/kubb-petstore.config.jsand into an explicit CI step in.github/workflows/pr.yml, so on Windows the actualtscoutput is captured (the kubb hook's detached pipe was swallowing stdout fromnpm.cmd → tsc, hiding the real failure).✅ Checklist
pnpm run test(52 files, 819 tests).pnpm typecheckpasses (13/13).pnpm typecheck:examplespasses (14/14).pnpm generatesucceeds for all examples.🚀 Release Impact