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

ember-source is required for babel-plugin-ember-template-compilation #306

Conversation

NullVoxPopuli
Copy link
Collaborator

@NullVoxPopuli NullVoxPopuli commented Nov 9, 2024

CI is currently failing on main, as does pnpm build in a real generated project (which is what CI does).

@NullVoxPopuli NullVoxPopuli added the bug Something isn't working label Nov 9, 2024
@@ -36,6 +36,9 @@
"@embroider/addon-shim": "^1.8.7",
"decorator-transforms": "^2.0.0"
},
"peerDependencies": {
"ember-source": ">= <%= latestEmberSource %>"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the rationale to put the version hardcoded into index.js? We have versions everywhere right in the template file (here), so why deviate from this pattern?

I would get it if the versions is determined in a smarter way than being hardcoded, but that's not the case. Seems more confusing to me to maintain tbh.

Copy link
Collaborator Author

@NullVoxPopuli NullVoxPopuli Nov 10, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I couldn't figure out how to get the version. Maybe i missed something? LatestVersion is async, and the locals object is sync

We have versions everywhere right in the template file (here), s

Where? 😅

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMO I would do same what we do in ember-cli addon blueprint - make it second most recent LTS version

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Folks can change it if they want

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Where? 😅

Like everywhere in https://github.com/embroider-build/addon-blueprint/blob/main/files/__addonLocation__/package.json? 😅

We have all those versions specifiers hardcoded in that file, why not also ember-source?

IMO I would do same what we do in ember-cli addon blueprint - make it second most recent LTS version

I agree. Also it needs to match what we have in the Readme and whatever ends up in test-app/config/ember-try.js as the minimum Ember version.

Copy link
Collaborator Author

@NullVoxPopuli NullVoxPopuli Nov 10, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I do want to drop ember older than built in types tho

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will happen in another pr to unblock built in types

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unrelated to this PR tho because we just need a template compiler.

I don't think that's true, as you are introducing a peer dependency on ember-source here, but not on the version we supported until now, which is 4.12, but on >= 5.4. Which means, without violating the peer dependency, you are supposed to require Ember 5.4+ now. But then the addon setup would be very inconsistent, as ember-try and Readme still refer to 4.12.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah I see what you mean

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed 58d2907

@NullVoxPopuli NullVoxPopuli merged commit 70b3852 into main Nov 10, 2024
16 checks passed
@NullVoxPopuli NullVoxPopuli deleted the ember-source-is-required-for-babel-plugin-ember-template-compilation branch November 10, 2024 21:02
@github-actions github-actions bot mentioned this pull request Oct 16, 2024
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
None yet
Development

Successfully merging this pull request may close these issues.

3 participants