Skip to content

Commit 815ebac

Browse files
authored
Fix building wheels for Python 3.7 (#1933)
1 parent 337d5f7 commit 815ebac

File tree

6 files changed

+19
-5
lines changed

6 files changed

+19
-5
lines changed

.github/workflows/build-wheels-linux-cuda.yaml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,11 @@ jobs:
3434
- name: Install Python dependencies
3535
shell: bash
3636
run: |
37-
pip install -U pip wheel setuptools twine==5.0.0
37+
if [[ ${{ matrix.python-version }} == "3.7" ]]; then
38+
pip install -U pip wheel setuptools twine
39+
else
40+
pip install -U pip wheel setuptools twine==5.0.0
41+
fi
3842
3943
- name: Build alsa-lib
4044
shell: bash

.github/workflows/build-wheels-macos-x64.yaml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,10 @@ jobs:
110110
fi
111111
112112
python3 -m pip install $opts --upgrade pip
113-
python3 -m pip install $opts wheel twine==5.0.0 setuptools
113+
if [[ ${{ matrix.python-version }} == "cp37" ]]; then
114+
python3 -m pip install $opts wheel twine setuptools
115+
else
116+
python3 -m pip install $opts wheel twine==5.0.0 setuptools
117+
fi
114118
115119
twine upload ./wheelhouse/*.whl

.github/workflows/build-wheels-win64.yaml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,11 +89,16 @@ jobs:
8989
git push https://csukuangfj:[email protected]/csukuangfj/sherpa-onnx-wheels main
9090
9191
- name: Publish wheels to PyPI
92+
shell: bash
9293
env:
9394
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
9495
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
9596
run: |
9697
python3 -m pip install --upgrade pip
97-
python3 -m pip install wheel twine==5.0.0 setuptools
98+
if [[ ${{ matrix.python-version }} == "3.7" ]]; then
99+
python3 -m pip install wheel twine setuptools
100+
else
101+
python3 -m pip install wheel twine==5.0.0 setuptools
102+
fi
98103
99104
twine upload ./wheelhouse/*.whl

.github/workflows/test-go-package.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ jobs:
4343
fetch-depth: 0
4444
- uses: actions/setup-go@v5
4545
with:
46-
go-version: '>=1.12'
46+
go-version: '>=1.17'
4747

4848
- name: Display go version
4949
shell: bash

.github/workflows/test-go.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ jobs:
4747

4848
- uses: actions/setup-go@v5
4949
with:
50-
go-version: '>=1.12'
50+
go-version: '>=1.17'
5151

5252
- name: Display go version
5353
shell: bash

scripts/go/release.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ echo "SHERPA_ONNX_VERSION $SHERPA_ONNX_VERSION"
1717
function linux() {
1818
echo "Process linux"
1919
git clone [email protected]:k2-fsa/sherpa-onnx-go-linux.git
20+
2021
rm -v ./sherpa-onnx-go-linux/*.go
2122

2223
cp -v ./sherpa_onnx.go ./sherpa-onnx-go-linux/

0 commit comments

Comments
 (0)