Skip to content

feat: Add compat with pi 0.66.0 (#6) #28

feat: Add compat with pi 0.66.0 (#6)

feat: Add compat with pi 0.66.0 (#6) #28

Workflow file for this run

name: CI
on:
pull_request:
push:
branches:
- main
workflow_dispatch:
jobs:
quality:
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Check out repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Read tool versions
id: tool_versions
run: ./.github/scripts/read-tool-versions.sh >> "$GITHUB_OUTPUT"
- name: Set up pnpm
uses: pnpm/action-setup@b307475762933b98ed359c036b0e51f26b63b74b # v5.0.0
with:
version: ${{ steps.tool_versions.outputs.pnpm }}
- name: Set up Node.js
uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6.3.0
with:
node-version: ${{ steps.tool_versions.outputs.node }}
cache: pnpm
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Check formatting, lint, and types
run: pnpm run check
- name: Run tests
run: pnpm test
- name: Smoke test extension entrypoint
run: pnpm run smoke
- name: Build package bundle
run: pnpm run pack
- name: Verify package contents
run: pnpm pack --dry-run
resolve-pi-compat:
name: Resolve pi compatibility window
runs-on: ubuntu-latest
timeout-minutes: 10
outputs:
pi-versions: ${{ steps.pi_versions.outputs.versions }}
latest-pi-version: ${{ steps.pi_versions.outputs.latest }}
oldest-pi-version: ${{ steps.pi_versions.outputs.oldest }}
steps:
- name: Check out repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Read tool versions
id: tool_versions
run: ./.github/scripts/read-tool-versions.sh >> "$GITHUB_OUTPUT"
- name: Set up Node.js
uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6.3.0
with:
node-version: ${{ steps.tool_versions.outputs.node }}
- name: Resolve supported pi versions
id: pi_versions
env:
PI_VERSION_COUNT: 3
run: node ./.github/scripts/resolve-pi-versions.mjs
integration-compat:
name: Integration compatibility (Node ${{ matrix.node-version }}, pi ${{ matrix.pi-version }})
needs: resolve-pi-compat
runs-on: ubuntu-latest
timeout-minutes: 20
strategy:
fail-fast: false
matrix:
node-version:
- 22
- 24
pi-version: ${{ fromJson(needs.resolve-pi-compat.outputs.pi-versions) }}
steps:
- name: Check out repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Read tool versions
id: tool_versions
run: ./.github/scripts/read-tool-versions.sh >> "$GITHUB_OUTPUT"
- name: Set up pnpm
uses: pnpm/action-setup@b307475762933b98ed359c036b0e51f26b63b74b # v5.0.0
with:
version: ${{ steps.tool_versions.outputs.pnpm }}
- name: Set up Node.js
uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6.3.0
with:
node-version: ${{ matrix.node-version }}
cache: pnpm
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Install pi compatibility target
run: pnpm add -D @mariozechner/pi-ai@${{ matrix.pi-version }} @mariozechner/pi-coding-agent@${{ matrix.pi-version }} --lockfile=false
- name: Run integration tests against pi ${{ matrix.pi-version }}
run: pnpm run test:integration
- name: Summarize compatibility target
run: |
{
echo "## Integration compatibility target"
echo
echo "Resolved compatibility window: ${{ needs.resolve-pi-compat.outputs.pi-versions }}"
echo "This job tested: Node ${{ matrix.node-version }}, pi ${{ matrix.pi-version }}"
echo
} >> "$GITHUB_STEP_SUMMARY"