Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

codegen: Generate the GQLDeprecated annotation #2107

Merged
merged 1 commit into from
Feb 2, 2024

Conversation

johnspade
Copy link
Contributor

When using the schema-first approach, it is useful to add annotations from the schema to the generated Caliban code, they will be used for introspection. It's helpful to see deprecated fields and types in tools like Graphiql.

The changes also include a small improvement following up on my previous PR #2064: root fields should also be generated with the parameterized effect type in the case of nested lazy fields.

@johnspade johnspade force-pushed the codegen-annotations branch from bd82e46 to 964defd Compare January 30, 2024 23:45
@johnspade johnspade marked this pull request as ready for review January 30, 2024 23:54
@ghostdogpr
Copy link
Owner

Nice! Could you add one case of this to the existing scripted tests (in the sbt plugin module). It will make sure the generated code compiles well.

@johnspade johnspade force-pushed the codegen-annotations branch from 19569da to fcc56e4 Compare February 1, 2024 15:00
@johnspade
Copy link
Contributor Author

Nice! Could you add one case of this to the existing scripted tests (in the sbt plugin module). It will make sure the generated code compiles well.

Done, added these cases to the scripted tests

Copy link
Owner

@ghostdogpr ghostdogpr left a comment

Choose a reason for hiding this comment

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

Thanks!

@ghostdogpr ghostdogpr merged commit cd13787 into ghostdogpr:series/2.x Feb 2, 2024
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants