ValidationError: Progress Plugin crash when webpack resolves to 5.106.2

Aperta Adatta ai principianti
#486 1 commento 1 reazione 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
68/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Tranquilla
Stack tecnologico
javascript, webpack
Ambito
build-system

Direzione di ricerca

Inizia da 10up-toolkit/scripts/build.js:30, dove vengono passate le opzioni di ProgressPlugin, e confronta tali opzioni con lo schema di webpack 5.106.2 descritto nell’issue. Riproduci il problema con webpack 5.106.2 e conferma che la build riesca senza un override di npm, mantenendo la compatibilità con 5.105.2.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Describe the bug

Running 10up-toolkit build (or start) fails immediately with a ValidationError
from webpack's ProgressPlugin when npm resolves webpack to 5.106.2.
The same setup works correctly with webpack 5.105.2.

Steps to Reproduce
  1. Create a project with [email protected] as the only dev dependency (no explicit webpack pin).
  2. Run npm install — npm resolves webpack to 5.106.2.
  3. Run npm run build.
Error Output

ValidationError: Invalid options object. Progress Plugin has been initialized
using an options object that does not match the API schema.

options should be one of these: object { activeModules?, dependencies?, dependenciesCount?, entries?, handler?, modules?, modulesCount?, percentBy?, profile? } | function Details:
options has an unknown property 'name'.
options has an unknown property 'color'.
options has an unknown property 'reporters'.
options has an unknown property 'reporter'.

Full stack trace points to 10up-toolkit/scripts/build.js:30.

Root Cause

webpack 5.106.2 removed the name, color, reporters, and reporter
properties from the ProgressPlugin options schema. 10up-toolkit's build
script passes an options object containing those properties, which now fails
schema validation.

Workaround

Pin webpack to 5.105.2 via npm overrides in package.json:

"overrides": {
  "webpack": "5.105.2"
}

Then reinstall:

rm -rf node_modules package-lock.json && npm install
Expected Behaviour

npm run build should work with the webpack version npm resolves automatically, without requiring a manual override.

Screenshots, screen recording, code snippet

No response

Environment information
  • 10up-toolkit: 6.5.1
  • webpack (broken): 5.106.2
  • webpack (working): 5.105.2
  • Node.js: v24.14.0
  • npm: 10.x
  • Device: MacBook Pro
  • OS: Tahoee 26.4.1
WordPress information

No response

Code of Conduct
  • I agree to follow this project's Code of Conduct
Lingua principale
JavaScript
Stelle
147
Fork
21
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di 10up/10up-toolkit

Tutte le issue di 10up/10up-toolkit

Issue simili

Altre issue su JavaScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.