fix(ci): point _selftest at current repo and reject pnpm <10 consumers#49
Merged
Merged
Conversation
`tests/rspack/_selftest.ts` was copied verbatim from the legacy `web-infra-dev/rspack-ecosystem-ci` when the rspack ecosystem CI moved into `rstackjs/rstack-ecosystem-ci`. The `repo` / dir / name-assertion were never updated, so every from-commit run was cloning the now-dormant legacy repo (last pushed 2026-04-28). That repo still pins pnpm@9.15.2, and `applyPackageOverrides` always writes a `pnpm-workspace.yaml` containing only `overrides:` and `strictDepBuilds:` — pnpm <10 treats that file as workspace-definition only and rejects it with `ERROR packages field missing or empty`, so the selftest never actually verified anything about the upstream rspack build. Switch the suite to clone this repo (which pins pnpm@10.33.4) and also guard `applyPackageOverrides` to refuse pnpm <10 consumers up front with an actionable message, instead of producing the confusing install-time error if any other consumer regresses to pnpm 9.
…guard The pnpm@6 branch was redundant — any consumer pinning pnpm <10 is caught by the `packageManager` check below. Consumers without a `packageManager` field aren't strictly pinned and may resolve to a modern pnpm anyway, so falling back to the ni-agent shape would be unreliable.
This was referenced May 25, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
tests/rspack/_selftest.tswas copied verbatim from the legacyweb-infra-dev/rspack-ecosystem-ciduring the move intorstackjs/rstack-ecosystem-ci. Therepofield, the cloned directory name, and thepkg.nameassertion all still point at the legacy repo (last pushed 2026-04-28). Switch them torstackjs/rstack-ecosystem-ci/rstack-ecosystem-ciso the selftest exercises the active repo.pnpm@9.15.2.applyPackageOverridesunconditionally writes apnpm-workspace.yamlcontaining onlyoverrides:+strictDepBuilds:into the consumer; pnpm <10 treats that file as a workspace definition and rejects it withERROR packages field missing or empty. So the selftest was failing atpnpm installand never actually verified anything about the upstream rspack build (latest impact: run 26384019463,execute-all (_selftest)).applyPackageOverrides: if the consumer'spackageManagerfield ispnpm@<10(or ni reportspnpm@6), throw a clear "requires pnpm >= 10" error instead of producing the confusing install-time crash. Targets both the migrated selftest path (the new home pinspnpm@10.33.4so this is a no-op) and any future consumer that regresses below 10.Test plan
_selftestsuite underrspack-ecosystem-ci-from-commit.ymlreachespnpm run selftestscript(it currently fails atpnpm install).applyPackageOverrideschange is additive; existing consumers all pin pnpm >=10).packageManagertopnpm@9.15.2and confirm the new error fires before thepnpm installstep.