-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
feat(core): support bun as a package manager #22402
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
☁️ Nx Cloud ReportCI is running/has finished running commands for commit 85a0eef. As they complete they will appear below. Click to see the status, the terminal output, and the build insights. 📂 See all runs for this CI Pipeline Execution ✅ Successfully ran 6 targets
Sent with 💌 from NxCloud. |
This is the bare minimum required to support Bun.js @JamesHenry please take a look again. Some changes are required to get that green check with minimal effort. The file changes are as minimal as the CI checks will allow. I can't cut all the things you want. Please pass this through for Bun.js support on NX! 🚀 |
👍 |
@JamesHenry I removed the git hook file. Reverted it. |
It's green again. This would be greatly appreciated if we could merge and make a new release. |
@JamesHenry It is my birthday today! 🎂 🎈 |
@@ -126,7 +133,6 @@ export function getPackageManagerCommand( | |||
}; | |||
}, | |||
npm: () => { | |||
// TODO: Remove this |
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.
Please revert this, I did not ask you to remove the existing comment. I asked you to remove the copy of this comment you added fresh in your PR
@laynef Happy Birthday! I can appreciate your enthusiasm in wanting to land this great feature, but we need to take a measured approach. So far all we have been able to really focus on is reverting the many changes you made to the codebase that are unrelated to supporting bun. Once we are at the point where the PR no longer contains unnecessary refactors and changes, then we will need to add e2e test coverage for bun usage for Nx. We will not land major features in Nx without adding high quality e2e tests. For the e2e tests, we will definitely need updates to Thanks for a the hard work, and I will continue to help you get this over the line, but please respect my requests for you to revert unrelated to changes and compare your local behaviour to the CI and master branch. I think there are some issues with your local setup somehow that are causing things to behave differently. |
@laynef Speaking of your local set up and things behaving differently - are you running things through bun all the time? Maybe that's the issue? Please try setting up your environment and running all commands per the https://github.com/nrwl/nx/blob/54d47805de2803de183ab1dee6e05e161efc6d41/CONTRIBUTING.md and see if things improve for you and let me know |
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.
Hi, I just wanted to bring up that we should be careful with Nx features relying on the package manager, I remember facing issues with those when we upgraded Yarn to v4, so it's probably better to check that those features are working well with Bun. Here are the features I think about:
- generatePackageJson option from webpack, remix, and other executors
- generateLockfile option from js tsc, swc, and other executors
Regarding the lockfile, Bun has the capability to produce a lockfile in the Yarn format, a format already compatible with Nx. See the related docs.
Thank you @edbzn, great callouts! |
I've spoken with the team and, in addition to the above comments, the major piece missing from this PR right now is the lock file parsing needed to truly support bun as a package manager. You will need to add to the Bun has a binary lockfile format, so you will not be able to parse it directly. My understanding is that we will instead want to run I also just want to add an overall disclaimer to this PR (particularly as I see you posting screenshots of running tasks via
Full runtime support can be handled in a follow up once this PR to complete bun package manager support goes in. Hopefully that's all clear for now! Thanks again |
Ohh okay I see what you what is supposed to be supported. I can add that. |
You can take a look at this PR it had the bun lock all sorted #19113 should be able to drop in to this PR without issue |
Damn, we are soooo close. Also, Bun for Windows will be released in a couple of days! |
Bun is out! Lets go :) |
Closing this. You guys figure it out |
This pull request has already been merged/closed. If you experience issues related to these changes, please open a new issue referencing this pull request. |
Current Behavior
Expected Behavior
Related Issue(s)
Fixes #