Closed mreishus closed 1 week ago
Thank you for your PR!
When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:
This comment will be updated as you work on your PR and make changes. If you think that some of those checks are not needed for your PR, please explain why you think so. Thanks for cooperation :robot:
The e2e test report can be found here. Please note that it can take a few minutes after the e2e tests checks are complete for the report to be available.
Follow this PR Review Process:
Still unsure? Reach out in #jetpack-developers for guidance!
We didn't stay with 9.3.0 specifically. We don't want to constantly chase updates, so as long as things keep working we let the ^9.3.0
in .engines.pnpm
allow later versions to be used. To keep that behavior, it looks like we should set manage-package-manager-versions=false
in .npmrc
so pnpm 10 (once that comes out and we switch to it) doesn't try to exactly match this field.
Probably we should also add something to the existing version checks to verify that this aligns with all the other pnpm version fields.
So, I first tried 9.11 and one of the checks failed. I'll repush that to see what it was.
Sadly, it seems like this field cannot take a range. If I don't provide this value and use devbox+corepack, it starts writing to it, like: + "packageManager": "pnpm@9.11.0+sha512.0a203ffaed5a3f63242cd064c8fb5892366c103e328079318f78062f24ea8c9d50bc6a47aa3567cabefd824d170e78fa2745ed1f16b13 2e16436146b7688f19b"
I see, so it says this:
Run pnpm/action-setup@v4.0.0
Running self-installer...
Error: Multiple versions of pnpm specified:
- version 9.3.0 in the GitHub Action config with the key "version"
- version pnpm@9.11.0 in the package.json with the key "packageManager"
In reference to this which is also not autoupdating: https://github.com/Automattic/jetpack/blob/5878fb5a5a07b94580fe4dec8c057e7b6125c124/.github/versions.sh#L5
We could try this, is this too many static versions? I know @sgomes is currently trying to get JP to work in devbox without corepack (we're both using devbox now). Maybe we won't need this..
Ok, we found two ways to get JP to work in Devbox; but both require changing files committed to the repo.
"packageManager": "pnpm@9.11.0"
to package.json.
engines.pnpm
in the same file as well as PNPM_VERSION
in .github/versions.sh
.use-node-version=22.9.0
to .npmrc
.
.nvmrc
.I didn't have any objection to setting packageManager
to 9.3.0, matching .github/version.sh
. As long as we set the npmrc setting so local pnpm doesn't try to enforce that version once we move to v10.
Option 2: Add
use-node-version=22.9.0
to.npmrc
.
Again, we don't really want to force a particular version of node on everyone.
OK, I updated it to provide the info for corepack users.
Proposed changes:
packageManager
field topackage.json
to specifypnpm@9.3.0
.This aligns with the version currently used in the GitHub Actions workflow and falls within the engines.pnpm range.
When using the repo with Devbox and Corepack, Corepack may attempt to download a newer pnpm version outside this range. Adding the packageManager field improves compatibility for Corepack users, ensuring consistency across local development and CI environments without impacting others.
I chose 9.3 specifically because it lines up with that's in the github actions.
Other information:
Jetpack product discussion
Does this pull request change what data or activity we track or use?
Testing instructions: