Skip to content

Commit

Permalink
ci: use maturin 1.6.0 for building the source package.
Browse files Browse the repository at this point in the history
The latest version (1.7.0) has the following issue: PyO3/maturin#2154
  • Loading branch information
plusvic committed Jul 30, 2024
1 parent b069f34 commit f5e1f74
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
- build: windows
os: windows-latest
target: x86_64-pc-windows-msvc

steps:
- name: Checkout sources
uses: actions/checkout@v4
Expand Down Expand Up @@ -74,7 +74,7 @@ jobs:
with:
name: yr-${{ matrix.target }}
path: yara-x-*

build-py:
runs-on: ${{ matrix.os }}
strategy:
Expand Down Expand Up @@ -103,7 +103,7 @@ jobs:
- build: windows
os: windows-latest
arch: 'x86 AMD64'

steps:
- name: Checkout sources
uses: actions/checkout@v4
Expand Down Expand Up @@ -135,8 +135,10 @@ jobs:

- name: Build sdist
if: matrix.build == 'linux' && matrix.python-version == 'cp312'
# Using maturin 1.6.0 because the latest version (1.7.0) has the
# following issue: https://github.com/PyO3/maturin/issues/2154
run: |
pip install maturin build
pip install maturin==1.6.0 build
python -m build --sdist -o wheelhouse py
- name: Build ${{ matrix.platform || matrix.os }} binaries
Expand Down Expand Up @@ -171,11 +173,11 @@ jobs:
with:
name: pypi-source-${{ strategy.job-index }}
path: ./wheelhouse/*.tar.gz

publish-cli:
needs: [ build-cli ]
runs-on: ubuntu-latest

steps:
- name: Download artifacts
uses: actions/download-artifact@v4
Expand All @@ -191,7 +193,7 @@ jobs:
with:
draft: true
files: yr-*/yara-x-*

publish-crate:
needs: [ publish-cli ]
runs-on: ubuntu-latest
Expand All @@ -203,7 +205,7 @@ jobs:
env:
# Don't re-generate the files `modules.rs` and `add_modules.rs`, use
# the ones in the repository. These files can't be regenerated because
# `cargo publish` checks that the repository doesn't change during
# `cargo publish` checks that the repository doesn't change during
# the build. See: https://github.com/rust-lang/cargo/pull/5584
YRX_REGENERATE_MODULES_RS: "no"
run: |
Expand All @@ -213,7 +215,7 @@ jobs:
cargo publish -p yara-x-proto-yaml
cargo publish -p yara-x-parser
cargo publish -p yara-x
publish-py:
needs: [ build-py ]
runs-on: ubuntu-latest
Expand Down

0 comments on commit f5e1f74

Please sign in to comment.