Closed HandyappGroup closed 6 months ago
Please update your version of the Codegen CLI by following the instructions at: ...
@HandyappGroup this error is correct, and expected. You cannot mix versions. You must install, and use, the CLI that from the dependency version your project is using. This looks like you were using preview-defer.2
and then changed to 1.10.0
but didn't re-install the CLI.
Error: JavaScriptError: GraphQLSchemaValidationError-There can be only one directive named "@defer".-GraphQLSchemaValidationError"
As for this error, I suggest fixing the first one and then we can focus on whether this is still relevant and in which version.
HI. I've updated Apollo and CLi version to use preview-defer.2 but still getting the same error.
Take a look in your schema for the @defer
directive definition, it will look like this:
directive @defer(label: String, if: Boolean! = true) on FRAGMENT_SPREAD | INLINE_FRAGMENT
Make sure there is only one @defer
directive definition.
Take a look in your schema for the
@defer
directive definition, it will look like this:directive @defer(label: String, if: Boolean! = true) on FRAGMENT_SPREAD | INLINE_FRAGMENT
Make sure there is only one
@defer
directive definition.
Removed defer but throwing now different errors. I am happy to share graphqls file over email for team to have a look.
I am happy to share graphqls file over email for team to have a look.
@xLuciferSx - sure, email it to me (
I am happy to share graphqls file over email for team to have a look.
@xLuciferSx - sure, email it to me (
) and I'll take a look.
Email sent :)
Closing as this seems to have been a syntax problem in an operation file. The graphql-js
error messages are misleading and don't clearly point to the actual problem.
Do you have any feedback for the maintainers? Please tell us by taking a one-minute survey. Your responses will help us understand Apollo iOS usage and allow us to serve you better.
Summary
I've downloaded the latest version, which technically fixes the @defer issue, but the problem is still exists.
Version
1.10.0
Steps to reproduce the behavior
Just try to generate new files using defer version fix. This is the version i've used - https://github.com/apollographql/apollo-ios/releases/tag/preview-defer.2
Logs
No response
Anything else?