Skip to content

Commit

Permalink
fix: publishing
Browse files Browse the repository at this point in the history
  • Loading branch information
dirvine committed Nov 11, 2024
1 parent 78880f8 commit e544465
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 17 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/python-publish-client.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.target }}
args: --release --out dist --find-interpreter --compatibility manylinux2014
args: --release --out dist --find-interpreter
sccache: 'true'
working-directory: ./autonomi
- name: Upload wheels
Expand Down Expand Up @@ -84,7 +84,7 @@ jobs:
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
args: --release --out dist --find-interpreter --compatibility manylinux2014
args: --release --out dist --find-interpreter
sccache: 'true'
working-directory: ./autonomi
- name: Upload wheels
Expand Down Expand Up @@ -137,7 +137,7 @@ jobs:
with:
target: ${{ matrix.target }}
manylinux: "2014"
args: --release --out dist --find-interpreter --compatibility manylinux2014
args: --release --out dist --find-interpreter
sccache: 'true'
working-directory: ./autonomi
- name: Upload wheels
Expand Down
29 changes: 17 additions & 12 deletions .github/workflows/python-publish-node.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,14 @@ jobs:
run: |
mkdir -p sn_node/python/safenode
cat > sn_node/python/safenode/__init__.py << EOL
from ._safenode import *
from .safenode import *
__version__ = "${{ github.ref_name }}"
EOL
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.target }}
args: --release --out dist
args: --release --out dist --find-interpreter
sccache: 'true'
working-directory: ./sn_node
- name: Upload wheels
Expand Down Expand Up @@ -79,12 +79,12 @@ jobs:
shell: cmd
run: |
if not exist "sn_node\python\safenode" mkdir sn_node\python\safenode
echo from ._safenode import * > sn_node\python\safenode\__init__.py
echo from .safenode import * > sn_node\python\safenode\__init__.py
echo __version__ = "${{ github.ref_name }}" >> sn_node\python\safenode\__init__.py
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
args: --release --out dist
args: --release --out dist --find-interpreter
sccache: 'true'
working-directory: ./sn_node
- name: Upload wheels
Expand Down Expand Up @@ -129,21 +129,17 @@ jobs:
run: |
mkdir -p sn_node/python/safenode
cat > sn_node/python/safenode/__init__.py << EOL
from ._safenode import *
from .safenode import *
__version__ = "${{ github.ref_name }}"
EOL
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.target }}
manylinux: auto
args: --release --out dist
manylinux: "2014"
args: --release --out dist --find-interpreter
sccache: 'true'
working-directory: ./sn_node
before-script-linux: |
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
source $HOME/.cargo/env
rustup component add rustfmt
- name: Upload wheels
uses: actions/upload-artifact@v4
with:
Expand Down Expand Up @@ -173,7 +169,7 @@ jobs:
run: |
mkdir -p sn_node/python/safenode
cat > sn_node/python/safenode/__init__.py << EOL
from ._safenode import *
from .safenode import *
__version__ = "${{ github.ref_name }}"
EOL
- name: Build sdist
Expand Down Expand Up @@ -221,6 +217,15 @@ jobs:
echo "Final dist directory contents:"
ls -la dist/
- name: Check if version exists
run: |
VERSION="${{ github.ref_name }}"
VERSION="${VERSION#v}" # Remove 'v' prefix if present
if pip index versions safenode | grep -q "${VERSION}"; then
echo "Version ${VERSION} already exists on PyPI"
exit 1
fi
- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
Expand Down
2 changes: 1 addition & 1 deletion autonomi/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ authors = ["MaidSafe Developers <[email protected]>"]
description = "Autonomi client API"
name = "autonomi"
license = "GPL-3.0"
version = "0.2.31"
version = "0.2.32"
edition = "2021"
homepage = "https://maidsafe.net"
readme = "README.md"
Expand Down
2 changes: 1 addition & 1 deletion sn_node/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
authors = ["MaidSafe Developers <[email protected]>"]
description = "Safe Node"
name = "sn_node"
version = "0.112.4"
version = "0.112.41"
edition = "2021"
license = "GPL-3.0"
homepage = "https://maidsafe.net"
Expand Down

0 comments on commit e544465

Please sign in to comment.