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
When using the stitching directives transformer with a transform that changes the type name the merge configs are created under the old type name rather than the transformed type name. This causes the stitched schema to be unable to resolve data for the renamed types.
To Reproduce
Steps to reproduce the behavior:
I've created a simple reproduction of the issue using the RenameTypes class from the wrap package in a public repository located here.
Expected behavior
I would expect that the merge configs are applied to the transformed type names as the original types won't be present in the wrapped subschema is being delegated to.
Environment:
OS: MacOS Big Sur 11.6.3
@graphql-tools/schema: 8.3.2,
@graphql-tools/stitch: 8.4.4,
@graphql-tools/stitching-directives: 2.2.2,
@graphql-tools/wrap: 8.4.3,
NodeJS: 16.11.1
Additional context
We are able to work around this and get data resolving again by creating a secondary subschema config transformer that moves the merge configs to the new type name. Additionally, manually specifying a merge config for the renamed type as you would for a schema extension also causes the stitched schema to resolve properly, but this doesn't scale well if you have a large number of renamed types.
The text was updated successfully, but these errors were encountered:
Describe the bug
When using the stitching directives transformer with a transform that changes the type name the merge configs are created under the old type name rather than the transformed type name. This causes the stitched schema to be unable to resolve data for the renamed types.
To Reproduce
Steps to reproduce the behavior:
I've created a simple reproduction of the issue using the
RenameTypes
class from thewrap
package in a public repository located here.Expected behavior
I would expect that the merge configs are applied to the transformed type names as the original types won't be present in the wrapped subschema is being delegated to.
Environment:
Additional context
We are able to work around this and get data resolving again by creating a secondary subschema config transformer that moves the merge configs to the new type name. Additionally, manually specifying a merge config for the renamed type as you would for a schema extension also causes the stitched schema to resolve properly, but this doesn't scale well if you have a large number of renamed types.
The text was updated successfully, but these errors were encountered: