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

Doesn't work with PNP node modules #353

Open
factoidforrest opened this issue Jan 19, 2022 · 1 comment
Open

Doesn't work with PNP node modules #353

factoidforrest opened this issue Jan 19, 2022 · 1 comment
Assignees
Labels
bug Something isn't working
Milestone

Comments

@factoidforrest
Copy link

This is a brittle way to go about invoking the apollo schema downloader CLI.

 const command = `${__dirname}/../../.bin/apollo client:download-schema --endpoint=${input} ${tmpFile} ${

This doesn't work with PNP and I think it will also break in some monorepos, where, for instance, your library could be at two lower level node-module folders but apollo is at the top level deduped.

Since the apollo CLI is javascript, I would either find a way to invoke the functionality you need directly with a javascript import, or use a different library to do the job. You could probably also get away without writing to a temp file which would be cleaner.

To make the current lib work with PNP, I had to unplug both apollo and mst-gql, and then do a manual symlink between their folders to get the binary where your lib expects it to be.

@jesse-savary jesse-savary added the bug Something isn't working label Nov 6, 2022
@jesse-savary jesse-savary added this to the v0.18.0 milestone Nov 6, 2022
@jesse-savary
Copy link
Member

There's a good chance this works already w/ 0.17.0 but I will do some manual testing.

@jesse-savary jesse-savary self-assigned this Nov 6, 2022
@jesse-savary jesse-savary moved this from Needs triage to High priority in Stability and Automated Testing Nov 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Development

No branches or pull requests

2 participants