Repository navigation
chore(deps): bump Docusaurus 3.10.2 + React 19 and k8s.io/x-net, clearing all criticals - #218
Merged
Merged
Conversation
…iticals `npm audit` had drifted to 52 advisories (18 critical, 25 high, 9 moderate) — well past the 17 c865b8c left — because almost every @docusaurus/* package inherits from a core that was four minors behind. Bumps: - @docusaurus/core, preset-classic, module-type-aliases, types 3.9.2 -> 3.10.2. This alone clears the 18 criticals, and it also resolves the two image-size advisories (GHSA-w3rx-r6r6-pgpr, GHSA-5p2g-fcmc-qvqq) that were previously unfixable: 3.10.2's mdx-loader pulls image-size >= 2.0.4, which did not exist when we last looked. The "unfixable upstream" note on those is now wrong. - react / react-dom 18.3.1 -> 19.3.1. Supported since Docusaurus 3.7; 3.10.2 declares `react: "^18.0.0 || ^19.0.0"`. - vitest 3.2.7 -> 4.1.12, @vitejs/plugin-react 4.7 -> 6.1.2, jsdom 26 -> 29, @testing-library/jest-dom 6 -> 7, and patch bumps for @testing-library/react and user-event. plugin-react 6 requires vite ^8, so the `vite` override floor moves ^6.4.3 -> ^8.3.4. None of this touches the shipped site: Docusaurus builds with webpack, and vite/vitest exist only for the component tests. - @easyops-cn/docusaurus-search-local ^0.55.1 -> ^0.55.3. The lockfile is regenerated rather than patched, deliberately. It had a stale `react-helmet-async` entry resolving to upstream 1.3.0 instead of the `npm:@slorber/react-helmet-async` alias that @docusaurus/types declares; only the fork supports React 19, and that exact entry is what blocked ionic-team/ionic-docs#4616. It now resolves to the fork. Override changes. Added postcss-selector-parser ^7.1.6 and tinypool ^2.2.0 — both had advisories with no fixed dependent release, so the floor has to be forced here; recorded in package.json rather than only in the lock so they survive regeneration. Removed the `esbuild` ^0.25.0 override: vite 8 builds with rolldown/oxc and no longer pulls esbuild at all, so that entry matched nothing in the tree. Every other override was checked and still binds to an installed package. Result: 52 -> 28 advisories, 0 critical, 0 moderate. All 28 remaining are one root advisory, braces <=3.0.3, inherited through micromatch/fast-glob/globby/chokidar into the @Docusaurus tree. braces' latest published release *is* 3.0.3, so there is nothing to pin to — the same shape as the old image-size problem. It is build-time only; the runtime image is nginx serving static files. Also cleared two deprecation warnings while here: `onBrokenMarkdownLinks` moved under `markdown.hooks` (v4 removes the top-level option), and vitest.config.js renamed to .mjs, since it uses ESM syntax and Vite is making the native config loader the default. Verified: npm ci resolves clean with no peer errors, npm test 4/4 under vitest 4 + jsdom 29, `docusaurus build --locale en` succeeds with no warnings. Site search was checked in a browser against the production build, not just the build exit code — @easyops-cn/docusaurus-search-local has an open React 19 issue upstream (easyops-cn/docusaurus-search-local#474) and 0.55.3 is unaffected: queries return highlighted results, and the console is clean of React and hydration errors. The dashboard page renders and degrades correctly without a validator backend. Assisted-by: claude-code/claude-opus-5 Signed-off-by: Riccardo Capraro <capraroriccardo@gmail.com>
…k clean) Two separate problems in the validator's module graph. k8s.io/api, apimachinery and client-go were pinned at v0.30.3 — four minors behind the v1.33 apiserver they talk to, outside client-go's supported skew. Moved to v0.33.13 to match the cluster (Aruba runs v1.33.2, solo k3d runs v1.33.6) rather than to the newest v0.37.1, which would put the client four minors *ahead* and reintroduce the same skew from the other side. This pulled protobuf 1.33.0 -> 1.36.5 and refreshed kube-openapi, utils, sigs.k8s.io/json and structured-merge-diff. golang.org/x/net was at v0.58.0, which govulncheck flags with five findings reachable from our code — all golang.org/x/net/http2, traced through http.ListenAndServe and the client-go Secret GET in vclientForPair. Fixed in v0.60.0; went to v0.61.0. That carried x/sys, x/term and x/text along with it. `go mod tidy` raised the go directive 1.25.0 -> 1.26.0, required by x/net v0.61.0. The builder image is already golang:1.26-alpine3.24 and CI builds the validator only through Docker (no setup-go step), so nothing else needs to move. On govulncheck numbers: scanning with the local toolchain is misleading here, because the shipped binary's stdlib comes from the builder image, not from the developer's machine — the same reasoning c865b8c used. Local go1.26.2 reports 20 stdlib findings purely because it is behind; go1.26.9, the current patch that golang:1.26-alpine3.24 resolves to, reports **no vulnerabilities found** after this change. Before it, that same toolchain reported 5. go build, go vet and go test all pass. Assisted-by: claude-code/claude-opus-5 Signed-off-by: Riccardo Capraro <capraroriccardo@gmail.com>
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.
Why
npm auditindocs/had drifted to 52 advisories (18 critical, 25 high, 9 moderate) — well past the 17 that #214 left — because nearly every@docusaurus/*package inherits from a core that was four minors behind. On the Go side,k8s.io/*sat atv0.30.3, four minors behind the v1.33 apiserver it talks to, andgolang.org/x/nethad five findings reachable from our own code.Result
govulncheck(go1.26.9)What changed
docs (
b75351f)@docusaurus/*3.9.2 → 3.10.2. Clears all 18 criticals on its own, and resolves the twoimage-sizeadvisories (GHSA-w3rx-r6r6-pgpr, GHSA-5p2g-fcmc-qvqq) that chore(deps): remediate known vulnerabilities in Go, npm, and base images #214 recorded as unfixable — upstream has since publishedimage-size2.0.4, which 3.10.2'smdx-loaderpicks up.react/react-dom18.3.1 → 19.3.1. Supported since Docusaurus 3.7; 3.10.2 declaresreact: "^18.0.0 || ^19.0.0".vitest3→4,@vitejs/plugin-react4→6,jsdom26→29,@testing-library/jest-dom6→7.plugin-react6 requires vite ^8, so theviteoverride floor moves ^6.4.3 → ^8.3.4.@easyops-cn/docusaurus-search-local→ 0.55.3.postcss-selector-parser^7.1.6 andtinypool^2.2.0 (advisories with no fixed dependent release); removed theesbuildoverride, which matched nothing once vite 8 moved to rolldown/oxc. Every remaining override was checked and still binds.onBrokenMarkdownLinksmoved undermarkdown.hooks, andvitest.config.js→.mjs.validator (
f4c25a1)k8s.io/api|apimachinery|client-gov0.30.3 → v0.33.13, matching the cluster (Aruba v1.33.2, solo k3d v1.33.6). Deliberately not the newest v0.37.1, which would put the client four minors ahead and reintroduce the same skew from the other side.golang.org/x/netv0.58.0 → v0.61.0, fixing five reachablehttp2findings.go mod tidyraised the go directive 1.25.0 → 1.26.0, which the existinggolang:1.26-alpine3.24builder already satisfies.The lockfile is regenerated, on purpose
It carried a stale
react-helmet-asyncentry resolving to upstream 1.3.0 rather than thenpm:@slorber/react-helmet-asyncalias@docusaurus/typesdeclares. Only the fork supports React 19, and that exact entry is what blocked ionic-team/ionic-docs#4616. Worth spot-checking on review:Expect
react@19.3.1, the@slorberfork, andimage-size@2.0.4.What is not fixed
All 28 remaining advisories are a single root:
braces <=3.0.3, inherited throughmicromatch→fast-glob/globby/chokidarinto the whole@docusaurustree.braces' latest published release is 3.0.3, so there is no version to pin to and an override cannot help — the same shape theimage-sizeproblem had until upstream shipped a fix. It is build-time only; the runtime image is nginx serving static files.28 entries here is one problem, not 28.
Verification
npm ciresolves clean, no peer errorsnpm test4/4 under vitest 4 + jsdom 29docusaurus build --locale ensucceeds with no warningsgo build,go vet,go testpass;govulncheckclean under go1.26.9@easyops-cn/docusaurus-search-localhas an open React 19 issue (#474) and 0.55.3 is unaffected: queries return highlighted results, console clean of React and hydration errors. The dashboard renders and degrades correctly without a validator backend.Reviewer note
Four test-stack majors land together here. The argument for accepting them as one change is that none can reach the shipped site — Docusaurus builds with webpack, and that stack exists solely to run
ValidateCheck.test.jsx. Happy to split them out if you'd rather.🤖 Generated with Claude Code