Skip to content

Commit 89cc410

Browse files
committed
Merge remote-tracking branch 'origin/master'
2 parents f6360fc + 534bbb3 commit 89cc410

4 files changed

Lines changed: 23 additions & 50 deletions

File tree

.github/workflows/publish-pypi.yml

Lines changed: 5 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@ jobs:
1919
uses: dawidd6/action-download-artifact@v6
2020
with:
2121
workflow: osx-build-test-amd64.yml
22-
path: dist
22+
path: .
2323
- name: "Download Linux/amd64 artifacts"
2424
uses: dawidd6/action-download-artifact@v6
2525
with:
26-
workflow: osx-build-test-amd64.yml
26+
workflow: linux-build-test-amd64.yml
2727
path: .
2828
- name: "Download Linux/arm64 artifacts"
2929
uses: dawidd6/action-download-artifact@v6
@@ -45,11 +45,8 @@ jobs:
4545
with:
4646
path: dist
4747
- name: show dist layout
48-
run: |
49-
ls -al
50-
ls -al dist
51-
find dist
52-
- name: Publish distribution 📦 to PyPI
48+
run: find dist
49+
- name: Publish distribution 📦 to TestPyPI
5350
uses: pypa/gh-action-pypi-publish@release/v1
5451
test-pypi-packages:
5552
runs-on: ${{ matrix.os }}
@@ -71,16 +68,4 @@ jobs:
7168
run: |
7269
python3 -m venv venv
7370
venv/bin/pip install --upgrade pip
74-
venv/bin/pip install python-snap7[test]
75-
76-
- name: Run pytest
77-
run: |
78-
venv/bin/pytest -m "server or util or client or mainloop"
79-
80-
- name: Run tests required sudo on Linux and macOS
81-
if: ${{ runner.os == 'Linux' || runner.os == 'macOS'}}
82-
run: sudo venv/bin/pytest -m partner
83-
84-
- name: On windows we don't need sudo
85-
if: ${{ runner.os == 'Windows'}}
86-
run: venv/bin/pytest -m partner
71+
venv/bin/pip install --extra-index-url https://test.pypi.org/simple/ python-snap7[test]

.github/workflows/publish-test-pypi.yml

Lines changed: 5 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@ jobs:
1919
uses: dawidd6/action-download-artifact@v6
2020
with:
2121
workflow: osx-build-test-amd64.yml
22-
path: dist
22+
path: .
2323
- name: "Download Linux/amd64 artifacts"
2424
uses: dawidd6/action-download-artifact@v6
2525
with:
26-
workflow: osx-build-test-amd64.yml
26+
workflow: linux-build-test-amd64.yml
2727
path: .
2828
- name: "Download Linux/arm64 artifacts"
2929
uses: dawidd6/action-download-artifact@v6
@@ -45,14 +45,12 @@ jobs:
4545
with:
4646
path: dist
4747
- name: show dist layout
48-
run: |
49-
ls -al
50-
ls -al dist
51-
find dist
48+
run: find dist
5249
- name: Publish distribution 📦 to TestPyPI
5350
uses: pypa/gh-action-pypi-publish@release/v1
5451
with:
5552
repository-url: https://test.pypi.org/legacy/
53+
verbose: true
5654
test-pypi-packages:
5755
runs-on: ${{ matrix.os }}
5856
needs: publish-to-testpypi
@@ -73,16 +71,4 @@ jobs:
7371
run: |
7472
python3 -m venv venv
7573
venv/bin/pip install --upgrade pip
76-
venv/bin/pip install -i https://test.pypi.org/simple/ python-snap7[test]
77-
78-
- name: Run pytest
79-
run: |
80-
venv/bin/pytest -m "server or util or client or mainloop"
81-
82-
- name: Run tests required sudo on Linux and macOS
83-
if: ${{ runner.os == 'Linux' || runner.os == 'macOS'}}
84-
run: sudo venv/bin/pytest -m partner
85-
86-
- name: On windows we don't need sudo
87-
if: ${{ runner.os == 'Windows'}}
88-
run: venv/bin/pytest -m partner
74+
venv/bin/pip install --extra-index-url https://test.pypi.org/simple/ python-snap7[test]

.github/workflows/windows-build-test-amd64.yml

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,12 @@ jobs:
2020
mkdir -p snap7/lib/
2121
Copy-Item .\snap7-full-1.4.2\release\Windows\Win64\snap7.dll .\snap7\lib
2222
python3 -m build . --wheel -C="--build-option=--plat-name=win_amd64"
23-
mkdir -p wheelhouse/${{ runner.os }}/
24-
cp dist/*.whl wheelhouse/${{ runner.os }}/
2523
2624
- name: Upload artifacts
2725
uses: actions/upload-artifact@v4
2826
with:
29-
name: wheels-${{ runner.os }}
30-
path: wheelhouse/${{ runner.os }}/*.whl
27+
name: dist
28+
path: dist/*.whl
3129

3230
windows-test-amd64:
3331
name: Testing wheels for AMD64 windows
@@ -49,13 +47,18 @@ jobs:
4947
- name: Download artifacts
5048
uses: actions/download-artifact@v4
5149
with:
52-
name: wheels-${{ runner.os }}
53-
path: wheelhouse
50+
name: dist
51+
path: dist
52+
53+
- name: List files
54+
run: |
55+
dir
56+
dir dist
5457
5558
- name: Install python-snap7
5659
run: |
5760
python3 -m pip install --upgrade pip pytest
58-
python3 -m pip install $(ls wheelhouse/*.whl)
61+
python3 -m pip install $(ls dist/*.whl)
5962
6063
- name: Run pytest
6164
run: |

README.rst

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
About
22
=====
33

4-
This is a ctypes-based Python wrapper for snap7. Snap7 is an open-source,
5-
32/64 bit, multi-platform Ethernet communication suite for interfacing natively
4+
This is a Python wrapper for Snap7, an open-source, 32/64 bit, multi-platform Ethernet communication suite for interfacing natively
65
with Siemens S7 PLCs.
76

87
Python-snap7 is tested with Python 3.9+, on Windows, Linux and OS X.
@@ -13,9 +12,9 @@ The full documentation is available on `Read The Docs <https://python-snap7.read
1312
Installation
1413
============
1514

16-
If you are running Windows, Mac OS X or GNU/Linux on an Intel x64 or ARM 64 compatible platform you can use the binary wheel installation::
15+
If you are running Windows (amd64), Mac OS X (amd64/aarch64), GNU/Linux (amd64/arm64) or a compatible platform you can install the binary wheel using::
1716

1817
$ pip install python-snap7
1918

2019

21-
Otherwise, please read the `online installation documentation <https://python-snap7.readthedocs.io/en/latest/installation.html>`_.
20+
Otherwise, please follow the `online installation instructions <https://python-snap7.readthedocs.io/en/latest/installation.html>`_ to install python-snap7 from source.

0 commit comments

Comments
 (0)