mirror of
https://github.com/hanzoai/ingress.git
synced 2026-10-26 02:47:15 +00:00
Two compounding issues blocked the upstream image build: 1. An incomplete dep bump moved `vitest: ^3.2.4` → `^4.0.3` and added `@vitest/web-worker: ^4.0.2`, but left `vite: ^5.4.19` and `@vitest/coverage-v8: ^3.2.4`. Vitest 4 needs Vite 6+, so vitest's internal `vite/module-runner` import threw ERR_PACKAGE_PATH_NOT_EXPORTED on every test run. Pin vitest + @vitest/web-worker back to ^3.2.4 to match the rest of the trio. (Forward-port to vitest 4 is an explicit step that should also bump vite to ^6 and coverage-v8 to ^4.) 2. The webui test suite has rebrand-era request mocks at /v1/ingress/* but `BASE_PATH` (src/libs/utils.ts) reads `window.APIUrl` at module-load and falls back to ''. With BASE_PATH='', SWR fetched /http/routers/<x> and missed every msw handler — 4 tests timed out on `waitFor(...not.toBeUndefined)`. Set `window.APIUrl=/v1/ingress` at the top of test/setup.ts (before the mock server import) to match production. Result: 28 test files, 125/125 pass. The Build experimental image workflow can now produce ghcr.io/hanzoai/ingress:<branch>; the v1.7.x branch and v1.7.37 tag both unblock.