33#
44# * Linux
55# * macOS
6- # * Windows (commented )
6+ # * Windows (disabled )
77# * FreeBSD
88#
99# To skip certain builds see:
1010# https://cibuildwheel.readthedocs.io/en/stable/options/#build-skip
1111#
1212# External GH actions:
13+ # * https://github.com/pypa/cibuildwheel
1314# * https://github.com/actions/checkout
1415# * https://github.com/actions/setup-python
1516# * https://github.com/actions/upload-artifact
1920on : [push, pull_request]
2021name : build
2122jobs :
22- linux-macos-win :
23- name : ${{ matrix.os }}
23+ # Linux + macOS + Python 3
24+ linux-macos-py3 :
25+ name : ${{ matrix.os }}-py3
2426 runs-on : ${{ matrix.os }}
25- timeout-minutes : 30
27+ timeout-minutes : 20
2628 strategy :
2729 fail-fast : false
2830 matrix :
@@ -35,11 +37,12 @@ jobs:
3537 PYTHONWARNINGS=always PYTHONUNBUFFERED=1 PSUTIL_DEBUG=1 python {project}/psutil/tests/runner.py &&
3638 PYTHONWARNINGS=always PYTHONUNBUFFERED=1 PSUTIL_DEBUG=1 python {project}/psutil/tests/test_memleaks.py
3739 CIBW_TEST_EXTRAS : test
38- CIBW_SKIP : cp35-* pp*
40+ CIBW_BUILD : ' cp37-* cp38-* cp39-* cp310-*'
41+ CIBW_SKIP : ' *-musllinux_*'
3942
4043 steps :
4144 - name : Cancel previous runs
42- uses : styfle/cancel-workflow-action@0.6.0
45+ uses : styfle/cancel-workflow-action@0.9.1
4346 with :
4447 access_token : ${{ github.token }}
4548
7376 mv dist/psutil*.tar.gz wheelhouse/
7477 python scripts/internal/print_hashes.py wheelhouse/
7578
79+ # Linux + macOS + Python 2
80+ linux-macos-py2 :
81+ name : ${{ matrix.os }}-py2
82+ runs-on : ubuntu-latest
83+ timeout-minutes : 20
84+ strategy :
85+ fail-fast : false
86+ matrix :
87+ os : [ubuntu-latest, macos-latest]
88+ include :
89+ - {name: Linux, python: '3.9', os: ubuntu-latest}
90+ env :
91+ CIBW_ARCHS : ' x86_64 i686'
92+ CIBW_TEST_COMMAND :
93+ PYTHONWARNINGS=always PYTHONUNBUFFERED=1 PSUTIL_DEBUG=1 python {project}/psutil/tests/runner.py &&
94+ PYTHONWARNINGS=always PYTHONUNBUFFERED=1 PSUTIL_DEBUG=1 python {project}/psutil/tests/test_memleaks.py
95+ CIBW_TEST_EXTRAS : test
96+ CIBW_BUILD : ' cp27-*'
97+ CIBW_SKIP : ' *-musllinux_*'
98+
99+ steps :
100+ - name : Cancel previous runs
101+ uses : styfle/cancel-workflow-action@0.9.1
102+ with :
103+ access_token : ${{ github.token }}
104+
105+ - uses : actions/checkout@v2
106+ - uses : actions/setup-python@v2
107+ with :
108+ python-version : 3.9
109+
110+ - name : Install cibuildwheel
111+ run : pip install cibuildwheel==1.12.0
112+
113+ - name : Run tests
114+ run : cibuildwheel .
115+
116+ - name : Create wheels
117+ uses : actions/upload-artifact@v2
118+ with :
119+ name : wheels
120+ path : wheelhouse
121+
122+ - name : Print hashes
123+ if : matrix.os == 'ubuntu-latest'
124+ run : |
125+ make generate-manifest
126+ python setup.py sdist
127+ mv dist/psutil*.tar.gz wheelhouse/
128+ python scripts/internal/print_hashes.py wheelhouse/
129+
76130 freebsd :
77131 runs-on : macos-latest
78132 steps :
0 commit comments