printSchemaWithDirectives from @graphql-tools/utils
uses incorrect descriptions
#5508
Open
1 of 4 tasks
@graphql-tools/utils
uses incorrect descriptions
#5508
Issue workflow progress
Progress of the issue based on the
Contributor Workflow
Describe the bug
Problem is that existing schema descriptions (for fields, objects etc.) modified over schema transformation (eg. using
mapSchema
) are not printed correctly byprintSchemaWithDirectives
. This method prefers descriptions fromastNode
instead from schema config object itself. ButastNode
is immutable in transformation, only schema config object can be changed.To Reproduce Steps to reproduce the behavior:
Reproducer is available here https://github.com/velias/graphqlToolsUtils-printSchemaWithDirectives-reproducer
Expected behavior
printSchemaWithDirectives
method will use description from schema config object (for fields, objects etc.) in final schema string, not fromastNode
.Environment:
@graphql-tools/utils
: 10.0.5Additional context
The text was updated successfully, but these errors were encountered: