You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
1. The issue provides a reproduction available on Github, Stackblitz or CodeSandbox
Make sure to fork this template and run yarn generate in the terminal.
Please make sure the GraphQL Tools package versions under package.json matches yours.
2. A failing test has been provided
3. A local solution has been provided
4. A pull request is pending review
Describe the bug
transformInputValue fails with:
TypeError: value.map is not a function at transformInputValue (.../node_modules/@graphql-tools/utils/cjs/transformInputValue.js)
when the client is depending on the array input field coercion.
To Reproduce
I'm using graphql-tools to build a stitched schema using graphql-mesh. I have an upstream graphql server that accepts a query with an input type, and the input type contains a field with an array type. E.g.
Some existing code in the application is sending fieldX: "valueY" instead of fieldX: ["valueY"], but now that I'm sending that query to my new graphql-mesh-based server it hits transformInputValue because I'm using a rename transform to rename the field.
Expected behavior
transformInputValue should check to see if the incoming value is an array before mapping over it.
Environment:
OS: MacOS
@graphql-tools/utils: 8.8.0
NodeJS: 16
Additional context
The text was updated successfully, but these errors were encountered:
Issue workflow progress
Progress of the issue based on the Contributor Workflow
Describe the bug
transformInputValue
fails with:when the client is depending on the array input field coercion.
To Reproduce
I'm using
graphql-tools
to build a stitched schema usinggraphql-mesh
. I have an upstream graphql server that accepts a query with an input type, and the input type contains a field with an array type. E.g.Some existing code in the application is sending
fieldX: "valueY"
instead offieldX: ["valueY"]
, but now that I'm sending that query to my newgraphql-mesh
-based server it hitstransformInputValue
because I'm using arename
transform to rename the field.Expected behavior
transformInputValue
should check to see if the incoming value is an array before mapping over it.Environment:
@graphql-tools/utils
:8.8.0
Additional context
The text was updated successfully, but these errors were encountered: