-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Installing node modules without a version #5097
Comments
As a workaround I assume you can just set a version in your package.json file (or copy/paste it from bower.json to package.json if moving from Bower). |
Yeah! For the meantime, I've been doing that and it's working okay (sorry I didn't put anything to that effect in the description!). I've submitted a few PRs to repositories where this is the case (as it is a required property in the package.json spec) however there are no guarantees that they'll all get addressed. On reflection, this issue is super esoteric as it should only really affects bower components using package.json to manage their dev tooling! |
It looks like with this #5318 installation will start to fail. It seems to me it would be better to show a warning and then use 0.0.0 as the version. There are hundreds of dependencies (mostly polymer components) that do not have a version field. Yes, it is a required part of the spec, but breaking existing workflows doesn't seem like a good idea. Yarn works fine and uses a version of 0.0.0 when there is no package.json. |
Any updates on this? |
Is there any update/workaround for this? |
no update. As this is an open source project, anyone can pick it up and make a PR to fix this issue. I thought there used to be come somewhere in yarn that would set a missing version to |
Looks like this line is supposed to do that |
Is there still no update on this very? Very frustrating there is no way to install via yarn and hence cannot install packages to patch them if they omit the version in monorepo main package.json. |
Do you want to request a feature or report a bug?
bug
What is the current behavior?
Currently if I install a private module, via git/github, the next time yarn.lock is regenerated it will set the version to an empty string e.g.:
If the current behavior is a bug, please provide the steps to reproduce.
What is the expected behavior?
It should resolve to a version of 0.0.0 (as happens on initial install), allowing for the private module to continue to be resolved. This is for continuity and especially useful with migration away from bower to yarn via
bower-away
.Please mention your node.js, yarn and operating system version.
macOS High Sierra
The text was updated successfully, but these errors were encountered: