diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..ae992e3 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,7 @@ +version: 2 +updates: + + - package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: "daily" diff --git a/.github/workflows/CI.yaml b/.github/workflows/CI.yaml index e6b1de2..6bbc7d4 100644 --- a/.github/workflows/CI.yaml +++ b/.github/workflows/CI.yaml @@ -1,23 +1,19 @@ name: CI on: - # GitHub has started calling new repo's first branch "main" https://github.com/github/renaming - # Existing codes likely still have "master" as the primary branch - # Both are tracked here to keep legacy and new codes working push: branches: - - "master" - "main" pull_request: branches: - - "master" - "main" schedule: - # Nightly tests run on master by default: - # Scheduled workflows run on the latest commit on the default or base branch. - # (from https://help.github.com/en/actions/reference/events-that-trigger-workflows#scheduled-events-schedule) - cron: "0 0 * * *" +defaults: + run: + shell: bash -leo pipefail {0} + jobs: test: name: Test on ${{ matrix.os }}, Python ${{ matrix.python-version }} @@ -25,51 +21,31 @@ jobs: strategy: matrix: os: [macOS-latest, ubuntu-latest, windows-latest] - python-version: [3.7, 3.8, 3.9] + python-version: ["3.10", "3.11"] steps: - uses: actions/checkout@v1 - - name: Additional info about the build - shell: bash - run: | - uname -a - df -h - ulimit -a - - - # More info on options: https://github.com/conda-incubator/setup-miniconda - - uses: conda-incubator/setup-miniconda@v2 + - name: Set up conda environment with micromamba + uses: mamba-org/setup-micromamba@v1 with: - python-version: ${{ matrix.python-version }} - environment-file: devtools/conda-envs/test_env.yaml - - channels: conda-forge,defaults - - activate-environment: test - auto-update-conda: false - auto-activate-base: false - show-channel-urls: true + micromamba-binary-path: ~/.local/bin/micromamba + environment-file: devtools/conda-envs/proteinbenchmark.yaml + create-args: >- + python=${{ matrix.python-version }} - name: Install package - - # conda setup requires this special shell - shell: bash -l {0} run: | python -m pip install . --no-deps - conda list - + micromamba list - name: Run tests - - # conda setup requires this special shell - shell: bash -l {0} - run: | - pytest -v --cov=proteinbenchmark --cov-report=xml --color=yes proteinbenchmark/tests/ + python -m pytest -v proteinbenchmark/tests/ \ + --cov=proteinbenchmark --cov-report=xml --color=yes - name: CodeCov - uses: codecov/codecov-action@v1 + uses: codecov/codecov-action@v4 with: file: ./coverage.xml flags: unittests diff --git a/devtools/conda-envs/proteinbenchmark.yaml b/devtools/conda-envs/proteinbenchmark.yaml index c80a1db..6431363 100644 --- a/devtools/conda-envs/proteinbenchmark.yaml +++ b/devtools/conda-envs/proteinbenchmark.yaml @@ -2,11 +2,7 @@ name: openff-proteinbenchmark channels: - conda-forge - openeye - - defaults dependencies: - - black - - click - - isort - pip - python @@ -17,8 +13,7 @@ dependencies: # MM calculations - ambertools - - cudatoolkit - - openeye-toolkits=2022.1.1 + - openeye-toolkits - openff-forcefields - openff-toolkit>=0.13.0 - openff-units @@ -27,7 +22,7 @@ dependencies: - openmmtools # Analysis - - loos + - loos ==4.1 - pandas - pymol-open-source - seaborn diff --git a/devtools/conda-envs/test_env.yaml b/devtools/conda-envs/test_env.yaml deleted file mode 100644 index c79a37b..0000000 --- a/devtools/conda-envs/test_env.yaml +++ /dev/null @@ -1,20 +0,0 @@ -name: test -channels: - - - conda-forge - - - defaults -dependencies: - # Base depends - - python - - pip - - # Testing - - pytest - - pytest-cov - - codecov - - # Pip-only installs - #- pip: - # - codecov -