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

Issues with having local graphql package installed #20

Open
ian opened this issue Nov 1, 2021 · 0 comments
Open

Issues with having local graphql package installed #20

ian opened this issue Nov 1, 2021 · 0 comments

Comments

@ian
Copy link
Owner

ian commented Nov 1, 2021

This arose around having a peer requirement for gqty. We want to just integrate gqty as the client so we should be able to knock this out at the same time.

Ensure that there is only one instance of "graphql" in the node_modules
directory. If different versions of "graphql" are the dependencies of other
relied on modules, use "resolutions" to ensure only one version is installed.

https://yarnpkg.com/en/docs/selective-version-resolutions

Duplicate "graphql" modules cannot be used at the same time since different
versions may have different capabilities and behavior. The data from one
version used in the function from another could produce confusing and
spurious results.
    at instanceOf (/Users/ian/Projects/project/node_modules/next-graphql/node_modules/@graphql-tools/stitch/node_modules/@graphql-tools/utils/node_modules/graphql/jsutils/instanceOf.js:41:19)
    at Object.isObjectType (/Users/ian/Projects/project/node_modules/next-graphql/node_modules/@graphql-tools/stitch/node_modules/@graphql-tools/utils/node_modules/graphql/type/definition.js:129:37)
    at mapArguments (/Users/ian/Projects/project/node_modules/next-graphql/node_modules/@graphql-tools/stitch/node_modules/@graphql-tools/utils/index.js:2549:26)
    at mapDefaultValues (/Users/ian/Projects/project/node_modules/next-graphql/node_modules/@graphql-tools/stitch/node_modules/@graphql-tools/utils/index.js:2438:24)
    at Object.mapSchema (/Users/ian/Projects/project/node_modules/next-graphql/node_modules/@graphql-tools/stitch/node_modules/@graphql-tools/utils/index.js:2368:96)
    at /Users/ian/Projects/project/node_modules/next-graphql/node_modules/@graphql-tools/stitch/index.js:1352:15
    at /Users/ian/Projects/project/node_modules/next-graphql/node_modules/@graphql-tools/stitch/index.js:1705:124
    at Array.flatMap (<anonymous>)
    at /Users/ian/Projects/project/node_modules/next-graphql/node_modules/@graphql-tools/stitch/index.js:1705:104
    at Array.reduce (<anonymous>) {
  page: '/api/graphql'
}
[GQtyError: invalid json response body at http://localhost:3000/api/graphql reason: Unexpected token < in JSON at position 0] {
  type: 'invalid-json'
}
error - Error: Cannot use GraphQLObjectType "Attribute" from another module or real
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

1 participant