You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have been encountering this issue after upgrading our app from Ember 3.24.6 to 3.28.8.
Basically, if I try to access any defined service in a routeless engine that has been included by a routeable engine, an error is generated and the engine does not properly render its content. It can be easily seen by accessing the following repo I created in order to replicate the issue:
Selecting the first link mounts the routeless engine by itself: the service is correctly accessible.
Selecting the second link accesses a routeable engine, which itself mounts the same routeless engine as above - but in this case the rendering errors out with the following error: Uncaught (in promise) Error: Assertion Failed: Attempting to inject an unknown injection: 'service:myService'.
This is happening with the 0.9.0 (latest) version of ember-engines. Both engines have the necessary service listed in the app's app.js and in their own engine.js.
Any advice would be appreciated. Is it possible there's an additional dependency missing somewhere or that this is not a recommended pattern? I've taken a good look at the docs but there doesn't appear to be any advice around this kind of scenario one way or the other.
Thanks!
The text was updated successfully, but these errors were encountered:
@gtb104 I moved the routeless engine service definitions (the engines = { ... { dependencies: { services: [ hash) out of the root application app.js and into the routeable engine's engine.js and that seemed to do the trick. 👍
I have been encountering this issue after upgrading our app from Ember 3.24.6 to 3.28.8.
Basically, if I try to access any defined service in a routeless engine that has been included by a routeable engine, an error is generated and the engine does not properly render its content. It can be easily seen by accessing the following repo I created in order to replicate the issue:
https://github.com/KeithKosh/ember-engines-services-embed-issue
Uncaught (in promise) Error: Assertion Failed: Attempting to inject an unknown injection: 'service:myService'
.This is happening with the 0.9.0 (latest) version of ember-engines. Both engines have the necessary service listed in the app's
app.js
and in their ownengine.js
.Any advice would be appreciated. Is it possible there's an additional dependency missing somewhere or that this is not a recommended pattern? I've taken a good look at the docs but there doesn't appear to be any advice around this kind of scenario one way or the other.
Thanks!
The text was updated successfully, but these errors were encountered: