Skip to content
This repository was archived by the owner on Jan 26, 2023. It is now read-only.

Commit 08ab082

Browse files
authored
Merge pull request #153 from randomir/support-py39
Support py39
2 parents a406a79 + 4f857e8 commit 08ab082

File tree

4 files changed

+76
-67
lines changed

4 files changed

+76
-67
lines changed

.appveyor.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ environment:
1414
- PYTHON: "C:\\Python37-x64"
1515
- PYTHON: "C:\\Python38"
1616
- PYTHON: "C:\\Python38-x64"
17+
- PYTHON: "C:\\Python39"
18+
- PYTHON: "C:\\Python39-x64"
1719

1820
install:
1921
# required to link py35 (x86 and x64)

.circleci/config.yml

Lines changed: 72 additions & 66 deletions
Original file line numberDiff line numberDiff line change
@@ -1,44 +1,44 @@
11
version: 2
22
jobs:
3-
test-3.6: &full-test-template
3+
test-3.9: &full-test-template
44
docker:
5-
- image: circleci/python:3.6-jessie
5+
- image: circleci/python:3.9
66

77
working_directory: ~/repo
88

99
steps:
1010

1111
- checkout
1212

13-
- restore_cache:
13+
- restore_cache: &restore-cache-env
1414
keys:
15-
- v1-dependencies-{{ checksum "requirements.txt" }}-{{ checksum "tests/requirements.txt" }}-{{ .Environment.CIRCLE_JOB }}
15+
- v2-dependencies-{{ checksum "requirements.txt" }}-{{ checksum "tests/requirements.txt" }}-{{ .Environment.CIRCLE_JOB }}
1616

1717
- run:
1818
name: create virtualenv
1919
command: |
2020
python -m virtualenv env
2121
22-
- run: &install-dependencies-template
22+
- run: &install-dependencies
2323
name: install dependencies
2424
command: |
2525
. env/bin/activate
2626
python --version
2727
pip install -r requirements.txt -r tests/requirements.txt
2828
29-
- save_cache:
29+
- save_cache: &save-cache-env
3030
paths:
3131
- ./env
32-
key: v1-dependencies-{{ checksum "requirements.txt" }}-{{ checksum "tests/requirements.txt" }}-{{ .Environment.CIRCLE_JOB }}
32+
key: v2-dependencies-{{ checksum "requirements.txt" }}-{{ checksum "tests/requirements.txt" }}-{{ .Environment.CIRCLE_JOB }}
3333

34-
- run: &install-package-template
34+
- run: &install-package
3535
name: install package
3636
command: |
3737
. env/bin/activate
3838
python setup.py build_ext --inplace
3939
pip install .
4040
41-
- run: &run-tests-template
41+
- run: &run-tests
4242
name: run unittests
4343
command: |
4444
. env/bin/activate
@@ -57,23 +57,28 @@ jobs:
5757
test-3.8:
5858
<<: *full-test-template
5959
docker:
60-
- image: circleci/python:3.8-buster
60+
- image: circleci/python:3.8
6161

6262
test-3.7:
6363
<<: *full-test-template
6464
docker:
65-
- image: circleci/python:3.7-stretch
65+
- image: circleci/python:3.7
66+
67+
test-3.6:
68+
<<: *full-test-template
69+
docker:
70+
- image: circleci/python:3.6
6671

6772
test-3.5:
6873
<<: *full-test-template
6974
docker:
70-
- image: circleci/python:3.5-jessie
75+
- image: circleci/python:3.5
7176

72-
test-osx-3.8: &osx-tests-template
77+
test-osx-3.9: &osx-tests-template
7378
macos:
74-
xcode: "11.2.1"
79+
xcode: "12.2.0"
7580
environment:
76-
PYTHON: 3.8.0
81+
PYTHON: 3.9.0
7782
HOMEBREW_NO_AUTO_UPDATE: 1
7883

7984
# Force (lie about) macOS 10.9 binary compatibility.
@@ -91,66 +96,63 @@ jobs:
9196
command: |
9297
brew install pyenv
9398
94-
- restore_cache:
99+
- restore_cache: &restore-cache-pyenv
95100
keys:
96-
- pyenv-{{ .Environment.CIRCLE_JOB }}-xcode11.2.1
101+
- v2-pyenv-{{ .Environment.CIRCLE_JOB }}-xcode-12.2.0
97102

