-
-
Notifications
You must be signed in to change notification settings - Fork 589
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
Ensure "type" = "module" ES declaration in pre-release.sh #4350
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm surprised to learn that matrix-js-sdk is being released as an ES module nowadays, because I thought matrix-react-sdk couldn't consume those yet. But, this fix seems appropriate especially with the context from Rich in the linked issue. Thanks!
d608039
Sorry, this appears to be breaking our release process https://github.com/matrix-org/matrix-js-sdk/actions/runs/10469900988/job/28993898692 and is preventing me from doing a release. I'm going to have to revert this. |
* Reapply "Add "type" = "module" to ensure it is present (#4350)" (#4352) This reverts commit 8214fd7. * Mark prettier config file as CommonJS I *think* this will fix a problem with the release process in which we saw an error: ``` Error: Invalid configuration for file "/home/runner/work/matrix-js-sdk/matrix-js-sdk/package.json": Error: module is not defined in ES module scope Error: This file is being treated as an ES module because it has a '.js' file extension and '/home/runner/work/matrix-js-sdk/matrix-js-sdk/package.json' contains "type": "module". To treat it as a CommonJS script, rename it to use the '.cjs' file extension. ```
Checklist
public
/exported
symbols have accurate TSDoc documentation.Attempts to fix the issue #4347. Added a line in
scripts/pre-release.sh
that should add"type" = "module"
topackage.json
. Analogous to 432aaa4.Reasoning:
CI order goes Release Process > Release Make >
pre-release.sh
. It does not involve the other release script with the previous fix.Unfortunately, I can't test or verify. The CI workflows are too complex.
Signed-off-by: Jonas Black [email protected]