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
Implement --resume-from [package-name]
#4690
Labels
Milestone
Comments
They are sorted but scripts are executed asynchronously, so when a script is executed on several projects at the same time, the order in which they print output is random. |
|
@zkochan Great to hear that! Should we transform this issue into a feature request to implement this? |
zkochan
changed the title
Implement Jun 6, 2022
pnpm -r exec 'pwd'
non-consistent package sorting--resume-from [package-name]
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
pnpm version: 7.0.0
Code to reproduce the issue:
pnpm -r exec 'pwd' | md5
Expected behavior:
If I ran the above command infinite times, I would expect to see the same result over and over.
Actual behavior:
There are slight variations between the executions. I get that the order can vary some times, since topologically, they're all correct, but this inconsistent behavior is very annoying for taking control over your dependency graph and creating some automations on top of it.
Additional information:
Last week we've had an important issue with
windows-latest
on GitHub Actions, where installing Lerna stopped working for a few hours. I guess they reverted it, since it went back to working again, but still, this made me and my team at https://github.com/kiegroup/kie-tools remeber that Lerna has been deprecated and unmaintained for a while now, so we started researching alternatives andpnpm
was kind of an obvious choice, mostly due to the control it gives the developers to really own theirnode_modules
.The motivation for this issue comes exactly from this migration. We work on a medium-sized monorepo, and due to the differences between yarn workspaces installs and pnpm installs, some adjustments that expanded through all the codebase had to be made. We fixed some issues along the way and even found some peer problems (!) too. Right now, I'm fixing all of our unit tests, and it's really annoying to pass a full build after each fix without being able to start a build from the last failure on.
Maven has the very useful
-rf :module-name
(where "rf" stands for "resume from") option, that lets you start a build from an arbitrary package within your topologically sorted list of dependencies.I can only imagine that being possible only if
pnpm -r exec 'pwd'
produces consistent outputs.If you like the idea, consider this a suggestion for implementing something like
-rf [package-name]
, that can work together with multiple --filters, as long as the package-name to resume from exists on the filtered list.Cheers and thanks for this amazing tool!
node -v
prints: v16.13.2The text was updated successfully, but these errors were encountered: