ember-graphql / ember-apollo-client

🚀 An ember-cli addon for Apollo Client and GraphQL
MIT License
279 stars 72 forks source link

Fix build for Embroider #404

Closed balinterdi closed 2 years ago

balinterdi commented 3 years ago

When building an app that has a dependency on ember-apollo-client and has Embroider switched on, I see the following error:

Module not found: Error: Can't resolve '../../test-waiters' in '$TMPDIR/embroider/ad9b46/node_modules/@ember/test-helpers/-internal/debug-info.js'

(This error is similar to the one discussed at https://github.com/emberjs/ember-test-waiters/issues/158)

Digging down, I've found it came from the @ember/test-waiters dependency that ember-apollo-client has.

The app had the following versions:

ember-cli: 3.27.0
node: 14.17.0
os: linux x64

(It also failed similarly with the latest Ember CLI, 3.28).

Interestingly, it didn't fail on macOS computers, only on Linux (no idea about Windows).

Upgrading the @ember/test-waiters dependency to 3.0.0 fixed it so I think if tests pass, this PR is good to merge?

nelstrom commented 2 years ago

We have an Ember app that runs on Embroider. I recently upgraded our app from v3.26.2 of Ember to v3.28.6. After the upgrade, our app would not build. It failed with this message:

cleaning up...
Build Error (PackagerRunner) in node_modules/@ember/test-helpers/-internal/debug-info.js

Module not found: Error: Can't resolve '@ember/test-waiters' in '$TMPDIR/embroider/39a280/node_modules/@ember/test-helpers/-internal/debug-info.js'

I was able to fix this build error by switching from the latest release of ember-apollo-client to the fork that @balinterdi created.

Screenshot 2021-12-01 at 12 21 18

It would be great to see this PR merged and included in a new release of ember-apollo-client. Is there anything I can do to help?

balinterdi commented 2 years ago

@josemarluedke Is there something preventing this PR from being considered for merging?

josemarluedke commented 2 years ago

@balinterdi sorry for the delay. This PR got into the cracks.