Skip to content

Commit

Permalink
debug CI
Browse files Browse the repository at this point in the history
  • Loading branch information
tztsai committed Dec 4, 2023
1 parent abe7557 commit ca4bbca
Showing 1 changed file with 8 additions and 9 deletions.
17 changes: 8 additions & 9 deletions .github/workflows/pyrealm_ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
steps:
- uses: actions/checkout@v3
with:
lfs: true
ref: ${{ github.head_ref }}

- uses: actions/setup-python@v4
with:
Expand All @@ -42,23 +42,22 @@ jobs:
# run: poetry run pytest -m "not profiling" --cov-report xml

- name: Run profiling
if: matrix.os == 'ubuntu-latest' && matrix.python-version == 3.9
# && github.ref == 'refs/heads/main'
id: profiling
if: matrix.os == 'ubuntu-latest' && matrix.python-version == 3.9 # && github.ref == 'refs/heads/main'
run: |
git lfs pull
git update-index --assume-unchanged pyrealm_build_data/*.nc
poetry run pytest -m "profiling" --profile-svg
# mv prof/combined.svg profiling/profiling.svg
mv prof/combined.prof profiling/profiling.prof
# mv prof/combined.svg profiling/profiling.svg
poetry run python profiling/report.py
echo "REPORT=1" >> $GITHUB_ENV
rm pyrealm_build_data/*.nc
- name: Generate report
if: env.REPORT == 1
uses: stefanzweifel/git-auto-commit-action@v5
if: steps.profiling.outcome == 'success'
with:
commit_message: Automated report
file_pattern: '*.csv *.png *.svg'
file_pattern: 'profiling/*'
commit_message: Auto-generated report

- name: Upload coverage reports to Codecov
if: success() && (matrix.os == 'ubuntu-latest' && matrix.python-version == 3.9)
Expand Down

0 comments on commit ca4bbca

Please sign in to comment.