-
Notifications
You must be signed in to change notification settings - Fork 205
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
[@auto-it/npm] Invalid option --registry
passed to lerna version
#2129
Comments
I found a temporary workaround by specifying the registry as |
This workaround doesnt seem to work anymore, but i don't understand why.
Also in package.json
Still when I run
Any idea? |
The defaulting code still seems to be there: Lines 250 to 255 in 0c96b56
The registry is parsed as so, so either should work: auto/plugins/npm/src/set-npm-token.ts Lines 16 to 30 in 0c96b56
The default registry is auto/plugins/npm/src/set-npm-token.ts Line 13 in 0c96b56
It seems to still be working for me, so I can only assume is isn't detecting the config for some reason? |
Maybe its something about the |
Installing Auto (https://intuit.github.io/auto/index) for automated publishing. Since this repo has a number of labels already, I disabled the default labels and added custom entries to match the labels that were created. I created a basic workflow for releasing that doesn't have anything lerna specific (although `lerna` is used internally with `auto`) but run the `release` npm script (which is `auto shipit --dry-run -v` for now). Testing locally I ran into an issue where an lerna error will be thrown. This issue seems to be known (see intuit/auto#2129) with a workaround by adding a "registry" entry to lerna.json (although seems to continue to fail with --dry-run option).
* Installing and configuring Auto Installing Auto (https://intuit.github.io/auto/index) for automated publishing. Since this repo has a number of labels already, I disabled the default labels and added custom entries to match the labels that were created. I created a basic workflow for releasing that doesn't have anything lerna specific (although `lerna` is used internally with `auto`) but run the `release` npm script (which is `auto shipit --dry-run -v` for now). Testing locally I ran into an issue where an lerna error will be thrown. This issue seems to be known (see intuit/auto#2129) with a workaround by adding a "registry" entry to lerna.json (although seems to continue to fail with --dry-run option). * Removing dry-run from shipit After testing the lerna comands locally, I'm removing `--dry-run` to test publishing canary versions in a pull-request. * adding `very verbose` logging to diagnose lerna command timeout * Consistent use of `prepare` and `npm-run-all` Using `prepare` npm lifecycle script for all packages (as opposed to prepublishOnly) and consistently using `npm-run-all` for any package that has multiple scripts to run during `prepare`. * upgrading gh actions and adding more npm logging * dropping npm-run-all * Turning down the logging level
I'm having the same issue. Running --dry-run results in |
Observing the same behaviour. |
For anyone still experiencing this issue, downgrading lerna to 3.0.0 is a workaround. |
Oooo this seems pretty bad. I hand't noticed this in their changelogs. Would someone experiencing the issue want to make a PR? I'll be fast about merging |
@hipstersmoothie looks like this is no longer relevant, it was added as a global option in Seems redundant to retrospectively fix it, given Auto jumped from 3 - 7.x. |
Awesome! |
I've just hit this issue whilst trying to debug why our repo started creating odd changelogs and unintentionally published a major version. We're running Unfortunately the global --registry argument was later removed in this PR which according to the commit in main was released in v7.2.0. @hipstersmoothie I've opened a PR here that removes the flag from all version commands that are wrapped in dry-run checks. |
Describe the bug
When upgrading to
[email protected]
they seem to be more strict about valid options.lerna version
as called in auto therefore fails as--registry
is an option oflerna publish
but notlerna version
.To Reproduce
[email protected]
to[email protected]
in a monorepo project.auto shipit
.Expected behavior
In theory
[email protected]
should be a clean upgrade, but because Auto is using an invalid option it fails.Environment information:
Additional context
Error log:
Code that adds the
--registry
flag seems to be here: https://github.com/intuit/auto/blob/main/plugins/npm/src/index.ts#L941The text was updated successfully, but these errors were encountered: