`vp env pin`: lockfile not updated after changing `devEngines.runtime`

Abierto
#3,371 4 comentarios 0 reacciones 1 asignado Ver en GitHub

Los mantenedores suelen responder en 1 día

@liangmiQwQ ya está trabajando en esto.

Desde el 6/11/2026.

Evaluación

Este issue todavía no se ha evaluado.

Descripción

pending triage triage: failed
Describe the bug

vp env pin updates devEngines.runtime in package.json but leaves pnpm-lock.yaml at the old node@runtime: version. vp outdated then shows the old version as current, and vp install --frozen-lockfile (e.g. in CI) fails.

Expected: refresh the lockfile, or at least tell the user to run vp install.

Reproduction

N/A (empty directory is enough)

Steps to reproduce
cd "$(mktemp -d)"
echo '{"name":"x"}' > package.json
vp env pin 24.21.0 [email protected] --target dev-engines
vp install
vp env pin lts --target dev-engines  # resolves to 26.13.0
grep -A1 '"node"' package.json       # "version": "26.13.0"
grep 'runtime:' pnpm-lock.yaml       # still runtime:24.21.0
vp outdated                          # node (dev): current 24.21.0
vp install --frozen-lockfile         # fails
System Info
$ vp env current
Node.js:
  Version    26.13.0
  Source     devEngines.runtime
  Installed  true
  Mode       managed

Package Manager:
  Name       pnpm
  Version    12.18.0
  Source     devEngines.packageManager
  Installed  true
  Mode       managed

$ vp --version
vp v1.5.0
Used Package Manager

pnpm

Logs
$ vp outdated
┌────────────┬─────────┬─────────┐
│ Package    │ Current │ Latest  │
├────────────┼─────────┼─────────┤
│ node (dev) │ 24.21.0 │ 26.13.0 │
└────────────┴─────────┴─────────┘

$ vp install --frozen-lockfile
Error: ERR_PNPM_OUTDATED_LOCKFILE

  × installing dependencies
  ╰─▶ Cannot install with "frozen-lockfile" because pnpm-lock.yaml is not up
      to date with package.json.

        Failure reason:
        specifiers in the lockfile don't match specifiers in package.json:
      * in importers["."]:
      * 1 dependency is mismatched:
        - node (lockfile: runtime:24.21.0, manifest: runtime:26.13.0)
  help: Regenerate the lockfile with `pnpm install --lockfile-only` so that
        pnpm-lock.yaml reflects the current package.json, then re-run `pnpm
        install --frozen-lockfile`.
Lenguaje dominante
Rust
Estrellas
6.5k
Forks
297
Merge medio
1 d 4 h
PR fusionados (30 d)
238

Preparar el entorno

Abrir en Codespaces

Inicia el contenedor de desarrollo del proyecto en tu navegador, con tu propia cuenta de GitHub.

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de voidzero-dev/vite-plus

Todos los issues de voidzero-dev/vite-plus

Issues similares

Más issues de Rust

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.