feat: Ignore specific field types#163
Merged
kodiakhq[bot] merged 1 commit intocloudquery:mainfrom Sep 21, 2022
Merged
Conversation
Contributor
|
why not fail here? seems like it the last fallback and it still generates an error. maybe you can skip this explicitly? otherwise if we skip errors it will become really hard to about any issues in codegen as it will turn into log parsing race |
Member
Author
We're discussing this on Slack. It's hard to know in advance which fields to skip without implementing the reflection logic in consumers. Not sure we should be creating columns for fields that are interfaces. |
f453b8b to
2e11d2b
Compare
erezrokah
commented
Sep 21, 2022
yevgenypats
approved these changes
Sep 21, 2022
kodiakhq bot
pushed a commit
that referenced
this pull request
Sep 21, 2022
🤖 I have created a release *beep* *boop* --- ## [0.7.13](v0.7.12...v0.7.13) (2022-09-21) ### Features * Ignore specific field types ([#163](#163)) ([792c88a](792c88a)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
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
#157 changed the behavior of printing a log message on unsupported types (like
interface) to failing.I'm not sure that's what we want as now the consumer has to skip all the interface fields to make code gen work.I kept the failure on custom type transformer as I believe that should be indeed a failure to generate.Changed the code to explicitly specific types
Use the following steps to ensure your PR is ready to be reviewed
go fmtto format your code 🖊golangci-lint run🚨 (install golangci-lint here)