Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add conda canary CI job #903

Merged
merged 18 commits into from
Aug 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ jobs:
- name: codecov-pr
if: ${{ github.repository == 'OpenFreeEnergy/openfe'
&& github.event_name == 'pull_request' }}
uses: codecov/codecov-action@v3
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: coverage.xml
Expand All @@ -137,7 +137,7 @@ jobs:
if: ${{ github.repository == 'OpenFreeEnergy/openfe'
&& github.event_name != 'schedule'
&& github.event_name != 'pull_request' }}
uses: codecov/codecov-action@v3
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: coverage.xml
Expand Down
67 changes: 67 additions & 0 deletions .github/workflows/conda_cron.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
name: "conda_cron"
on:
workflow_dispatch:
schedule:
# At 07:00 UTC every day
- cron: "0 7 * * *"

concurrency:
group: "${{ github.workflow }}-${{ github.ref }}"
cancel-in-progress: true

defaults:
run:
shell: bash -leo pipefail {0}

jobs:
condacheck:
runs-on: ${{ matrix.OS }}
name: "daily conda check"
strategy:
fail-fast: false
matrix:
os: ['ubuntu-latest', 'macos-latest', 'macos-12']
python-version:
- "3.9"
- "3.10"
- "3.11"
- "3.12"
exclude:
- os: 'macos-latest'
python-version: '3.9'

steps:
- name: Setup Micromamba
uses: mamba-org/setup-micromamba@v1
with:
environment-name: openfe
create-args: >-
python=${{ matrix.python-version }}
pip
jq
condarc: |
channels:
- jaimergp/label/unsupported-cudatoolkit-shim
- conda-forge
init-shell: bash

- name: "Install openfe + optional deps"
run: |
# get latest version from conda-forge
LATEST_VERSION=$(micromamba search --json openfe | jq '.result.pkgs[0].version')
echo "LATEST_VERSION: $LATEST_VERSION"
# Removing the quotes from the vesrion number
# https://mywiki.wooledge.org/BashGuide/Parameters#Parameter_Expansion
micromamba install openfe=${LATEST_VERSION//\"} pytest -c conda-forge
python -m pip install pytest-xdist

- name: "env info"
run: |
micromamba info
micromamba list
pip list
- id: run-tests
name: "Run tests"
run: |
# note: this only runs the fast tests
pytest -n auto --pyargs openfe openfecli
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm relying on a normal failure here rather than raising the issue as we do with gufe. The plan will be to hook up Swenson's cron job checker tool.

Loading