Skip to content

Commit

Permalink
Fix benchmark debug action
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewiggins committed Oct 31, 2023
1 parent 30873a3 commit 0189a2c
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 14 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
description: 'Branch or tag ref to check out'
type: string
required: false
default: 'main'
default: ''
artifact_name:
description: 'Name of the artifact to upload'
type: string
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/run-bench.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@ jobs:
with:
name: results
path: benches/results/${{ inputs.benchmark }}.json
- name: Anaylze logs if present
working-directory: benches
run: '[ -d logs ] && npm run analyze || echo "No logs to analyze"'
- name: Tar logs if present
working-directory: benches
run: '[ -d logs ] && tar -zcvf ${{ inputs.benchmark}}_logs.tgz logs || echo "No logs found"'
Expand Down
30 changes: 17 additions & 13 deletions .github/workflows/single-bench.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,15 @@ on:
type: boolean
default: true
required: false
timeout:
description: 'How many minutes to give the benchmark to run before timing out and failing'
type: number
default: 20
required: false
# A bug in GitHub actions prevents us from passing numbers (as either
# number or string type) to called workflows. So disabling this for now.
# See: https://github.com/orgs/community/discussions/67182
#
# timeout:
# description: 'How many minutes to give the benchmark to run before timing out and failing'
# type: number
# default: 20
# required: false

jobs:
build_local:
Expand All @@ -57,17 +61,17 @@ jobs:
with:
name: npm-package
- run: mv preact.tgz preact-local.tgz
- name: Upload locally built preact package
uses: actions/upload-artifact@v3
with:
name: bench-environment
path: preact-local.tgz
- name: Clear working directory
run: |
ls -al
rm -rf *
echo "===================="
ls -al
- name: Upload locally built preact package
uses: actions/upload-artifact@v3
with:
name: bench-environment
path: preact-local.tgz
- name: Download base package
uses: actions/download-artifact@v3
with:
Expand All @@ -80,10 +84,10 @@ jobs:
path: preact-main.tgz

benchmark:
name: Bench ${{ inputs.benchmark}}
name: Bench ${{ inputs.benchmark }}
uses: ./.github/workflows/run-bench.yml
needs: prepare
with:
benchmark: ${{ inputs.benchmark}}
timeout: ${{ inputs.timeout }}
benchmark: ${{ inputs.benchmark }}
trace: ${{ inputs.trace }}
# timeout: ${{ inputs.timeout }}

0 comments on commit 0189a2c

Please sign in to comment.