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

chore(): update lerna to 5.3.0 #25682

Merged
merged 3 commits into from
Jul 28, 2022
Merged

Conversation

JamesHenry
Copy link
Contributor

Hi Folks 👋

I'm one of the new maintainers of Lerna (via Nrwl).

As I noted on #25497, I'm sorry that you had to initially downgrade from v5 back to v4.

I used Ionic's repo to troubleshoot a subtle difference between some of the implementation details we upgraded as part of v4->v5. Lerna uses a lot of packages produced by the npm team and in this case the package concerned with running lifecycle scripts needed to swapped out entirely after npm reimplemented it from scratch.

I added a missing piece of logic needed for the new package and released 5.3.0 of lerna just now, which addresses the issues you experienced before.

I even verified your full publishing flow locally by using a verdaccio instance instead of the real npm registry.

Please let me know if you have any questions or concerns! 🙏

@JamesHenry JamesHenry requested a review from a team as a code owner July 27, 2022 14:03
@liamdebeasi
Copy link
Contributor

Thank you very much! Apologies for not reaching out sooner. I saw your comment on my previous PR, but it slipped my mind. I'll give this a test and let you know how it goes.

@JamesHenry
Copy link
Contributor Author

P.S.

It is by no means a requirement, but one huge benefit you can opt into after this change goes in is to get lerna to delegate task running to Nx (instead of p-map and p-queue like it has done historically).

All you need to do over and above this PR is set "useNx": true in your lerna.json and everything will still work as it did before: lerna run will just get faster, have smart computation caching and allow for distributed task execution:

Over and above that, the Nx Console VSCode extension is then able to analyze your lerna workspace and give you visualizations of how your projects relate to one another:

image

Again, all you need to do to get these things is set "useNx": true in your lerna.json (after merging this PR)

https://github.com/redwoodjs/redwood is an example of a popular OSS repo that is already leveraging these benefits with their lerna setup.

Copy link
Contributor

@liamdebeasi liamdebeasi left a comment

Choose a reason for hiding this comment

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

I tested this using our dev build action as well, and it worked: https://github.com/ionic-team/ionic-framework/actions/runs/2747291733.

Thank you again! We really appreciate the help.

@JamesHenry
Copy link
Contributor Author

Awesome, thanks for the fast review and testing @liamdebeasi! Feel free to reach out if you have any queries or concerns post-merge! @mhartington can always reach me on slack too 🙂

@liamdebeasi liamdebeasi changed the title chore: update lerna to 5.3.0 chore(): update lerna to 5.3.0 Jul 28, 2022
@liamdebeasi liamdebeasi merged commit ea83073 into ionic-team:main Jul 28, 2022
@liamdebeasi
Copy link
Contributor

Merged. Thank you again!

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 this pull request may close these issues.

2 participants