AWS Amplify looking for graphql when I am not using graphql

60 views Asked by At

I am working on an react-admin project and I am implementing a cognito login with federated users as well. For some reason, when I install aws-amplify I get a series of errors related to graphql. We use apollo and graphql for a similar react admin project, but it is not mentioned anywhere in this project. Some of these errors are shown below. I'm really at a loss to explain why this is happening. Any help is appreciated.

ERROR in ./node_modules/@aws-amplify/pubsub/lib-esm/Providers/AWSAppSyncRealTimeProvider.js 311:36-48
export 'GraphQLError' (imported as 'GraphQLError') was not found in 'graphql' (module has no exports)

ERROR in ./node_modules/@aws-amplify/pubsub/lib-esm/Providers/AWSAppSyncRealTimeProvider.js 322:38-50
export 'GraphQLError' (imported as 'GraphQLError') was not found in 'graphql' (module has no exports)

ERROR in ./node_modules/@aws-amplify/pubsub/lib-esm/Providers/AWSAppSyncRealTimeProvider.js 446:40-52
export 'GraphQLError' (imported as 'GraphQLError') was not found in 'graphql' (module has no exports)

ERROR in ./node_modules/@aws-amplify/pubsub/lib-esm/Providers/AWSAppSyncRealTimeProvider.js 628:34-46
export 'GraphQLError' (imported as 'GraphQLError') was not found in 'graphql' (module has no exports)

ERROR in ./node_modules/@aws-amplify/pubsub/lib-esm/Providers/AWSAppSyncRealTimeProvider.js 643:36-48
export 'GraphQLError' (imported as 'GraphQLError') was not found in 'graphql' (module has no exports)

ERROR in ./node_modules/@aws-amplify/pubsub/lib-esm/Providers/AWSAppSyncRealTimeProvider.js 669:34-46
export 'GraphQLError' (imported as 'GraphQLError') was not found in 'graphql' (module has no exports)

ERROR in ./node_modules/graphql/error/GraphQLError.mjs 9:0-42
Module not found: Error: Can't resolve './printError' in '/Users/jfoxworth/CodeBase/dmn/elections/node_modules/graphql/error'
Did you mean 'printError.mjs'?
BREAKING CHANGE: The request './printError' failed to resolve only because it was resolved as fully specified
(probably because the origin is strict EcmaScript Module, e. g. a module with javascript mimetype, a '*.mjs' file, or a '*.js' file where the package.json contains '"type": "module"').
The extension in the request is mandatory for it to be fully specified.
Add the extension to the request.
0

There are 0 answers