diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1b857b61..ecfb37ed 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -20,7 +20,7 @@ jobs: strategy: fail-fast: false matrix: - node-version: [22.19.0, 24] + node-version: [22.19.0, 24, 26] steps: - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4 - uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4 @@ -32,6 +32,14 @@ jobs: - name: Install dependencies run: bun install --frozen-lockfile - run: bun run check + - name: Verify committed Web build + run: | + changes="$(git status --porcelain=v1 --untracked-files=all -- web/dist)" + if [[ -n "$changes" ]]; then + printf '%s\n' "$changes" + echo "web/dist is missing or stale; run bun run build:web and commit the result" + exit 1 + fi - run: bun run test - name: Smoke-test Pi package discovery run: | @@ -61,7 +69,7 @@ jobs: --extension "$package/extensions/git-info/index.ts" \ --extension "$package/extensions/ai-providers/index.ts" \ /dev/null tarballs=("$root"/*.tgz) test "${#tarballs[@]}" -eq 1 - npm install --prefix "$root/app" --ignore-scripts --no-audit --no-fund "${tarballs[0]}" + pi_ai_version="$(node -p 'require("./node_modules/@earendil-works/pi-ai/package.json").version')" + pi_agent_version="$(node -p 'require("./node_modules/@earendil-works/pi-coding-agent/package.json").version')" + pi_tui_version="$(node -p 'require("./node_modules/@earendil-works/pi-tui/package.json").version')" + typebox_version="$(node -p 'require("./node_modules/typebox/package.json").version')" + npm install --prefix "$root/app" --ignore-scripts --no-audit --no-fund \ + "@earendil-works/pi-ai@$pi_ai_version" \ + "@earendil-works/pi-coding-agent@$pi_agent_version" \ + "@earendil-works/pi-tui@$pi_tui_version" \ + "typebox@$typebox_version" \ + "${tarballs[0]}" OPENPI_WEB_TOKEN=aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa \ "$root/app/node_modules/.bin/openpi" web "$root/workspace" --port 0 --no-open \ >"$root/host.log" 2>&1 & @@ -90,12 +107,97 @@ jobs: done origin="$(sed -n 's/^OpenPI Web Workbench is running at //p' "$root/host.log" | tail -n 1)" test -n "$origin" - curl --fail --silent --show-error --output "$root/marked.js" "$origin/marked.js" - grep -q 'marked v18' "$root/marked.js" + curl --fail --silent --show-error --output "$root/index.html" "$origin/" + grep -q '
' "$root/index.html" + grep -Eq ' + + + + + +