MetaMask / action-npm-publish

GitHub Action to publish to NPM
MIT License
8 stars 6 forks source link

switch package version comparison to yarn #34

Closed mariosant closed 1 year ago

mariosant commented 1 year ago

Hi there!

I had an issue trying to this action with a private npm registry. I had to add a .yarnrc.yml file that contains the private scope & registry but the absence of .npmrc did not allow the action to correctly compare versions. This lead to errors because npm was not able to find the private module.

This PRs tries to fix this issue by migrating the comparison to yarn.

rickycodes commented 1 year ago

@mariosant lgtm!

mcmire commented 1 year ago

Hmm, it looks like this has started causing issues with new deployments. The publish script here now thinks that the "latest" version of each package is 0.0.0-use.local, and because this always differs from the "current" version, it tries to publish all packages when a new release is issued. You can see an example of this failure here: https://github.com/MetaMask/core/actions/runs/5180316837/jobs/9334551029. I think we need to figure out another way to solve this problem. I'll make a new issue for this. Update: New issue created here: https://github.com/MetaMask/action-npm-publish/issues/49

mcmire commented 12 months ago

Since this change, we have returned this action to using npm view: https://github.com/MetaMask/action-npm-publish/pull/51, which addressed the issue I mentioned above. Let us know if the newest version(s) cause issues and we will figure out another solution.