From fc570d0e58f7e09efa0cb05d1541d3805afd0952 Mon Sep 17 00:00:00 2001 From: Peter Steinberger Date: Sun, 3 May 2026 14:06:18 +0100 Subject: [PATCH] ci: use current performance report helpers --- .github/workflows/openclaw-performance.yml | 32 ++++++++++++++++++++-- 1 file changed, 30 insertions(+), 2 deletions(-) diff --git a/.github/workflows/openclaw-performance.yml b/.github/workflows/openclaw-performance.yml index a83082b989d..aa6d66e5613 100644 --- a/.github/workflows/openclaw-performance.yml +++ b/.github/workflows/openclaw-performance.yml @@ -92,6 +92,7 @@ jobs: env: KOVA_REF: ${{ inputs.kova_ref || 'b63b6f9e20efb23641df00487e982230d81a90ac' }} KOVA_HOME: ${{ github.workspace }}/.artifacts/kova/home/${{ matrix.lane }} + PERFORMANCE_HELPER_DIR: ${{ github.workspace }}/.artifacts/performance-workflow REPORT_DIR: ${{ github.workspace }}/.artifacts/kova/reports/${{ matrix.lane }} BUNDLE_DIR: ${{ github.workspace }}/.artifacts/kova/bundles/${{ matrix.lane }} SUMMARY_DIR: ${{ github.workspace }}/.artifacts/kova/summaries @@ -149,6 +150,15 @@ jobs: fetch-depth: 1 persist-credentials: false + - name: Checkout performance workflow helpers + if: steps.lane.outputs.run == 'true' + uses: actions/checkout@v6 + with: + ref: ${{ github.sha }} + path: .artifacts/performance-workflow + fetch-depth: 1 + persist-credentials: false + - name: Record tested revision if: steps.lane.outputs.run == 'true' shell: bash @@ -310,7 +320,7 @@ jobs: report_url="https://github.com/openclaw/clawgrit-reports/tree/main/openclaw-performance/${ref_slug}/${run_slug}/${LANE_ID}" fi summary_path="$SUMMARY_DIR/${LANE_ID}.md" - summary_args=(node scripts/kova-ci-summary.mjs --report "$report_json" --output "$summary_path" --lane "$LANE_ID") + summary_args=(node "$PERFORMANCE_HELPER_DIR/scripts/kova-ci-summary.mjs" --report "$report_json" --output "$summary_path" --lane "$LANE_ID") if [[ -n "$report_url" ]]; then summary_args+=(--report-url "$report_url") fi @@ -349,6 +359,24 @@ jobs: fi mkdir -p "$SOURCE_PERF_DIR/mock-hello" + if ! node -e "const fs=require('node:fs'); const scripts=require('./package.json').scripts||{}; process.exit(scripts['test:gateway:cpu-scenarios'] && scripts.openclaw && fs.existsSync('scripts/bench-cli-startup.ts') ? 0 : 1)"; then + cat > "$SOURCE_PERF_DIR/index.md" <> "$GITHUB_STEP_SUMMARY" + exit 0 + fi + pnpm build pnpm test:gateway:cpu-scenarios \ @@ -432,7 +460,7 @@ jobs: cleanup_gateway trap - EXIT - pnpm perf:source:summary \ + node "$PERFORMANCE_HELPER_DIR/scripts/openclaw-performance-source-summary.mjs" \ --source-dir "$SOURCE_PERF_DIR" \ --output "$SOURCE_PERF_DIR/index.md"