98103
- run:
99104
name: install python
100105
command: |
101106
pyenv install $PYTHON -s
102107
103-
- save_cache:
108+
- save_cache: &save-cache-pyenv
104109
paths:
105110
- ~/.pyenv
106-
key: pyenv-{{ .Environment.CIRCLE_JOB }}-xcode11.2.1
111+
key: v2-pyenv-{{ .Environment.CIRCLE_JOB }}-xcode-12.2.0
107112

108-
- run:
113+
- run: &create-virtualenv-pyenv
109114
name: create virtualenv
110115
command: |
111116
eval "$(pyenv init -)"
112117
pyenv local $PYTHON
113118
python -m pip install virtualenv
114119
python -m virtualenv env
115120
116-
- restore_cache:
117-
keys:
118-
- v1-dependencies-{{ checksum "requirements.txt" }}-{{ checksum "tests/requirements.txt" }}-{{ .Environment.CIRCLE_JOB }}
121+
- restore_cache: *restore-cache-env
119122

120-
- run: &install-dependencies-template
121-
name: install dependencies
122-
command: |
123-
. env/bin/activate
124-
python --version
125-
pip install -r requirements.txt -r tests/requirements.txt
123+
- run: *install-dependencies
126124

127-
- save_cache:
128-
paths:
129-
- ./env
130-
key: v1-dependencies-{{ checksum "requirements.txt" }}-{{ checksum "tests/requirements.txt" }}-{{ .Environment.CIRCLE_JOB }}
125+
- save_cache: *save-cache-env
131126

132-
- run: *install-package-template
127+
- run: *install-package
133128

134-
- run: *run-tests-template
129+
- run: *run-tests
130+
131+
test-osx-3.8:
132+
<<: *osx-tests-template
133+
environment:
134+
PYTHON: 3.8.6
135+
HOMEBREW_NO_AUTO_UPDATE: 1
136+
MACOSX_DEPLOYMENT_TARGET: 10.9
135137

136138
test-osx-3.7:
137139
<<: *osx-tests-template
138140
environment:
139-
PYTHON: 3.7.4
141+
PYTHON: 3.7.9
140142
HOMEBREW_NO_AUTO_UPDATE: 1
141143
MACOSX_DEPLOYMENT_TARGET: 10.9
142144

143145
test-osx-3.6:
144146
<<: *osx-tests-template
145147
environment:
146-
PYTHON: 3.6.5
148+
PYTHON: 3.6.12
147149
HOMEBREW_NO_AUTO_UPDATE: 1
148150
MACOSX_DEPLOYMENT_TARGET: 10.9
149151

150152
test-osx-3.5:
151153
<<: *osx-tests-template
152154
environment:
153-
PYTHON: 3.5.5
155+
PYTHON: 3.5.10
154156
HOMEBREW_NO_AUTO_UPDATE: 1
155157
MACOSX_DEPLOYMENT_TARGET: 10.9
156158

