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

Rebuild issues with core 3.4.0 and compat 3.3.0 #1660

Closed
Techn1x opened this issue Nov 13, 2023 · 3 comments · Fixed by #1661
Closed

Rebuild issues with core 3.4.0 and compat 3.3.0 #1660

Techn1x opened this issue Nov 13, 2023 · 3 comments · Fixed by #1661

Comments

@Techn1x
Copy link

Techn1x commented Nov 13, 2023

Seems to build the first time OK, but then after changing code (causing a rebuild) this error occurs in the browser. Getting it to work again requires deleting node_modules / reinstall. Using pnpm.

Uncaught Error: Assertion Failed: [ember-data-factory-guy] FactoryGuy#setStore needs a valid store instance. You passed in [<teacher-ui-client@service:store::ember113>]

Screenshot 2023-11-13 at 9 07 41 pm

tests seem to show a bit more detail
Screenshot 2023-11-13 at 9 10 53 pm

I have also encountered a similar issue with mirage in some other addons I use

[2023-11-13T03:54:18Z] ERROR in ../rewritten-packages/ember-cli-mirage.41f0748a/node_modules/ember-cli-mirage/_app_/mirage/config.js 2:0-81

[2023-11-13T03:54:18Z] Module not found: Error: Can't resolve '@blakeelearning/app-refresher/mirage/config' in '/workdir/packages'

[2023-11-13T03:54:18Z] @ ./assets/test-app.js 342:13-49

[2023-11-13T03:54:18Z]

[2023-11-13T03:54:18Z] ERROR in ../rewritten-packages/ember-cli-mirage.41f0748a/node_modules/ember-cli-mirage/_app_/mirage/config.js 3:0-93

[2023-11-13T03:54:18Z] Module not found: Error: Can't resolve '@blakeelearning/student-events/mirage/config' in '/workdir/packages'

[2023-11-13T03:54:18Z] @ ./assets/test-app.js 342:13-49

[2023-11-13T03:54:18Z]

[2023-11-13T03:54:18Z] ERROR in ../rewritten-packages/ember-cli-mirage.41f0748a/node_modules/ember-cli-mirage/_app_/mirage/config.js 4:0-86

[2023-11-13T03:54:18Z] Module not found: Error: Can't resolve '@blakeelearning/student-progress/mirage/config' in '/workdir/packages'

[2023-11-13T03:54:18Z] @ ./assets/test-app.js 342:13-49

[2023-11-13T03:54:18Z]

[2023-11-13T03:54:18Z] ERROR in ../rewritten-packages/ember-cli-mirage.41f0748a/node_modules/ember-cli-mirage/_app_/mirage/factories/student-progress.js 1:0-93

[2023-11-13T03:54:18Z] Module not found: Error: Can't resolve '@blakeelearning/student-progress/mirage/factories/student-progress' in '/workdir/packages'

[2023-11-13T03:54:18Z] @ ./assets/test-app.js 348:13-69

[2023-11-13T03:54:18Z]

[2023-11-13T03:54:18Z] ERROR in ../rewritten-packages/ember-cli-mirage.41f0748a/node_modules/ember-cli-mirage/_app_/mirage/serializers/student-progress.js 1:0-95

[2023-11-13T03:54:18Z] Module not found: Error: Can't resolve '@blakeelearning/student-progress/mirage/serializers/student-progress' in '/workdir/packages'

[2023-11-13T03:54:18Z] @ ./assets/test-app.js 354:13-71

[2023-11-13T03:54:18Z]

[2023-11-13T03:54:18Z] 5 errors have detailed information that is not shown.

[2023-11-13T03:54:18Z] Use 'stats.errorDetails: true' resp. '--stats-error-details' to show it.

[2023-11-13T03:54:18Z]

[2023-11-13T03:54:18Z] webpack 5.89.0 compiled with 5 errors and 4 warnings in 7277 ms

[2023-11-13T03:54:18Z] cleaning up

[2023-11-13T03:54:18Z] cleaning up...

[2023-11-13T03:54:18Z] Build Error (PackagerRunner) in ../rewritten-packages/ember-cli-mirage.41f0748a/node_modules/ember-cli-mirage/_app_/mirage/config.js

[2023-11-13T03:54:18Z]

[2023-11-13T03:54:18Z] Module not found: Error: Can't resolve '@blakeelearning/app-refresher/mirage/config' in '/workdir/packages'

Going to guess it's likely to do with #1627

@Techn1x
Copy link
Author

Techn1x commented Nov 14, 2023

Couldn't do a quick downgrade with resolutions either, had to do a full git revert of the renovate commit that bumped to the latest release, so that all the subpackages were downgraded too.
Screenshot 2023-11-14 at 12 25 39 pm

@Techn1x
Copy link
Author

Techn1x commented Nov 14, 2023

@mansona @ef4 do these issues look related to the changes from #1627 ?

@mansona
Copy link
Member

mansona commented Nov 14, 2023

@Techn1x yes it's likely that it's related to that PR, although it shouldn't have affected anyone's apps 🤔 it was intended to be a totally internal refactor. We're currently looking for a reproduction of the issue so that we can debug the problem, are you able to put one together?

ef4 added a commit that referenced this issue Nov 14, 2023
There was a regression in #1605 that broke html clearing on rebuilds, which would cause all assets to get duplicated in the DOM.

(After `removeChild(target)`, `target.nextSibling` goes undefined.)

Fixes #1660.
mansona pushed a commit that referenced this issue Nov 14, 2023
There was a regression in #1605 that broke html clearing on rebuilds, which would cause all assets to get duplicated in the DOM.

(After `removeChild(target)`, `target.nextSibling` goes undefined.)

Fixes #1660.
@ef4 ef4 closed this as completed in #1661 Nov 14, 2023
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

Successfully merging a pull request may close this issue.

2 participants