Skip to content

fix(ci): bump Node to 22 for Vite 8 (dist rebuild workflow + Space Dockerfile)#27

Merged
nicolas-rabault merged 1 commit into
huggingface:mainfrom
cn0303:fix/frontend-dist-stale-node-bump
Jun 9, 2026
Merged

fix(ci): bump Node to 22 for Vite 8 (dist rebuild workflow + Space Dockerfile)#27
nicolas-rabault merged 1 commit into
huggingface:mainfrom
cn0303:fix/frontend-dist-stale-node-bump

Conversation

@cn0303

@cn0303 cn0303 commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

What does this PR do?

A Dependabot PR bumped the repo to Vite 8 (build(deps-dev): bump vite 5→8),
which requires Node ^20.19.0 || >=22.12.0. Two build pipelines were still
pinned to Node 18, so npm run build fails on both. This bumps both to
Node 22.

The two breakages (same root cause)

1. .github/workflows/build_frontend.yml — the "Rebuild frontend/dist"
workflow. On Node 18 its build failed silently (a stale generated file, not a
red ❌), so the committed frontend/dist stopped being regenerated and the
shipped bundle fell behind the merged source — e.g. the PR #21 calibration
UI never reached dist, so a plain pip install / lelab run still served the
old UI.

2. frontend/Dockerfile — the image the Hugging Face Space builds
(FROM node:18-alpine). Its npm run build step fails, so the Space currently
shows a build error and the live demo is down.

image

⚠️ Worth flagging: this is a Dependabot blind spot — the bot bumped the
build tool's Node requirement, but nothing bumped the node-version in CI or
the node:18-alpine base image, and the failures are easy to miss (a stale
file, and a Space build error on a separate runtime). It may be worth having
Dependabot also watch actions/setup-node / the Dockerfile base image so a
future build-tool bump can't silently desync these again.

Notes

  • The rebuild workflow also triggers on changes to its own file, so merging
    this re-runs it on Node 22 and regenerates frontend/dist from the current
    source — no hand-built dist is committed here.
  • Verified the Vite 8 build passes on Node ≥20 locally; the Dockerfile change is
    the base-image tag only.

…ckerfile)

A Dependabot PR bumped the repo to Vite 8 (build(deps-dev): bump vite 5→8),
which requires Node ^20.19.0 || >=22.12.0. Two build pipelines were still
pinned to Node 18, so `npm run build` fails on both:

- .github/workflows/build_frontend.yml — the "Rebuild frontend/dist" workflow.
  Its build failed silently, so the committed frontend/dist stopped being
  regenerated and the shipped bundle fell behind the merged source (e.g. the
  PR huggingface#21 calibration UI never reached dist).
- frontend/Dockerfile — the image the Hugging Face Space builds. Its
  `npm run build` step fails, so the Space shows a build error.

Bump both to Node 22. The rebuild workflow also triggers on changes to its own
file, so merging this re-runs it and regenerates dist from the current source.
@cn0303
cn0303 force-pushed the fix/frontend-dist-stale-node-bump branch from f9bb453 to f2a0695 Compare June 8, 2026 21:55
@cn0303 cn0303 changed the title fix(ci): bump frontend-rebuild workflow to Node 22 so dist stays in sync fix(ci): bump Node to 22 for Vite 8 (dist rebuild workflow + Space Dockerfile) Jun 8, 2026
@nicolas-rabault
nicolas-rabault self-requested a review June 9, 2026 08:24

@nicolas-rabault nicolas-rabault left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you,
You fix things faster than I catch the bugs 🤗.

@nicolas-rabault
nicolas-rabault merged commit 32aca71 into huggingface:main Jun 9, 2026
1 check passed
@cn0303
cn0303 deleted the fix/frontend-dist-stale-node-bump branch June 9, 2026 09:05
@cn0303

cn0303 commented Jun 9, 2026

Copy link
Copy Markdown
Contributor Author

Thanks a lot!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants