14
14
jobs :
15
15
16
16
first_check :
17
- name : first code check / python-3.8 / ubuntu-latest
17
+ name : first code check / python-3.10 / ubuntu-latest
18
18
runs-on : ubuntu-latest
19
19
steps :
20
20
- uses : actions/checkout@v4
21
- - name : Set up Python 3.9
21
+ - name : Set up Python 3.10
22
22
uses : actions/setup-python@v5
23
23
with :
24
- python-version : 3.9
24
+ python-version : ' 3.10 '
25
25
- name : Python info
26
26
run : |
27
27
which python
28
28
python --version
29
29
- name : Build package and create dev environment
30
30
run : |
31
- python -m pip install --upgrade pip
32
- pip install -e .[dev]
31
+ python -m pip install --upgrade pip poetry
32
+ poetry lock
33
+ poetry install --with dev
33
34
- name : Show pip list
34
35
run : |
35
36
pip list
36
37
- name : Test with coverage
37
38
run : |
38
- pytest --cov --cov-report term --cov-report xml --junitxml=xunit-result.xml
39
+ poetry run pytest --cov --cov-report term --cov-report xml --junitxml=xunit-result.xml
39
40
- name : Correct coverage paths
40
41
run : sed -i "s+$PWD/++g" coverage.xml
41
42
- name : Check style against standards using prospector
42
43
shell : bash -l {0}
43
- run : prospector -o grouped -o pylint:pylint-report.txt
44
+ run : poetry run prospector -o grouped -o pylint:pylint-report.txt
44
45
- name : Check whether import statements are used consistently
45
- run : isort . --check-only --diff
46
+ run : poetry run isort . --check-only --diff
46
47
47
48
build_pypi :
48
49
name : Test pypi build
49
50
runs-on : ubuntu-latest
50
51
needs : first_check
51
52
steps :
52
53
- uses : actions/checkout@v4
53
- - name : Set up Python 3.9
54
+ - name : Set up Python 3.10
54
55
uses : actions/setup-python@v5
55
56
with :
56
- python-version : 3.9
57
+ python-version : ' 3.10 '
57
58
- name : Python info
58
59
run : |
59
60
which python
60
61
python --version
61
62
- name : Install dependencies
62
63
run : |
63
- python -m pip install --upgrade pip
64
+ python -m pip install --upgrade pip poetry twine
64
65
- name : Build package
65
66
run : |
66
- pip install wheel twine
67
- python setup.py sdist bdist_wheel
67
+ poetry build
68
68
- name : Test package
69
69
run : |
70
+ poetry lock
71
+ poetry install --only dev
70
72
python -m twine check dist/*
71
73
- name : Show pip list
72
74
run : |
73
75
pip list
74
76
- name : Install development dependencies
75
77
run : |
76
- pip install -e .[dev]
78
+ poetry lock
79
+ poetry install
77
80
- name : Show pip list again
78
81
run : |
79
82
pip list
80
83
- name : Run tests
81
84
run : |
82
- pytest
85
+ poetry run pytest
83
86
- name : Show environment variables
84
87
shell : bash -l {0}
85
88
run : |
@@ -93,48 +96,25 @@ jobs:
93
96
fail-fast : false
94
97
matrix :
95
98
os : ['ubuntu-latest', 'macos-latest', 'windows-latest']
96
- python-version : ['3.8', '3.9', '3.10', '3.11']
97
- exclude :
98
- - os : ubuntu-latest
99
- python-version : 3.9
99
+ python-version : ['3.10', '3.11', '3.12']
100
100
steps :
101
- - uses : actions/checkout@v2
102
- with :
103
- fetch-depth : " 0"
104
- - name : Create conda environment
105
- uses : conda-incubator/setup-miniconda@v3
101
+ - uses : actions/checkout@v4
102
+ - name : Set up Python
103
+ uses : actions/setup-python@v5
106
104
with :
107
- auto-update-conda : true
108
105
python-version : ${{ matrix.python-version }}
109
- - name : Show conda config
110
- shell : bash -l {0}
111
- run : |
112
- conda info
113
- conda list
114
- conda config --show-sources
115
- conda config --show
116
- conda env list
117
106
- name : Python info
118
- shell : bash -l {0}
119
107
run : |
120
108
which python
121
109
python --version
122
- - name : Show environment variables
123
- shell : bash -l {0}
124
- run : |
125
- env | sort
126
- - name : Install conda dependencies
127
- shell : bash -l {0}
110
+ - name : Install dependencies (includinv dev + chemistry)
128
111
run : |
129
- conda install -c conda-forge rdkit
130
- - name : Install dev dependencies
131
- shell : bash -l {0}
132
- run : |
133
- python -m pip install --upgrade pip
134
- pip install -e .[dev]
112
+ python -m pip install --upgrade pip poetry
113
+ poetry lock
114
+ poetry install
135
115
- name : Show pip list
136
- shell : bash -l {0}
137
- run : pip list
116
+ run : |
117
+ pip list
138
118
- name : Run tests
139
- shell : bash -l {0}
140
- run : pytest
119
+ run : |
120
+ poetry run pytest
0 commit comments