Skip to content

Update dependency sphinx-autobuild to v2024.9.19 (#590) #101

Update dependency sphinx-autobuild to v2024.9.19 (#590)

Update dependency sphinx-autobuild to v2024.9.19 (#590) #101

Workflow file for this run

name: Benchmark
on:
push:
branches:
- main
workflow_dispatch:
permissions:
contents: read
jobs:
benchmark:
name: Check performance regeression.
runs-on: ubuntu-latest
permissions:
# deployments permission to deploy GitHub pages website
deployments: write
# contents permission to update benchmark contents in gh-pages branch
contents: write
steps:
- name: Harden Runner
uses: step-security/harden-runner@91182cccc01eb5e619899d80e4e971d6181294a7 # v2.10.1
with:
disable-sudo: true
egress-policy: audit
disable-telemetry: false
allowed-endpoints: >
files.pythonhosted.org:443
github.com:443
pypi.org:443
api.github.com:443
- name: Checkout main branch
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
with:
clean: true
- name: Setup Python
uses: actions/setup-python@f677139bbe7f9c59b41e40162b753c062f5d49a3 # v5
with:
python-version: "3.11"
# This is a hack until pipx fixes the absolute path bug
# present in 1.5.0
# See also https://github.com/pypa/pipx/issues/1331
# Hopefully the next release in Sprint 2024 will resolve this and
# pipx will be able to find the constraints file again
- name: Upgrade pipx
run: |
pip install pipx==1.4.3
python -m pipx ensurepath
pipx --version
# End of pipx hack
- name: Upgrade pip
run: |
pip install --constraint=.github/workflows/constraints.txt pip
pip --version
- name: Upgrade pip in virtual environments
shell: python
run: |
import os
import pip
with open(os.environ["GITHUB_ENV"], mode="a") as io:
print(f"VIRTUALENV_PIP={pip.__version__}", file=io)
- name: Install Poetry
run: |
pipx install --pip-args=--constraint=.github/workflows/constraints.txt poetry
poetry --version
- name: Install Nox
run: |
pipx install --pip-args=--constraint=.github/workflows/constraints.txt nox
pipx inject --pip-args=--constraint=.github/workflows/constraints.txt nox nox-poetry poetry-plugin-export
nox --version
- name: Run benchmark with nox
run: nox -s benchmark
- name: Store benchmark result in github.io
uses: benchmark-action/github-action-benchmark@4de1bed97a47495fc4c5404952da0499e31f5c29 # tag=v1
with:
name: Pytest-Benchmark Benchmark
tool: "pytest"
output-file-path: benchmark-output.json
github-token: ${{ secrets.PERSONAL_GITHUB_TOKEN }}
auto-push: true
alert-threshold: "130%"
comment-on-alert: true
fail-on-alert: true