electron-userland/electron-builder

25.0.0-alpha.9 was released to npm as "latest"

AviVahl opened this issue · 13 comments

The new version was released as "latest", overriding the previous "24.13.3"

$ npm dist-tags electron-builder
latest: 25.0.0-alpha.9
next: 25.0.0-alpha.8

can also be seen on: https://www.npmjs.com/package/electron-builder?activeTab=versions

leevva commented

Hi! When you fix this?

It can be easily fixed using https://docs.npmjs.com/cli/v10/commands/npm-dist-tag (has to be someone with publish access to the npm package)

@mmaietta any insights if this was intentional or can be rolled back? An -alpha package is now marked as latest.

See #8241

Hmmmm, it should have occurred as the CI/CD has always published as next only. Just reset latest back to 24.13.3.

I'll look into the CI config, but it's already set to next

"publishConfig": {
"tag": "next"
}

Thank you all for calling this out!

@mmaietta in #8253 same happened and electron-builder@25.0.0-alpha.10 is marked latest.

Oh gosh darn it. I'll fix that asap. Not sure why the automation isn't working correctly now despite no changes. Thanks for the quick heads up!

Honestly, I have this same automation setup in app-builder repo and it works exactly as prescribed -> publishes all new releases as next. IDK what's started happening here in this project since no CI/CD changes have occurred. I'll give it a go in updating pnpm and see if that resolves the issue

@mmaietta in #8253 same happened and electron-builder@25.0.0-alpha.10 is marked latest.

This is still happening, and sometimes in a big monorepo it causes v24 to be installed from one dependency and 25.0.0-alpha.10 from another ...

I don't believe so, looking at the release that was performed yesterday, it's correctly tagged as next
https://www.npmjs.com/package/electron-builder?activeTab=versions
https://www.npmjs.com/package/electron-updater?activeTab=versions

Indeed, now with v24.13.3 installed, it is pulling the same version as dependency again.
Before, I manually pinned app-builder-lib@24.13.2 and this solved it.

What happened to me in detail:
For the last months (on 24.13.2) everything was fine and without warnings.
Then, I think about 1-2 weeks ago, I started getting warnings after pnpm update about wrong versions of peer dependencies.
The warnings were about electron-builder-squirrel-windows@2.24.2 and electron-builder-squirrel-windows@25.0.0-alpha.10 were both installed.

pnpm why electron-builder-squirrel-windows showed something like:
electron-builder@24.13.2 depends on app-builder-lib@25.0.0-alpha.10 but also depends on electron-builder-squirrel-windows@2.24.2. And app-builder-lib@25.0.0-alpha.10 depends on electron-builder-squirrel-windows@25.0.0-alpha.10, which led to the conflict warnings.

This is based on what I remember, because now since the release of v24.13.3, I can not reproduce it any more.
Unfortunately I did not make any screenshots or logs, since I do not use electron-builder-squirrel-windows in that project and could quickly solving it by pinning app-builder-lib@24.13.2.

But since I found this issue here, I will pay attention if it happens again after pnpm update and keep you updated.

It happened again after pnpm update.
Here some more details, as promised:

Screenshot 2024-08-17 at 16 59 35 Screenshot 2024-08-17 at 16 59 57

my .npmrc:

engine-strict=true
auto-install-peers=true
shamefully-hoist=true
strict-peer-dependencies=false

a reduced package.json:

{
  "name": "TEST",
  "private": true,
  "engines": {
    "node": "^20",
    "pnpm": "^9"
  },
  "packageManager": "pnpm@9.4.0",
  "scripts": {
    "dev": "nuxi dev"
  },
  "devDependencies": {
    "electron": "^31.4.0",
    "electron-builder": "^24.13.3",
    "nuxt": "^3.12.4",
    "nuxt-electron": "^0.7.0"
  }
}

And the resulting pnpm-lock.yaml.txt.

@mmaietta the same issue persists even when electron-builder is updated to 25.0.5. But it looks like the issue is because of app-builder@25.0.0-alpha.10 is still marked as latest: https://www.npmjs.com/package/app-builder-lib?activeTab=versions

Thanks for notifying me! I've updated the latest tag for app-builder-lib. Not sure why it was frozen on the alpha version, it seems other packages within electron-builder also have the same issue. Just finished updating all of them with the proper latest tag.

Please let me know if the issue persists.

EDIT: looks fine after manually adding and removing the app-builder-lib as dev-dependency

--- old answer:

pnpm update still throwing up this warning:
Screenshot 2024-09-10 at 10 40 49

looks like there are still references to the alpha in app-builder-lib....

pnpm why electron-builder-squirrel-windows gives:
Screenshot 2024-09-10 at 10 44 11