-
-
Notifications
You must be signed in to change notification settings - Fork 246
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* add parameter type * move db module back to be more backwards compatible * small fixes * sync log code with client code * lets see if we can get the pypi test upload working again * improve the test situation * lets see if this recv is causing all trouble * trigger test pypi upload * switch to new workflow comaptible action container * use workflow file names * use dist as folder everywhere, at source tarball * flatten dist structure * fix artefact name * switch to manual trigger
- Loading branch information
1 parent
3752d51
commit fe1f2ca
Showing
38 changed files
with
992 additions
and
1,166 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
name: Doc | ||
name: Documentation | ||
on: | ||
push: | ||
branches: [master] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
name: Linux Test all Pythons with Debian packages | ||
name: Test with Debian packages | ||
on: | ||
push: | ||
branches: [master] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
name: OS X Test | ||
name: Test on macOS with brew | ||
on: | ||
push: | ||
branches: [master] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,12 @@ | ||
name: pre-commit | ||
name: Run pre-commit hook | ||
on: | ||
push: | ||
branches: [master] | ||
pull_request: | ||
branches: [master] | ||
jobs: | ||
pre-commit: | ||
runs-on: ubuntu-20.04 | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.9' | ||
- uses: pre-commit/[email protected] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
name: Publish distribution 📦 to PyPI | ||
|
||
on: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
publish-to-testpypi: | ||
environment: | ||
name: pypi | ||
url: https://pypi.org/p/python-snap7 | ||
|
||
permissions: | ||
id-token: write # IMPORTANT: mandatory for trusted publishing | ||
|
||
name: Publish distribution 📦 toPyPI | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: "Download macOS artifacts" | ||
uses: dawidd6/action-download-artifact@v6 | ||
with: | ||
workflow: osx-build-test-amd64.yml | ||
path: dist | ||
- name: "Download Linux/amd64 artifacts" | ||
uses: dawidd6/action-download-artifact@v6 | ||
with: | ||
workflow: osx-build-test-amd64.yml | ||
path: . | ||
- name: "Download Linux/arm64 artifacts" | ||
uses: dawidd6/action-download-artifact@v6 | ||
with: | ||
workflow: linux-build-test-arm64.yml | ||
path: . | ||
- name: "Download Windows artifacts" | ||
uses: dawidd6/action-download-artifact@v6 | ||
with: | ||
workflow: windows-build-test-amd64.yml | ||
path: . | ||
- name: "Download source artifacts" | ||
uses: dawidd6/action-download-artifact@v6 | ||
with: | ||
workflow: source-build.yml | ||
path: . | ||
- name: Combine artifacts | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
path: dist | ||
- name: show dist layout | ||
run: | | ||
ls -al | ||
ls -al dist | ||
find dist | ||
- name: Publish distribution 📦 to PyPI | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
test-pypi-packages: | ||
runs-on: ${{ matrix.os }} | ||
needs: publish-to-testpypi | ||
strategy: | ||
matrix: | ||
os: [ubuntu-24.04, ubuntu-22.04, ubuntu-20.04, macos-14, macos-12, windows-2022, windows-2019] | ||
python-version: ["3.9", "3.10", "3.11", "3.12"] | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: install python-snap7 | ||
run: | | ||
python3 -m venv venv | ||
venv/bin/pip install --upgrade pip | ||
venv/bin/pip install python-snap7[test] | ||
- name: Run pytest | ||
run: | | ||
venv/bin/pytest -m "server or util or client or mainloop" | ||
- name: Run tests required sudo on Linux and macOS | ||
if: ${{ runner.os == 'Linux' || runner.os == 'macOS'}} | ||
run: sudo venv/bin/pytest -m partner | ||
|
||
- name: On windows we don't need sudo | ||
if: ${{ runner.os == 'Windows'}} | ||
run: venv/bin/pytest -m partner |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
name: Publish distribution 📦 to Test PyPI | ||
|
||
on: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
publish-to-testpypi: | ||
environment: | ||
name: testpypi | ||
url: https://test.pypi.org/p/python-snap7 | ||
|
||
permissions: | ||
id-token: write # IMPORTANT: mandatory for trusted publishing | ||
|
||
name: Publish distribution 📦 to TestPyPI | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: "Download macOS artifacts" | ||
uses: dawidd6/action-download-artifact@v6 | ||
with: | ||
workflow: osx-build-test-amd64.yml | ||
path: dist | ||
- name: "Download Linux/amd64 artifacts" | ||
uses: dawidd6/action-download-artifact@v6 | ||
with: | ||
workflow: osx-build-test-amd64.yml | ||
path: . | ||
- name: "Download Linux/arm64 artifacts" | ||
uses: dawidd6/action-download-artifact@v6 | ||
with: | ||
workflow: linux-build-test-arm64.yml | ||
path: . | ||
- name: "Download Windows artifacts" | ||
uses: dawidd6/action-download-artifact@v6 | ||
with: | ||
workflow: windows-build-test-amd64.yml | ||
path: . | ||
- name: "Download source artifacts" | ||
uses: dawidd6/action-download-artifact@v6 | ||
with: | ||
workflow: source-build.yml | ||
path: . | ||
- name: Combine artifacts | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
path: dist | ||
- name: show dist layout | ||
run: | | ||
ls -al | ||
ls -al dist | ||
find dist | ||
- name: Publish distribution 📦 to TestPyPI | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
with: | ||
repository-url: https://test.pypi.org/legacy/ | ||
test-pypi-packages: | ||
runs-on: ${{ matrix.os }} | ||
needs: publish-to-testpypi | ||
strategy: | ||
matrix: | ||
os: [ubuntu-24.04, ubuntu-22.04, ubuntu-20.04, macos-14, macos-12, windows-2022, windows-2019] | ||
python-version: ["3.9", "3.10", "3.11", "3.12"] | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: install python-snap7 | ||
run: | | ||
python3 -m venv venv | ||
venv/bin/pip install --upgrade pip | ||
venv/bin/pip install -i https://test.pypi.org/simple/ python-snap7[test] | ||
- name: Run pytest | ||
run: | | ||
venv/bin/pytest -m "server or util or client or mainloop" | ||
- name: Run tests required sudo on Linux and macOS | ||
if: ${{ runner.os == 'Linux' || runner.os == 'macOS'}} | ||
run: sudo venv/bin/pytest -m partner | ||
|
||
- name: On windows we don't need sudo | ||
if: ${{ runner.os == 'Windows'}} | ||
run: venv/bin/pytest -m partner |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
name: Test with Debian packages | ||
on: | ||
push: | ||
branches: [master] | ||
pull_request: | ||
branches: [master] | ||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Install Debian packages | ||
run: | | ||
sudo apt-get update -qq | ||
sudo apt-get install -y python3 python3-pip | ||
- name: Install build tools | ||
run: | | ||
python3 -m venv venv | ||
venv/bin/pip install --upgrade pip wheel build setuptools | ||
- name: Create source tarball | ||
run: | | ||
venv/bin/python -m build . --sdist | ||
- name: Upload artifacts | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: dist | ||
path: dist/*.tar.gz |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
=========== | ||
development | ||
Development | ||
=========== | ||
|
||
Github | ||
|
Oops, something went wrong.