Skip to content

Commit 66c117f

Browse files
committed
31 | Update test workflow
1 parent d7338af commit 66c117f

File tree

7 files changed

+107
-45
lines changed

7 files changed

+107
-45
lines changed

.github/workflows/deploy-docs.yaml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,7 @@ jobs:
1616
environment: github-pages
1717

1818
steps:
19-
- name: Checkout Repository
20-
uses: actions/checkout@v3
19+
- uses: actions/checkout@v4
2120

2221
- name: Setup Python
2322
uses: actions/setup-python@v4

.github/workflows/publish-to-pypi.yaml

Lines changed: 53 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -12,48 +12,85 @@ jobs:
1212
os: [ubuntu-latest, windows-latest, macos-latest]
1313

1414
steps:
15-
- name: Checkout code
16-
uses: actions/checkout@v3
15+
- uses: actions/checkout@v4
1716

18-
- name: Set up Python
19-
uses: actions/setup-python@v4
20-
with:
21-
python-version: 3.11
17+
- uses: actions/setup-python@v5
2218

2319
- name: Install build tools
24-
run: pip install build twine wheel cibuildwheel
20+
run: python -m pip install cibuildwheel
2521

2622
- name: Build wheel with cibuildwheel
2723
env:
28-
CIBW_BUILD: cp37-*,cp38-*,cp39-*,cp310-*,cp311-*,cp312-*,cp313-*,cp314-*
29-
run: cibuildwheel --output-dir wheelhouse
24+
CIBW_BUILD: "cp37-* cp38-* cp39-* cp310-* cp311-* cp312-* cp313-* cp314-*"
25+
CIBW_BEFORE_BUILD: pip install cffi
26+
run: python -m cibuildwheel --output-dir wheelhouse
3027

3128
- name: Upload wheels
32-
uses: actions/upload-artifact@v3
29+
uses: actions/upload-artifact@v4
3330
with:
3431
name: wheels-${{ matrix.os }}
3532
path: wheelhouse/
3633

34+
build-dist-artifacts:
35+
runs-on: ubuntu-latest
36+
37+
steps:
38+
- uses: actions/checkout@v4
39+
40+
- uses: actions/setup-python@v5
41+
42+
- name: Install build tools
43+
run: pip install build wheel cython
44+
45+
- name: Compile and Build package
46+
run: python setup.py sdist bdist_wheel
47+
48+
- name: Upload dist
49+
uses: actions/upload-artifact@v4
50+
with:
51+
name: dist
52+
path: dist/
53+
3754
publish:
38-
needs: build
55+
needs:
56+
- build
57+
- build-dist-artifacts
3958
runs-on: ubuntu-latest
4059

4160
steps:
61+
- uses: actions/checkout@v4
62+
63+
- uses: actions/setup-python@v5
64+
65+
- name: Install build tools
66+
run: pip install build twine wheel cython
67+
4268
- name: Download wheels
43-
uses: actions/download-artifact@v3
69+
uses: actions/download-artifact@v4
4470
with:
4571
name: wheels-ubuntu-latest
72+
4673
- name: Download wheels
47-
uses: actions/download-artifact@v3
74+
uses: actions/download-artifact@v4
4875
with:
4976
name: wheels-windows-latest
77+
5078
- name: Download wheels
51-
uses: actions/download-artifact@v3
79+
uses: actions/download-artifact@v4
5280
with:
5381
name: wheels-macos-latest
5482

