Skip to content

Commit

Permalink
chore: switch benchmark results branch
Browse files Browse the repository at this point in the history
`gh-pages` -> `benchmark-results`
  • Loading branch information
jonathanpwang committed Dec 14, 2024
1 parent 6b87714 commit cd9c4fd
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 13 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/benchmark-call.yml
Original file line number Diff line number Diff line change
Expand Up @@ -261,11 +261,11 @@ jobs:
fi
##########################################################################
# Update gh-pages with individual results #
# Update benchmark-results with individual results #
##########################################################################
- uses: actions/checkout@v4
with:
ref: gh-pages
ref: benchmark-results

- name: Set up git
run: |
Expand Down Expand Up @@ -304,9 +304,9 @@ jobs:
while [ $ATTEMPT -lt $MAX_RETRIES ]; do
echo "Attempt $((ATTEMPT + 1)) to push of $MAX_RETRIES..."
git fetch origin gh-pages
git merge origin/gh-pages --no-edit
if git push origin gh-pages; then
git fetch origin benchmark-results
git merge origin/benchmark-results --no-edit
if git push origin benchmark-results; then
SUCCESS=true
break
else
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/benchmarks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ jobs:
python3 ci/scripts/metric_unify/summarize.py "${md_file_list}" \
--e2e-md-files "${E2E_FILE_LIST}" \
--aggregation-json ci/scripts/metric_unify/aggregation.json \
--gh-pages-link "https://github.com/${{ github.repository }}/blob/gh-pages/${GH_PAGES_PATH}"
--benchmark-results-link "https://github.com/${{ github.repository }}/blob/benchmark-results/${GH_PAGES_PATH}"
echo "" >> summary.md
echo "Commit: https://github.com/${{ github.repository }}/commit/${CURRENT_SHA}" >> summary.md
Expand All @@ -199,12 +199,12 @@ jobs:
cp summary.md /tmp/benchmark-results/
##########################################################################
# Update gh-pages with summary upon a PR event #
# Update benchmark-results with summary upon a PR event #
##########################################################################
- uses: actions/checkout@v4
if: github.event_name == 'pull_request' || (github.event_name == 'push' && github.ref == 'refs/heads/main')
with:
ref: gh-pages
ref: benchmark-results

- name: Set up git
if: github.event_name == 'pull_request' || (github.event_name == 'push' && github.ref == 'refs/heads/main')
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,5 +45,5 @@ The flamegraphs will be written to `*.svg` files in `.bench_metrics/flamegraphs`

### Latest Benchmark Results

Latest benchmark results can be found [here](https://github.com/axiom-crypto/afs-prototype/blob/gh-pages/index.md).
Latest benchmark results can be found [here](https://github.com/axiom-crypto/afs-prototype/blob/benchmark-results/index.md).
These are run via [github workflows](./.github/workflows/benchmark-call.yml) and should always be up to date with the latest `main` branch.
2 changes: 1 addition & 1 deletion ci/scripts/metric_unify/summarize.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ def main():
argparser.add_argument('metrics_md_files', type=str, help="Comma separated list of metrics markdown file names")
argparser.add_argument('--e2e-md-files', type=str, required=False, help="Comma separated list of e2e metrics markdown file names")
argparser.add_argument('--aggregation-json', type=str, required=True, help="Path to a JSON file with metrics to aggregate")
argparser.add_argument('--gh-pages-link', type=str, required=True, help="Link to this PR's gh-pages directory")
argparser.add_argument('--benchmark-results-link', type=str, required=True, help="Link to this PR's benchmark-results directory")
args = argparser.parse_args()

aggregations = read_aggregations(args.aggregation_json)
Expand Down
6 changes: 3 additions & 3 deletions ci/scripts/utils.sh
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,9 @@ commit_and_push_gh_pages() {

while [ $ATTEMPT -lt $MAX_RETRIES ]; do
echo "Attempt $((ATTEMPT + 1)) to push of $MAX_RETRIES..."
git fetch origin gh-pages
git merge origin/gh-pages --no-edit
if git push origin gh-pages; then
git fetch origin benchmark-results
git merge origin/benchmark-results --no-edit
if git push origin benchmark-results; then
SUCCESS=true
break
else
Expand Down

0 comments on commit cd9c4fd

Please sign in to comment.