[Infra] Update performance tests. #60
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: performance | |
on: | |
release: | |
types: [ published ] | |
pull_request: | |
branches: [ main ] | |
workflow_dispatch: | |
concurrency: | |
group: "workflow = ${{ github.workflow }}, ref = ${{ github.event.ref }}, pr = ${{ github.event.pull_request.id }}" | |
cancel-in-progress: ${{ github.event_name == 'pull_request' || github.repository != 'alibaba/code-data-share-for-python' }} | |
jobs: | |
perf-import: | |
if: false | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
python: [ '3.8', '3.9', '3.10', '3.11', '3.12' ] | |
os: [ ubuntu-latest, macOS-latest, windows-latest ] | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: s-weigand/setup-conda@v1 | |
with: | |
conda-channels: conda-forge | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
python -m pip install nox | |
- name: Perf importing third-party packages | |
continue-on-error: true | |
env: | |
RUN: LONG | |
run: | | |
nox -s test_import_third_party_perf-${{ matrix.python }} | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: perf-import | |
path: "*.json" | |
perf-import-result: | |
runs-on: ubuntu-latest | |
needs: [ perf-import ] | |
steps: | |
- uses: actions/setup-python@v4 | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
python -m pip install pyperf | |
- name: Download artifact | |
uses: actions/download-artifact@v3 | |
with: | |
name: perf-import | |
path: ./ | |
- name: Result | |
run: | | |
for VERSION in 3.8 3.9 3.10 3.11 3.12 | |
do | |
for OS in linux darwin windows | |
do | |
pyperf compare_to perf-import-$VERSION-$OS-raw.json perf-import-$VERSION-$OS-cds.json --table | tee perf-import-$VERSION-$OS.table | |
done | |
done | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: perf-import | |
path: "*.table" | |
pyperformance: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
python: [ '3.8', '3.9', '3.10', '3.11', '3.12' ] | |
os: [ ubuntu-latest, macOS-latest, windows-latest ] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python ${{ matrix.python }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python }} | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
python -m pip install nox | |
- name: Pyperformance tests against cds | |
continue-on-error: true | |
env: | |
RUN: LONG | |
run: | | |
nox -s pyperformance | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: pyperformance | |
path: "*.json" |