Skip to content

Commit

Permalink
Devops: fix the nightly build
Browse files Browse the repository at this point in the history
The nightly build against the `develop` branch of `aiida-core` was
failing at the installation of the Python dependencies when running
against Python 3.7. The reason is that the current `develop` branch has
dropped support for Python 3.7 and the `pip` is then failing to install
a version of `pymatgen` that matches the dependency requirements. The
solution is simply to not run against Python 3.7 anymore.

Furthermore, the workflow is updated to match the exact same setup
procedure as the `ci.yml` workflow which has also recently been updated.
The workflow is also renamed to `develop` as that is the name of the
file itself and is a bit more concrete than nightly build, since you can
have many nightly builds of different kinds in principle, but this one
is especially used to test against `aiida-core`'s `develop` branch.
  • Loading branch information
sphuber committed Feb 1, 2022
1 parent e3268c5 commit 506f308
Showing 1 changed file with 7 additions and 22 deletions.
29 changes: 7 additions & 22 deletions .github/workflows/develop.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Nightly Build
name: develop

on:
schedule:
Expand All @@ -9,22 +9,15 @@ jobs:
tests:

if: github.repository == 'aiidateam/aiida-quantumespresso' # Prevent running the builds on forks as well

runs-on: ubuntu-latest

strategy:
matrix:
python-version: [3.7, 3.8, 3.9]
python-version: ['3.8', '3.9']

services:
postgres:
image: postgres:10
env:
POSTGRES_DB: test_${{ matrix.backend }}
POSTGRES_PASSWORD: ''
POSTGRES_HOST_AUTH_METHOD: trust
ports:
- 5432:5432
image: postgres:12
rabbitmq:
image: rabbitmq:latest
ports:
Expand All @@ -33,8 +26,7 @@ jobs:
steps:
- uses: actions/checkout@v2

- name: Cache python dependencies
id: cache-pip
- name: Cache Python dependencies
uses: actions/cache@v1
with:
path: ~/.cache/pip
Expand All @@ -47,25 +39,18 @@ jobs:
with:
python-version: ${{ matrix.python-version }}

- name: Install system dependencies
run: |
sudo apt update
sudo apt install postgresql-12
- name: Install python dependencies
- name: Install Python dependencies
continue-on-error: true
id: install
run: |
pip install --upgrade setuptools
pip install --upgrade pip setuptools wheel
pip install git+https://github.com/aiidateam/aiida-core@develop#egg=aiida-core[atomic_tools]
pip install -e .[tests]
reentry scan
- name: Run pytest
continue-on-error: true
id: tests
run:
pytest -sv tests
run: pytest -sv tests

- name: Slack notification
if: steps.install.outcome == 'Failure' || steps.tests.outcome == 'Failure'
Expand Down

0 comments on commit 506f308

Please sign in to comment.