Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introspection error with latest CLI #49

Closed
noahemmet opened this issue Jul 24, 2019 · 3 comments
Closed

Introspection error with latest CLI #49

noahemmet opened this issue Jul 24, 2019 · 3 comments

Comments

@noahemmet
Copy link

Version 0.13.0 of Apollo iOS was just released, and it includes an update to the CLI from 1.9 to 2.16. Unfortunately, there's a breaking change around @directives.

When I run the code gen build script, I get a CLIError: Error in "Loading schema for Unnamed Project": Error: Introspection result missing directive locations: { onField: true, onOperation: false, args: [[Object]], name: "include", description: "Directs the executor to include this field or fragment only when the ifargument is true.", onFragment: true }

I haven't delved into it too much, but the error message was added in graphql/graphql-js#1429, in response to dotansimha/graphql-code-generator#556 (comment).

(I opened a ticket on the Apollo GitHub as well: apollographql/apollo-ios#665.)

Any thoughts?

@paulofaria
Copy link
Member

Sorry for the huge delay. Were you able to overcome this issue?

@noahemmet
Copy link
Author

No worries! Unfortunately no; I’ve had to pin to an earlier version of Apollo. It sort of feels like it’s missing a directive_location field or something, but I’m not sure exactly what that should be... if you have any tips, I’ll take another look!

@noahemmet
Copy link
Author

Figured it out! The Vapor extension I was using wasn't including the directives field in the introspection query: StevenLambion/GraphQLRouteCollection#3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants