Files
openfe/.github/workflows/ci.yaml
Alyssa Travitz 2d3af6a058 Release prep v1.6.1 (#1544)
* update partial charge tests now that a production NAGL model is available (#1506)

* update tests now that a production NAGL model is available

* fix mock

* clean up mocking

* add nagl test news item

* debug slow python 3.13 tests (#1468)

* Turn off minimization when we do a dry run
---------

Co-authored-by: IAlibay <IAlibay@users.noreply.github.com>

* update quickrun execution docs and add MPS link (#1483)

* add jq cookbook (#1488)

* add jq code blocks

* use tutorial data

* news

* debug docs build (#1489)

* don't build openmm

* mambaforge->miniconda for rtd

* artifically small build for debugging

* dont build env

* just build python

* add channels

* add sphinx packages to env

* add all non-openfe-ecosystem deps

* remove shim channel

* add openfe package

* add everything except openmm and toolkit

* add openmm

* add openff-toolkit

* only openff-toolkit

* try openff-toolkit-base

* try latest openff

* everybody back in

* build without openmm

* build with openff-toolkit-base

* bump rtd

* add pip build

* remove any openff-toolkit

* build w/o openmm

* add pip install

* build everything without pip install

* try no deps

* try custom build

* only python and pip

* try openfe-toolkit-base

* add temp deps for build with openff-toolkit-base

* add temp deps for build with openff-toolkit-base

* mock imports

* dont mock with toolkit base

* bump toolkit version

* Revert "bump toolkit version"

This reverts commit 6e3108a836.

* add mocks

* try pinnint to toolkit-base 0.13.0, no mocks

* back to >= 0.13.0 toolkit to make sure it wasn't a fluke

* mock imports

* add pipe example for jq (#1505)

* add pipe example for jq

* pin to docutil 0.20

* try to avoid memory error

* debug rtd build memory error (#1510)

* try mambaforge build

* Revert "try mambaforge build"

This reverts commit 683e07f1ea.

* try explicit build

* try removing ambertools

* use the right env

* just add gufe pip install back

* add back openfe eco packages

* mock py3dmol

* add note for pip installs

* fix quote

* temporarily resort to SettingsBaseModel to get build

* specific imports

* dont use base settings placeholder

* temp pin numpy (#1542)

* Removing unnecessary limit on resids (#1539)

* Removing unnecessary limit on resids indices gathering

* Updated CHANGELOG for 1.6.1

* add summary

* update docs theme (#1545)

* adding new branding assets

* remove images

* update theme branch

* CantinaPurple accent

* lowercase convention

* updating text

* remove dark mode for now

* fix sidebars

* fix formatting

* capitalization

* don't break spaces

* bump ci

* favicon!

* whitespace :(

* pin to sphinx release

* pin to gufe 1.6.1

* move env info before test imports

* bump single file installer to 3.12.11 to match colab

---------

Co-authored-by: IAlibay <IAlibay@users.noreply.github.com>
Co-authored-by: Iván Pulido <2949729+ijpulidos@users.noreply.github.com>
2025-10-07 18:41:50 +00:00

134 lines
4.1 KiB
YAML

name: "CI"
on:
pull_request:
branches:
- main
# Skip CI if changed files only affect the following folders
# - docs: documentation changes don't need code validation
# See here for more details: https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#example-excluding-paths
paths-ignore:
- "docs/*"
- ".readthedocs.yaml"
push:
branches:
- main
schedule:
- cron: "0 4 * * *"
workflow_dispatch:
release:
types:
- published
concurrency:
group: "${{ github.workflow }}-${{ github.ref }}"
cancel-in-progress: true
defaults:
run:
shell: bash -leo pipefail {0}
jobs:
tests:
runs-on: ${{ matrix.os }}
name: "💻-${{matrix.os }} 🐍-${{ matrix.python-version }} oechem: ${{ matrix.openeye }}"
strategy:
fail-fast: false
matrix:
os: ["ubuntu-latest", "macos-latest"]
python-version:
- "3.11"
- "3.12"
- "3.13"
openeye: ["no"]
include: # NOTE: openeye does not yet support 3.13.
- os: "ubuntu-latest"
python-version: "3.11"
openeye: "yes"
- os: "macos-latest"
python-version: "3.12"
openeye: "yes"
env:
OE_LICENSE: ${{ github.workspace }}/oe_license.txt
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Get current date
id: date
run: echo "date=$(date +%Y-%m-%d)" >> "${GITHUB_OUTPUT}"
- name: "Setup Micromamba"
uses: mamba-org/setup-micromamba@v2
with:
environment-file: environment.yml
environment-name: openfe_env
cache-environment: true
cache-downloads: true
cache-environment-key: environment-${{ steps.date.outputs.date }}
cache-downloads-key: downloads-${{ steps.date.outputs.date }}
create-args: >-
python=${{ matrix.python-version }}
pydantic=${{ matrix.pydantic-version }}
init-shell: bash
- name: "Install OpenEye"
if: ${{ !github.event.pull_request.head.repo.fork
&& matrix.openeye == 'yes' }}
env:
OE_LICENSE_TEXT: ${{ secrets.OE_LICENSE }}
run: |
echo "${OE_LICENSE_TEXT}" > ${OE_LICENSE}
micromamba install -c openeye openeye-toolkits
python -c "import openeye; assert openeye.oechem.OEChemIsLicensed(), 'oechem license check failed!'"
- name: "Install"
run: python -m pip install --no-deps -e .
- name: "Environment Information"
run: |
micromamba info
micromamba list
pip list
- name: "Test imports"
run: |
# if we add more to this, consider changing to for + env vars
python -Ic "import openfe; print(openfe.__version__)"
- name: "Run tests"
env:
# Set the OFE_SLOW_TESTS to True if running a Cron job
OFE_SLOW_TESTS: ${{ fromJSON('{"false":"false","true":"true"}')[github.event_name != 'pull_request'] }}
DUECREDIT_ENABLE: 'yes'
run: |
pytest -n auto -v --cov=openfe --cov=openfecli --cov-report=xml --durations=10
- name: codecov-pr
if: ${{ github.repository == 'OpenFreeEnergy/openfe'
&& github.event_name == 'pull_request' }}
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: coverage.xml
fail_ci_if_error: False
verbose: True
flags: fast-tests
- name: codecov-merge
# we only want to upload a slow report if
# 1) it isn't a schedule run
# 2) it wasn't from a PR (we don't run slow tests on PRs)
if: ${{ github.repository == 'OpenFreeEnergy/openfe'
&& github.event_name != 'schedule'
&& github.event_name != 'pull_request' }}
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: coverage.xml
fail_ci_if_error: False
verbose: True
flags: slow-tests