55-
- name: Combine wheels
56-
run: mkdir dist && mv wheelhouse/* dist/
83+
- name: Download dist
84+
uses: actions/download-artifact@v4
85+
with:
86+
name: dist
87+
88+
- name: Compile and Build package
89+
run: |
90+
mkdir -p dist
91+
for f in *; do
92+
[ "$f" != "dist" ] && mv "$f" dist/
93+
done
5794
5895
- name: Publish to PyPI
5996
env:

.github/workflows/test-lib-building.yaml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,7 @@ jobs:
1414
os: [ubuntu-latest, windows-latest, macos-latest]
1515

1616
steps:
17-
- name: Checkout code
18-
uses: actions/checkout@v3
17+
- uses: actions/checkout@v4
1918

2019
- name: Set up Python
2120
uses: actions/setup-python@v4
Lines changed: 48 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
name: Publish to PyPI
22

33
on:
4-
release:
5-
types: [published]
4+
push:
5+
branches:
6+
- main
67

78
jobs:
89
build:
@@ -12,48 +13,75 @@ jobs:
1213
os: [ubuntu-latest, windows-latest, macos-latest]
1314

1415
steps:
15-
- name: Checkout code
16-
uses: actions/checkout@v3
16+
- uses: actions/checkout@v4
1717

18-
- name: Set up Python
19-
uses: actions/setup-python@v4
20-
with:
21-
python-version: 3.11
18+
- uses: actions/setup-python@v5
2219

2320
- name: Install build tools
24-
run: pip install build twine wheel cibuildwheel
21+
run: python -m pip install cibuildwheel
2522

2623
- name: Build wheel with cibuildwheel
2724
env:
28-
CIBW_BUILD: cp37-*,cp38-*,cp39-*,cp310-*,cp311-*,cp312-*,cp313-*,cp314-*
29-
run: cibuildwheel --output-dir wheelhouse
25+
CIBW_BUILD: "cp37-* cp38-* cp39-* cp310-* cp311-* cp312-* cp313-* cp314-*"
26+
CIBW_BEFORE_BUILD: pip install cffi
27+
run: python -m cibuildwheel --output-dir wheelhouse
3028

3129
- name: Upload wheels
32-
uses: actions/upload-artifact@v3
30+
uses: actions/upload-artifact@v4
3331
with:
3432
name: wheels-${{ matrix.os }}
3533
path: wheelhouse/
3634

35+
build-dist-artifacts:
36+
runs-on: ubuntu-latest
37+
38+
steps:
39+
- uses: actions/checkout@v4
40+
41+
- uses: actions/setup-python@v5
42+
43+
- name: Install build tools
44+
run: pip install build twine wheel cython
45+
46+
- name: Compile and Build package
47+
run: python setup.py sdist bdist_wheel
48+
49+
- name: Upload dist
50+
uses: actions/upload-artifact@v4
51+
with:
52+
name: dist
53+
path: dist/
54+
3755
publish:
38-
needs: build
56+
needs:
57+
- build
58+
- build-dist-artifacts
3959
runs-on: ubuntu-latest
4060

4161
steps:
4262
- name: Download wheels
43-
uses: actions/download-artifact@v3
63+
uses: actions/download-artifact@v4
4464
with:
4565
name: wheels-ubuntu-latest
66+
4667
- name: Download wheels
47-
uses: actions/download-artifact@v3
68+
uses: actions/download-artifact@v4
4869
with:
4970
name: wheels-windows-latest
71+
5072
- name: Download wheels
51-
uses: actions/download-artifact@v3
73+
uses: actions/download-artifact@v4
5274
with:
5375
name: wheels-macos-latest
5476

55-
- name: Combine wheels
56-
run: mkdir dist && mv wheelhouse/* dist/
77+
- name: Download dist
78+
uses: actions/download-artifact@v4
79+
with:
80+
name: dist
5781

58-
- name: Publish to PyPI
59-
run: ls -la dist
82+
- name: Compile and Build package
83+
run: |
84+
mkdir -p dist
85+
for f in *; do
86+
[ "$f" != "dist" ] && mv "$f" dist/
87+
done

.github/workflows/test_env.yaml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,7 @@ jobs:
1111
runs-on: ubuntu-latest
1212

1313
steps:
14-
- name: Checkout code
15-
uses: actions/checkout@v4
14+
- uses: actions/checkout@v4
1615

1716
- name: Cache Docker layers
1817
uses: actions/cache@v4

flask_inputfilter/__init__.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import os
2+
import sys
23

3-
if os.getenv("flask_inputfilter_dev"):
4+
if os.getenv("flask_inputfilter_dev") or sys.version_info == (3, 14):
45
import pyximport
56

67
pyximport.install()

setup.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,8 @@
33

44
setup(
55
name="flask_inputfilter",
6-
version="0.2.0",
6+
version="0.2.0a1",
77
license="MIT",
8-
license_files=["LICENSE"],
98
author="Leander Cain Slotosch",
109
author_email="[email protected]",
1110
description="A library to filter and validate input data in "

0 commit comments

Comments
 (0)