Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update actions, fix publishing #1063

Merged
merged 1 commit into from
Oct 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
Expand Down
71 changes: 36 additions & 35 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ jobs:
package-source:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.9"
- name: Prepare C files to include
Expand All @@ -25,9 +25,9 @@ jobs:
- name: Build source package
run: python -m build --sdist
- name: Upload source package
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: dist
name: dist-source
path: dist/

package-wheel:
Expand All @@ -49,17 +49,17 @@ jobs:
- os: windows-latest
arch: amd64
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.9"
- name: Set up QEMU
if: ${{ matrix.arch == 'aarch64' }}
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3
- name: Build wheels
env:
CIBW_ARCHS_LINUX: ${{matrix.arch}}
CIBW_BUILD: cp38-* cp39-* cp310-* cp311-* cp312-*
CIBW_BUILD: cp39-* cp310-* cp311-* cp312-* cp313-*
CIBW_SKIP: '*-musllinux*'
CIBW_BEFORE_BUILD_LINUX: pip install -r requirements-cython.txt && yum install -y zlib-devel
# On windows and mac we should have z library preinstalled
Expand All @@ -71,9 +71,9 @@ jobs:
cibuildwheel --output-dir dist
shell: bash
- name: Upload wheels
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: dist
name: dist-${{ matrix.os }}-${{ matrix.arch }}
path: dist/

test-wheels-windows:
Expand All @@ -96,14 +96,14 @@ jobs:
aiokafka_whl: dist/aiokafka-*-cp313-cp313-win_amd64.whl

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Download distributions
uses: actions/download-artifact@v2
uses: actions/download-artifact@v4
with:
name: dist
name: dist-windows-latest-amd64
path: dist/
- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}

Expand Down Expand Up @@ -141,14 +141,14 @@ jobs:
aiokafka_whl: dist/aiokafka-*-cp313-cp313-macosx_*_x86_64.whl

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Download distributions
uses: actions/download-artifact@v2
uses: actions/download-artifact@v4
with:
name: dist
name: dist-macos-13-x86_64
path: dist/
- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}

Expand Down Expand Up @@ -184,14 +184,14 @@ jobs:
aiokafka_whl: dist/aiokafka-*-cp313-cp313-macosx_*_arm64.whl

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Download distributions
uses: actions/download-artifact@v2
uses: actions/download-artifact@v4
with:
name: dist
name: dist-macos-latest-arm64
path: dist/
- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}

Expand Down Expand Up @@ -227,14 +227,14 @@ jobs:
aiokafka_whl: dist/aiokafka-*-cp313-cp313-manylinux*_x86_64.whl

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Download distributions
uses: actions/download-artifact@v2
uses: actions/download-artifact@v4
with:
name: dist
name: dist-ubuntu-latest-x86_64
path: dist/
- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}

Expand Down Expand Up @@ -264,8 +264,6 @@ jobs:
strategy:
matrix:
include:
- pyver: cp38-cp38
aiokafka_whl: dist/aiokafka-*-cp38-cp38-manylinux*_aarch64.whl
- pyver: cp39-cp39
aiokafka_whl: dist/aiokafka-*-cp39-cp39-manylinux*_aarch64.whl
- pyver: cp310-cp310
Expand All @@ -274,16 +272,18 @@ jobs:
aiokafka_whl: dist/aiokafka-*-cp311-cp311-manylinux*_aarch64.whl
- pyver: cp312-cp312
aiokafka_whl: dist/aiokafka-*-cp312-cp312-manylinux*_aarch64.whl
- pyver: cp313-cp313
aiokafka_whl: dist/aiokafka-*-cp313-cp313-manylinux*_aarch64.whl

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Set up QEMU
id: qemu
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3
- name: Download distributions
uses: actions/download-artifact@v2
uses: actions/download-artifact@v4
with:
name: dist
name: dist-ubuntu-latest-aarch64
path: dist/
- name: Test Wheel
run: |
Expand Down Expand Up @@ -320,11 +320,12 @@ jobs:
https://pypi.org/project/aiokafka/${{ github.ref_name }}

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Download distributions
uses: actions/download-artifact@v2
uses: actions/download-artifact@v4
with:
name: dist
path: dist/
pattern: dist-*
merge-multiple: true
- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
36 changes: 18 additions & 18 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v5
with:
python-version: 3.9

