Skip to content

Commit a29f6af

Browse files
committed
Bencher v0.4.21
1 parent 5910b93 commit a29f6af

8 files changed

+66
-54
lines changed

.github/workflows/base_benchmarks.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,12 @@ jobs:
1616
--token '${{ secrets.BENCHER_API_TOKEN }}' \
1717
--branch main \
1818
--testbed ubuntu-latest \
19-
--adapter json \
19+
--threshold-measure latency \
20+
--threshold-test t_test \
21+
--threshold-max-sample-size 64 \
22+
--threshold-upper-boundary 0.99 \
23+
--thresholds-reset \
2024
--err \
25+
--adapter json \
26+
--github-actions '${{ secrets.GITHUB_TOKEN }}' \
2127
bencher mock
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
on:
2+
pull_request:
3+
types: [closed]
4+
5+
jobs:
6+
archive_fork_pr_branch:
7+
name: Archive closed fork PR branch with Bencher
8+
permissions:
9+
pull-requests: write
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v4
13+
- uses: bencherdev/bencher@main
14+
- name: Archive closed fork PR branch with Bencher
15+
run: |
16+
bencher archive \
17+
--project example \
18+
--token '${{ secrets.BENCHER_API_TOKEN }}' \
19+
--branch '${{ github.head_ref }}'

.github/workflows/run_fork_pr_benchmarks.yml renamed to .github/workflows/fork_pr_benchmarks_run.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Run and Cache Benchmarks
1+
name: Run Benchmarks
22

33
on:
44
pull_request:
@@ -22,4 +22,4 @@ jobs:
2222
uses: actions/upload-artifact@v4
2323
with:
2424
name: event.json
25-
path: ${{ github.event_path }}
25+
path: ${{ github.event_path }}

.github/workflows/track_fork_pr_benchmarks.yml renamed to .github/workflows/fork_pr_benchmarks_track.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: Track Benchmarks with Bencher
22

33
on:
44
workflow_run:
5-
workflows: [Run and Cache Benchmarks]
5+
workflows: [Run Benchmarks]
66
types: [completed]
77

88
jobs:
@@ -40,12 +40,12 @@ jobs:
4040
--project example \
4141
--token '${{ secrets.BENCHER_API_TOKEN }}' \
4242
--branch '${{ env.PR_HEAD }}' \
43-
--branch-start-point '${{ env.PR_BASE }}' \
44-
--branch-start-point-hash '${{ env.PR_BASE_SHA }}' \
45-
--branch-reset \
43+
--start-point '${{ env.PR_BASE }}' \
44+
--start-point-hash '${{ env.PR_BASE_SHA }}' \
45+
--start-point-reset \
4646
--testbed ubuntu-latest \
47-
--adapter json \
4847
--err \
48+
--adapter json \
4949
--github-actions '${{ secrets.GITHUB_TOKEN }}' \
5050
--ci-number '${{ env.PR_NUMBER }}' \
5151
--file "$BENCHMARK_RESULTS"

.github/workflows/pr_benchmarks.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@ jobs:
1919
--project example \
2020
--token '${{ secrets.BENCHER_API_TOKEN }}' \
2121
--branch '${{ github.head_ref }}' \
22-
--branch-start-point '${{ github.base_ref }}' \
23-
--branch-start-point-hash '${{ github.event.pull_request.base.sha }}' \
24-
--branch-reset \
22+
--start-point '${{ github.base_ref }}' \
23+
--start-point-hash '${{ github.event.pull_request.base.sha }}' \
24+
--start-point-reset \
2525
--testbed ubuntu-latest \
26-
--adapter json \
2726
--err \
27+
--adapter json \
2828
--github-actions '${{ secrets.GITHUB_TOKEN }}' \
29-
bencher mock
29+
bencher mock
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
on:
2+
pull_request:
3+
types: [closed]
4+
5+
jobs:
6+
archive_pr_branch:
7+
name: Archive closed PR branch with Bencher
8+
# DO NOT REMOVE: For handling Fork PRs see Pull Requests from Forks
9+
if: github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository
10+
permissions:
11+
pull-requests: write
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v4
15+
- uses: bencherdev/bencher@main
16+
- name: Archive closed PR branch with Bencher
17+
run: |
18+
bencher archive \
19+
--project example \
20+
--token '${{ secrets.BENCHER_API_TOKEN }}' \
21+
--branch '${{ github.head_ref }}'

.github/workflows/pr_target_benchmarks.yml

Lines changed: 0 additions & 36 deletions
This file was deleted.

README.md

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,10 @@
44
The `.github` directory contains example workflows from [how to use Bencher in GitHub Actions](https://bencher.dev/docs/how-to/github-actions/).
55

66
- [Benchmark pushes to `main` branch](.github/workflows/base_benchmarks.yml)
7-
- [Benchmark pull requests from branches](.github/workflows/pr_benchmarks.yml)
8-
- Benchmark fork pull requests and upload from default branch
9-
- [Run benchmarks and cache](.github/workflows/run_fork_pr_benchmarks.yml)
10-
- [Track benchmarks](.github/workflows/track_fork_pr_benchmarks.yml)
11-
- [Benchmark fork pull requests with Required Reviewers](.github/workflows/pr_target_benchmarks.yml)
7+
- Benchmark pull requests
8+
- [Run and track benchmarks](.github/workflows/pr_benchmarks.yml)
9+
- [Archive branches for closed pull requests](.github/workflows/pr_benchmarks_closed.yml)
10+
- Benchmark pull requests from forks
11+
- [Run benchmarks](.github/workflows/fork_pr_benchmarks_run.yml)
12+
- [Track benchmarks](.github/workflows/fork_pr_benchmarks_track.yml)
13+
- [Archive branches for closed pull requests from forks](.github/workflows/fork_pr_benchmarks_closed.yml)

0 commit comments

Comments
 (0)