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

apollo-server-express 2.11 + graphql 15.0 = error: Must provide Source. Received: undefined. #3952

Closed
NGPixel opened this issue Apr 4, 2020 · 9 comments

Comments

@NGPixel
Copy link

NGPixel commented Apr 4, 2020

Upon upgrading the graphql package to 15.0.0, the package apollo-server-express throws an error as soon as it's being included. Reverting back to 14.6.0 fixes the issue.

 error: Must provide Source. Received: undefined.

Steps to reproduce:

  • Install latest apollo-server-express package (2.11.0)
  • Install latest graphql package (15.0.0)
  • Run sample code (index.js):
const apollo = require('apollo-server-express')
  • Process will crash immediately with above error.
@NGPixel NGPixel changed the title apollo-server-express 2.11 + graphql 15.0 = Must provide Source. Received: undefined. apollo-server-express 2.11 + graphql 15.0 = error: Must provide Source. Received: undefined. Apr 4, 2020
@Vultraz
Copy link

Vultraz commented Apr 9, 2020

Also encountered this. It seems apollo-server-express (and by extension, apollo-server-core rely on a slightly outdated version of graphql-tools: graphql/graphql-js#2503 (4.0.0). Forcing resolution for graphql-tools": ^4.0.6 should work, I think.

@Glen-Moonpig
Copy link
Contributor

Same issue with apollo-server-lambda 2.13.0 + graphql 15.0.0

@clok
Copy link

clok commented May 10, 2020

Also seen with apollo-server-hapi and graphql v15. Has to drop down to graphql v14 latest.

@Vultraz
Copy link

Vultraz commented May 10, 2020

Really hope they fix this for server v3 at least.

@prabhuignoto
Copy link

prabhuignoto commented Jun 5, 2020

having the same issue. downgrading to graphql@14 seems to solve the issue

@lolgesten
Copy link

lolgesten commented Aug 6, 2020

Still the same in apollo-server 2.16.1.

We get multiple graphql versions cause @types/graphql-upload@8.0.3 drags in graphql@14.

The double graphql version problem were also found here graphql/graphql-js#2503

$ npm ls graphql
lookback@0.0.1 /Users/martin/dev/lk/server
├─┬ apollo-server@2.16.1
│ └─┬ apollo-server-core@2.16.1
│   └─┬ @types/graphql-upload@8.0.3
│     └── graphql@14.7.0 
└── graphql@15.3.0 

@sannamar
Copy link

sannamar commented Feb 1, 2021

This is still an issue with apollo-server 2.19.2.

Running npm ls graphql outputs the following:

├─┬ apollo-server@2.19.2
│ └─┬ apollo-server-core@2.19.2
│   └─┬ @types/graphql-upload@8.0.3
│     └── graphql@14.7.0
└── UNMET PEER DEPENDENCY graphql@15.5.0

@glasser
Copy link
Member

glasser commented Feb 6, 2021

I'm going to close this as duplicate of #4865 but I'll make sure to note that it might be slightly different than just a peer dep issue.

@glasser
Copy link
Member

glasser commented Feb 11, 2021

Apollo Server v2.21.0 will fix this. I published alpha packages with version v2.21.0-alpha.0. I'd love some folks to try the alpha and let me know if it works for you! Both folks who actually use the upload feature and those who don't! It's currently in the release-2.21.0 branch, being tracked at #4922

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 20, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants