-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
[5.3.7] Issue with use in nested addon #9498
Comments
I'm not sure this can be worked around but feel free to try. Unfortunately we don't have a real addon-main in v2 addons, its far more restricted (which is why we can't simply do |
Thanks, this works if a copy it into a project so I have high hopes! I'll test as soon as it's released (should I back port it?) and can tweak it with a PR if needed. The complication with v2 adding is what prevented me from making any attempt at this myself, I'm just not familiar with the rules there yet. |
is already released! |
Yeah it is! The process here has gotten super fast, LOVE IT! |
Reproduction
This is reproducible in any app which consumes an addon that provides ember data, you can see it in our CI build failure when upgrading ember-data pin Ilios
However it's most easily seen in the
test-app
of a monorepo embroider v2 addon with:Description
Installing
ember-data
after 5.3.4 in an add-on and consuming that add-on from an app causes a build failure with the error:Cannot read properties of undefined (reading 'project')
which comes fromconst dirname = app.project.root;
in addon-main.cjs which was added in #9477.I've seen this issue worked around before with something like the
findApp
method in ember-cli-babel because you need to traverse up the tree before you get to the actual app.I've also used the slightly messy:
Versions
The text was updated successfully, but these errors were encountered: