93 lines
3.5 KiB
YAML
93 lines
3.5 KiB
YAML
name: Runner E2E Public Preview Qualification
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
|
|
permissions: {}
|
|
|
|
jobs:
|
|
public_preview:
|
|
name: Transform, OCR, and render one real runner screenshot
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: 10
|
|
permissions:
|
|
actions: read
|
|
contents: read
|
|
steps:
|
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
|
|
with:
|
|
persist-credentials: false
|
|
|
|
- uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7
|
|
with:
|
|
node-version: 24
|
|
|
|
- uses: pnpm/action-setup@0977fd99725f1db4007ccb2928dbb4e90d06cc86 # v6
|
|
env:
|
|
NPM_CONFIG_AUDIT: "false"
|
|
NPM_CONFIG_FUND: "false"
|
|
NPM_CONFIG_UPDATE_NOTIFIER: "false"
|
|
with:
|
|
version: 9.15.4
|
|
|
|
- uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7
|
|
with:
|
|
node-version: 24
|
|
cache: pnpm
|
|
|
|
- run: pnpm install --frozen-lockfile --ignore-scripts
|
|
|
|
- name: Install exact public preview tools
|
|
run: |
|
|
set -euo pipefail
|
|
sudo apt-get update -qq
|
|
sudo apt-get install --no-install-recommends -y imagemagick tesseract-ocr
|
|
convert -version
|
|
tesseract --version
|
|
|
|
- name: Download one passed real runner screenshot artifact
|
|
env:
|
|
GH_TOKEN: ${{ github.token }}
|
|
run: |
|
|
set -euo pipefail
|
|
mkdir -p representative-cell
|
|
gh api repos/paperclipai/paperclip/actions/artifacts/9948272233/zip > representative-cell.zip
|
|
unzip -q representative-cell.zip -d representative-cell
|
|
test -f "$(find representative-cell -type f -name final-state.png -print -quit)"
|
|
|
|
- name: Build trusted one-cell normalized report
|
|
env:
|
|
PAPERCLIP_RUNNER_E2E_REPORT_ROOT: ${{ github.workspace }}/representative-cell
|
|
PAPERCLIP_RUNNER_E2E_REPORT_OUT: ${{ github.workspace }}/private-report
|
|
PAPERCLIP_RUNNER_E2E_EXPECTED_IDS: '["core-compatibility.runner-codex.local.message-marker"]'
|
|
PAPERCLIP_E2E_CAMPAIGN_ID: preview-qualification-33901996853
|
|
PAPERCLIP_RUNNER_E2E_SOURCE_SHA: b84964e5a2fa8b1e6498a1ccb471f6adba97d470
|
|
PAPERCLIP_RUNNER_E2E_SOURCE_REF: refs/heads/master
|
|
run: pnpm test:e2e:runner:report
|
|
|
|
- name: Prepare and prove rendered public preview
|
|
run: |
|
|
set -euo pipefail
|
|
pnpm test:e2e:runner:history:prepare -- \
|
|
"$GITHUB_WORKSPACE/private-report" \
|
|
"$GITHUB_WORKSPACE/public-report"
|
|
preview="$(find public-report/evidence -type f -path '*/public-visuals/final-state.png' -print -quit)"
|
|
test -n "$preview"
|
|
dimensions="$(identify -format '%wx%h' "$preview")"
|
|
width="${dimensions%x*}"
|
|
height="${dimensions#*x}"
|
|
test "$width" -le 96
|
|
test "$height" -le 96
|
|
test -z "$(find public-report/evidence -type f -name final-state.png ! -path '*/public-visuals/*' -print -quit)"
|
|
grep -F 'public-visuals/final-state.png' public-report/index.html
|
|
grep -F '<img src=' public-report/index.html
|
|
echo "Representative runner screenshot survived transform and OCR as ${dimensions}, and the generated gallery renders it."
|
|
|
|
- name: Upload sanitized proof only
|
|
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
|
|
with:
|
|
name: runner-e2e-public-preview-qualification-${{ github.run_id }}
|
|
path: public-report/
|
|
retention-days: 1
|
|
if-no-files-found: error
|