0no-co / gql.tada

🪄 Magical GraphQL query engine for TypeScript
https://gql-tada.0no.co
MIT License
2.45k stars 36 forks source link

GraphiQL VSCode warning: Multischema type checking doesn't seem to work #271

Closed nathanchapman closed 2 months ago

nathanchapman commented 2 months ago

Describe the bug

Added an unexpected field to the query, which reflects in VS Code

image

but type checking passed unexpectedly

image

Reproduction

No response

gql.tada version

1.6.1

Validations

kitten commented 2 months ago

We'll need a reproduction here, without more information there's nothing I can do, sorry

nathanchapman commented 2 months ago

@kitten will get one added shortly

kitten commented 2 months ago

Actually, I think I can see what's going on. The dialog here says "GraphQL: Validation".

This is not a warning from GraphQLSP, but from the GraphiQL/"GraphQL Language Feature Support" extension (i.e. https://marketplace.visualstudio.com/items?itemName=GraphQL.vscode-graphql)

This has been a bit problematic. It doesn't seem like we can alter or suggest changes to the in-repo .vscode/settings.json to prevent these errors but the gql.tada doctor command should point out to you that you have the extension installed and that it's an issue.

kitten commented 2 months ago

Duplicate of https://github.com/0no-co/gql.tada/issues/194

Edit: There's a reference to a fix in that extension here: https://github.com/graphql/graphiql/issues/3588#issuecomment-2069209638 (Provided it's configured correctly to exclude ts(x) files handled by GraphQLSP/gql.tada