@@ -171,7 +173,7 @@ jobs:
171173
name: build wheels
172174
command: |
173175
for PYBIN in /opt/python/*/bin; do
174-
"${PYBIN}/python" -c "import sys; sys.exit((3,5)<=sys.version_info<(3,9))" && continue
176+
"${PYBIN}/python" -c "import sys; sys.exit((3,5)<=sys.version_info<(3,10))" && continue
175177
"${PYBIN}/pip" install -r requirements.txt -r tests/requirements.txt
176178
"${PYBIN}/pip" wheel . -w ./wheelhouse
177179
"${PYBIN}/python" setup.py sdist -d ./dist
@@ -187,13 +189,6 @@ jobs:
187189
- store_artifacts:
188190
path: ./dist
189191

190-
- run: &init-pypirc-template
191-
name: init .pypirc
192-
command: |
193-
echo -e "[pypi]" >> ~/.pypirc
194-
echo -e "username = $PYPI_USERNAME" >> ~/.pypirc
195-
echo -e "password = $PYPI_PASSWORD" >> ~/.pypirc
196-
197192
- run:
198193
name: create a virtualenv
199194
command: |
@@ -202,23 +197,23 @@ jobs:
202197
"$python/pip" install virtualenv
203198
"$python/python" -m virtualenv env
204199
205-
- run: &upload-template
200+
- run: &upload-pypi
206201
name: install twine and deploy
207202
command: |
208203
. env/bin/activate
209-
python -m pip install twine
210-
twine upload --skip-existing ./dist/*
204+
pip install twine
205+
twine upload -u "$PYPI_USERNAME" -p "$PYPI_PASSWORD" --skip-existing ./dist/*
211206
212207
build-manylinux-32:
213208
<<: *manylinux-template
214209
docker:
215210
- image: quay.io/pypa/manylinux1_i686
216211

217-
build-osx-3.8: &osx-build-template
212+
build-osx-3.9: &osx-build-template
218213
macos:
219-
xcode: "11.2.0"
214+
xcode: "12.2.0"
220215
environment:
221-
PYTHON: 3.8.0
216+
PYTHON: 3.9.0
222217
HOMEBREW_NO_AUTO_UPDATE: 1
223218
MACOSX_DEPLOYMENT_TARGET: 10.9
224219

@@ -232,22 +227,20 @@ jobs:
232227
command: |
233228
brew install pyenv
234229
230+
- restore_cache: *restore-cache-pyenv
231+
235232
- run:
236233
name: install python
237234
command: |
238235
pyenv install $PYTHON -s
239236
240-
- run:
241-
name: create virtualenv
242-
command: |
243-
eval "$(pyenv init -)"
244-
pyenv local $PYTHON
245-
python -m pip install virtualenv
246-
python -m virtualenv env
237+
- save_cache: *save-cache-pyenv
238+
239+
- run: *create-virtualenv-pyenv
247240

248-
- run: *install-dependencies-template
241+
- run: *install-dependencies
249242

250-
- run: *install-package-template
243+
- run: *install-package
251244

252245
- run:
253246
name: create bdist_wheel
@@ -258,28 +251,33 @@ jobs:
258251
- store_artifacts:
259252
path: ./dist
260253

261-
- run: *init-pypirc-template
254+
- run: *upload-pypi
262255

263-
- run: *upload-template
256+
build-osx-3.8:
257+
<<: *osx-build-template
258+
environment:
259+
PYTHON: 3.8.6
260+
HOMEBREW_NO_AUTO_UPDATE: 1
261+
MACOSX_DEPLOYMENT_TARGET: 10.9
264262

265263
build-osx-3.7:
266264
<<: *osx-build-template
267265
environment:
268-
PYTHON: 3.7.4
266+
PYTHON: 3.7.9
269267
HOMEBREW_NO_AUTO_UPDATE: 1
270268
MACOSX_DEPLOYMENT_TARGET: 10.9
271269

272270
build-osx-3.6:
273271
<<: *osx-build-template
274272
environment:
275-
PYTHON: 3.6.5
273+
PYTHON: 3.6.12
276274
HOMEBREW_NO_AUTO_UPDATE: 1
277275
MACOSX_DEPLOYMENT_TARGET: 10.9
278276

279277
build-osx-3.5:
280278
<<: *osx-build-template
281279
environment:
282-
PYTHON: 3.5.5
280+
PYTHON: 3.5.10
283281
HOMEBREW_NO_AUTO_UPDATE: 1
284282
MACOSX_DEPLOYMENT_TARGET: 10.9
285283

@@ -288,10 +286,12 @@ workflows:
288286
version: 2
289287
test:
290288
jobs:
289+
- test-3.9
291290
- test-3.8
292291
- test-3.7
293292
- test-3.6
294293
- test-3.5
294+
- test-osx-3.9
295295
- test-osx-3.8
296296
- test-osx-3.7
297297
- test-osx-3.6
@@ -311,6 +311,12 @@ workflows:
311311
only: /^[0-9]+(\.[0-9]+)*(\.dev([0-9]+)?)?$/
312312
branches:
313313
ignore: /.*/
314+
- build-osx-3.9:
315+
filters:
316+
tags:
317+
only: /^[0-9]+(\.[0-9]+)*(\.dev([0-9]+)?)?$/
318+
branches:
319+
ignore: /.*/
314320
- build-osx-3.8:
315321
filters:
316322
tags:

requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
dimod==0.9.5
1+
dimod==0.9.12
22
cython==0.29.21

setup.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ def build_extensions(self):
6767
'Programming Language :: Python :: 3.6',
6868
'Programming Language :: Python :: 3.7',
6969
'Programming Language :: Python :: 3.8',
70+
'Programming Language :: Python :: 3.9',
7071
]
7172

7273
python_requires = '>=3.5'

0 commit comments

Comments
 (0)