Skip to content

Conversation

@bitgopatmcl
Copy link
Contributor

@bitgopatmcl bitgopatmcl commented May 9, 2024

Fixes an issue where errors are swallowed while processing an httpRoute. Generally this happens while processing a request type, the error just gets swallowed and the request property is omitted from the resulting schema. This then errors out later on in the section of the codebase that expects a request to be there, causing this hard-to-debug error:

Error parsing SomeApiSpec: Route must have a request

With this change, the actual error is passed all the way through, making it much easier to see what went wrong.

@bitgopatmcl bitgopatmcl changed the title Don't silently drop properties from httpRequest Don't silently drop properties when processing an httpRoute May 9, 2024
@bitgopatmcl bitgopatmcl marked this pull request as ready for review May 9, 2024 14:59
@bitgopatmcl bitgopatmcl requested a review from a team as a code owner May 9, 2024 14:59
@bitgopatmcl bitgopatmcl force-pushed the VL-1836-fix-error-message branch from ae0b7ce to addbc6c Compare May 9, 2024 15:02
@bitgopatmcl bitgopatmcl marked this pull request as draft May 9, 2024 15:41
@bitgopatmcl bitgopatmcl force-pushed the VL-1836-fix-error-message branch 2 times, most recently from 92d03a1 to 48821de Compare May 9, 2024 15:43
@bitgopatmcl bitgopatmcl marked this pull request as ready for review May 9, 2024 15:43
@bitgopatmcl bitgopatmcl force-pushed the VL-1836-fix-error-message branch from 48821de to bc65c5f Compare May 9, 2024 16:20
@bitgopatmcl bitgopatmcl requested a review from a team May 9, 2024 16:43
Copy link
Contributor

@ericcrosson-bitgo ericcrosson-bitgo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👨‍🍳 🚀

@ericcrosson-bitgo ericcrosson-bitgo merged commit a16cea1 into master May 9, 2024
@ericcrosson-bitgo ericcrosson-bitgo deleted the VL-1836-fix-error-message branch May 9, 2024 17:01
@github-actions
Copy link

github-actions bot commented May 9, 2024

🎉 This PR is included in version @api-ts/openapi-generator@3.6.2 🎉

The release is available on npm package (@latest dist-tag)

Your semantic-release bot 📦🚀

@github-actions
Copy link

github-actions bot commented Jun 4, 2024

🎉 This PR is included in version @api-ts/express-wrapper@1.0.26 🎉

The release is available on npm package (@latest dist-tag)

Your semantic-release bot 📦🚀

@github-actions
Copy link

github-actions bot commented Jun 4, 2024

🎉 This PR is included in version @api-ts/superagent-wrapper@1.2.1 🎉

The release is available on npm package (@latest dist-tag)

Your semantic-release bot 📦🚀

@github-actions
Copy link

github-actions bot commented Jun 4, 2024

🎉 This PR is included in version @api-ts/typed-express-router@1.1.6 🎉

The release is available on npm package (@latest dist-tag)

Your semantic-release bot 📦🚀

@github-actions
Copy link

github-actions bot commented Aug 5, 2024

🎉 This PR is included in version @api-ts/io-ts-http@3.1.0 🎉

The release is available on npm package (@latest dist-tag)

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants