apollographql / apollographql/vscode-graphql

Error in "Loading schema for ...": GraphQLSchemaValidationError: Unknown directive "@aws_subscribe".

Open
#59 0 comments 1 reaction 0 assignees View on GitHub
Dominant language
TypeScript
Stars
78
Forks
23
PR merge metrics
No merged PRs in 30d

Description

Hi,
I have a problem while adding the extension with the local schema file.
We are using aws-app-sync. Below is the example schema

```
Type Article{
title:String!
description:String
author:Author
}

type Subscription {
updateTitleSubscription(domain: String!): Article
@aws_subscribe(mutations: ["updateTitle"])
}
```
my `apollo.config.js`
```
module.exports = {
client: {
includes: [
'./src/**/stores/**/*.js',
'./src/**/stores/**/*.ts',
'./src/**/stores/**/*.tsx'
],
service: {
localSchemaFile: './src/graphql/schema.graphql'
}
}
}

```
Is there a way to add custom decorators like above or shall i remove them to work?
TIA :smiley:

┆Issue is synchronized with this [Jira Task](https://apollographql.atlassian.net/browse/NEBULA-938) by [Unito](https://www.unito.io)

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with apollo.config.js and src/graphql/schema.graphql, then reproduce local-schema loading for the @aws_subscribe directive. Trace how the extension validates this schema; done means the schema loads without the unknown-directive error or the supported handling for the directive is documented.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript, vscode
Domain
devtools
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.