Skip to content

Commit

Permalink
Corrected release issues with github and pypi for Python wheels
Browse files Browse the repository at this point in the history
  • Loading branch information
gsleap committed Oct 17, 2024
1 parent 2aac8c3 commit b205be5
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 7 deletions.
23 changes: 19 additions & 4 deletions .github/workflows/releases.yml
Original file line number Diff line number Diff line change
Expand Up @@ -206,19 +206,34 @@ jobs:
gh release create "$tag" \
--repo="$GITHUB_REPOSITORY" \
--title="${GITHUB_REPOSITORY#*/} ${tag#v}" \
--generate-notes *.tar.gz
--generate-notes *.tar.gz *.whl
pypi_release:
name: PyPi Release
name: Publish to pypi
runs-on: ubuntu-latest
if: ${{ startsWith(github.ref, 'refs/tags/') }}
if: ${{ startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch' }}
needs: [create-github-release]
permissions:
# Use to sign the release artifacts
id-token: write
# Used to upload release artifacts
contents: write
# Used to generate artifact attestation
attestations: write
steps:
- uses: actions/download-artifact@v4
- name: Download artifacts
uses: actions/download-artifact@v4
with:
pattern: wheels-*
merge-multiple: true

- name: Generate artifact attestation
uses: actions/attest-build-provenance@v1
with:
subject-path: 'wheels-*/*'

- name: Publish to PyPI
if: startsWith(github.ref, 'refs/tags/')
uses: PyO3/maturin-action@v1
env:
MATURIN_PYPI_TOKEN: ${{ secrets.PYPI_API_TOKEN }}
Expand Down
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

Changes in each release are listed below.

## 1.6.1 17-Oct-2024

* Correcting release issues with github and pypi for Python wheels

## 1.6.0 17-Oct-2024

* Updated ndarray to 0.16
Expand Down
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "mwalib"
version = "1.6.0"
version = "1.6.1"
homepage = "https://github.com/MWATelescope/mwalib"
repository = "https://github.com/MWATelescope/mwalib"
readme = "README.md"
Expand Down
4 changes: 2 additions & 2 deletions tools/test_msrv.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ RUSTUP_TOOLCHAIN=${MIN_RUST} cargo update --verbose

# Build and run rust tests
echo "Building and running tests..."
RUSTUP_TOOLCHAIN=${MIN_RUST} MWALIB_LINK_STATIC_CFITSIO=1 cargo test --release --all-features
RUSTUP_TOOLCHAIN=${MIN_RUST} cargo test --release --all-features

# Install mwalib python wheel
echo "Installing mwalib python wheel..."
RUSTUP_TOOLCHAIN=${MIN_RUST} MWALIB_LINK_STATIC_CFITSIO=1 maturin develop --all-features --release --strip
RUSTUP_TOOLCHAIN=${MIN_RUST} maturin develop --all-features --release --strip

# Run python tests
echo "Running python tests..."
Expand Down

0 comments on commit b205be5

Please sign in to comment.