Expand All @@ -36,7 +36,7 @@ jobs:
echo "::set-output name=dir::$(pip cache dir)"

- name: Cache packages
uses: actions/cache@v1
uses: actions/cache@v4
with:
path: ${{ steps.pip-cache.outputs.dir }}
key: ${{ runner.os }}-py-3.9-${{ hashFiles('requirements-ci.txt') }}-${{ hashFiles('setup.py') }}
Expand Down Expand Up @@ -76,11 +76,11 @@ jobs:
python: ["3.9", "3.10", "3.11", "3.12", "3.13"]

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}
- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}

Expand All @@ -91,7 +91,7 @@ jobs:
echo "::set-output name=dir::$(pip cache dir)"

- name: Cache packages
uses: actions/cache@v1
uses: actions/cache@v4
with:
path: ${{ steps.pip-cache.outputs.dir }}
key: ${{ runner.os }}-py-${{ matrix.python }}-${{ hashFiles('requirements-win-test.txt') }}-${{ hashFiles('setup.py') }}
Expand Down Expand Up @@ -120,15 +120,15 @@ jobs:
AIOKAFKA_NO_EXTENSIONS: "1"

- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
uses: codecov/codecov-action@v4
with:
file: ./coverage-ext.xml
flags: unit,cext
name: test-windows-${{ matrix.python }}-ext
if: ${{ always() }}

- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
uses: codecov/codecov-action@v4
with:
file: ./coverage-py.xml
flags: unit,purepy
Expand All @@ -144,11 +144,11 @@ jobs:
python: ["3.9", "3.10", "3.11", "3.12", "3.13"]

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}
- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}

Expand All @@ -159,7 +159,7 @@ jobs:
echo "::set-output name=dir::$(pip cache dir)"

- name: Cache packages
uses: actions/cache@v1
uses: actions/cache@v4
with:
path: ${{ steps.pip-cache.outputs.dir }}
key: ${{ runner.os }}-py-${{ matrix.python }}-${{ hashFiles('requirements-ci.txt') }}-${{ hashFiles('setup.py') }}
Expand Down Expand Up @@ -188,15 +188,15 @@ jobs:
AIOKAFKA_NO_EXTENSIONS: "1"

- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
uses: codecov/codecov-action@v4
with:
file: ./coverage-ext.xml
flags: unit,cext
name: test-mac-${{ matrix.python }}-ext
if: ${{ always() }}

- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
uses: codecov/codecov-action@v4
with:
file: ./coverage-py.xml
flags: unit,purepy
Expand Down Expand Up @@ -265,11 +265,11 @@ jobs:
fail-fast: false

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}
- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}

Expand All @@ -285,7 +285,7 @@ jobs:
echo "::set-output name=dir::$(pip cache dir)"

- name: Cache packages
uses: actions/cache@v1
uses: actions/cache@v4
with:
path: ${{ steps.pip-cache.outputs.dir }}
key: ${{ runner.os }}-py-${{ matrix.python }}-${{ hashFiles('requirements-ci.txt') }}-${{ hashFiles('setup.py') }}
Expand Down Expand Up @@ -317,15 +317,15 @@ jobs:
KAFKA_VERSION: ${{ matrix.kafka }}

- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
uses: codecov/codecov-action@v4
with:
file: ./coverage-ext.xml
flags: integration,cext
name: test-linux-${{ matrix.python }}-${{ matrix.kafka }}-${{ matrix.scala }}-ext
if: ${{ always() }}

- name: Upload coverage without cext to Codecov
uses: codecov/codecov-action@v1
uses: codecov/codecov-action@v4
with:
file: ./coverage-py.xml
flags: integration,purepy
Expand Down
Loading