feat(10.x.x): Include deprecated input fields in introspection query - #2198
Merged
samuelAndalon merged 1 commit intoJul 1, 2026
Merged
Conversation
…2195) ### 📝 Description If an introspection query runs against a schema where all fields on an object are deprecated then an empty object is returned which will fail to print via graphql-java when doing `SchemaPrinter(options).print(graphQLDocument)` which is done in the graphql-kotlin client. By including those deprecated fields, we avoid the invalid object. Stack trace example: ``` Caused by: graphql.schema.validation.InvalidSchemaException: invalid schema: "InputTypeWithAllDeprecatedFields" must define one or more fields. at graphql.schema.GraphQLSchema$Builder.validateSchema(GraphQLSchema.java:886) at graphql.schema.GraphQLSchema$Builder.buildImpl(GraphQLSchema.java:874) at graphql.schema.GraphQLSchema$Builder.build(GraphQLSchema.java:841) at graphql.schema.idl.SchemaGenerator.makeExecutableSchemaImpl(SchemaGenerator.java:143) at graphql.schema.idl.SchemaGenerator.makeExecutableSchema(SchemaGenerator.java:113) at graphql.schema.idl.SchemaGenerator.makeExecutableSchema(SchemaGenerator.java:84) at graphql.schema.idl.UnExecutableSchemaGenerator.makeUnExecutableSchema(UnExecutableSchemaGenerator.java:28) at graphql.schema.idl.SchemaPrinter.print(SchemaPrinter.java:496) at com.expediagroup.graphql.plugin.client.IntrospectSchemaKt$introspectSchema$2$1.invokeSuspend(introspectSchema.kt:182) at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33) at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:104) at kotlinx.coroutines.EventLoopImplBase.processNextEvent(EventLoop.common.kt:277) at kotlinx.coroutines.BlockingCoroutine.joinBlocking(Builders.kt:95) at kotlinx.coroutines.BuildersKt__BuildersKt.runBlocking(Builders.kt:69) at kotlinx.coroutines.BuildersKt.runBlocking(Unknown Source) at kotlinx.coroutines.BuildersKt__BuildersKt.runBlocking$default(Builders.kt:48) at kotlinx.coroutines.BuildersKt.runBlocking$default(Unknown Source) at com.expediagroup.graphql.plugin.client.IntrospectSchemaKt.introspectSchema(introspectSchema.kt:150) at com.expediagroup.graphql.plugin.gradle.actions.IntrospectSchemaAction.execute(IntrospectSchemaAction.kt:37) ``` And an example schema that causes the problem: ```sdl schema { query: Query } type Query { hello(input: HelloInput): String! } input HelloInput { legacyField: String @deprecated(reason: "Use `newField` instead.") } ``` ### 🔗 Related Issues
samuelAndalon
deleted the
fix/10.x.x/deprecated-input-fields-introspection
branch
July 1, 2026 16:37
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.
cherry pick #2195