labnode-async 0.16.3__tar.gz → 1.0.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (65) hide show
  1. labnode_async-1.0.0/.github/dependabot.yml +33 -0
  2. labnode_async-1.0.0/.github/workflows/code-coverage-comment.yml +38 -0
  3. labnode_async-1.0.0/.github/workflows/code-coverage.yml +69 -0
  4. labnode_async-1.0.0/.github/workflows/documentation.yml +67 -0
  5. labnode_async-1.0.0/.github/workflows/pre-commit.yml +42 -0
  6. labnode_async-1.0.0/.github/workflows/publish-pypi.yml +38 -0
  7. labnode_async-1.0.0/.github/workflows/publish-test-pypi.yml +42 -0
  8. labnode_async-1.0.0/.github/workflows/pylint.yml +43 -0
  9. labnode_async-1.0.0/.github/workflows/tests.yml +80 -0
  10. labnode_async-1.0.0/.github/workflows/zizmor.yml +41 -0
  11. labnode_async-1.0.0/.github/zizmor.yml +14 -0
  12. labnode_async-1.0.0/.gitignore +104 -0
  13. labnode_async-1.0.0/.pre-commit-config.yaml +43 -0
  14. {labnode_async-0.16.3 → labnode_async-1.0.0}/PKG-INFO +33 -17
  15. {labnode_async-0.16.3 → labnode_async-1.0.0}/README.md +11 -0
  16. labnode_async-1.0.0/doc/Makefile +20 -0
  17. labnode_async-1.0.0/doc/source/conf.py +63 -0
  18. labnode_async-1.0.0/doc/source/examples.rst +17 -0
  19. labnode_async-1.0.0/doc/source/index.rst +24 -0
  20. labnode_async-1.0.0/doc/source/modules.rst +32 -0
  21. labnode_async-1.0.0/doc/source/readme.rst +5 -0
  22. labnode_async-1.0.0/examples/pid.py +124 -0
  23. labnode_async-1.0.0/examples/simple.py +23 -0
  24. labnode_async-1.0.0/labnode_async/_version.py +24 -0
  25. {labnode_async-0.16.3 → labnode_async-1.0.0}/labnode_async/connection.py +128 -25
  26. {labnode_async-0.16.3 → labnode_async-1.0.0}/labnode_async/device_factory.py +1 -0
  27. {labnode_async-0.16.3 → labnode_async-1.0.0}/labnode_async/devices.py +1 -0
  28. labnode_async-1.0.0/labnode_async/ip_connection.py +211 -0
  29. {labnode_async-0.16.3 → labnode_async-1.0.0}/labnode_async/labnode.py +1 -0
  30. {labnode_async-0.16.3 → labnode_async-1.0.0}/labnode_async/pid_controller.py +12 -11
  31. labnode_async-1.0.0/labnode_async/py.typed +0 -0
  32. {labnode_async-0.16.3 → labnode_async-1.0.0}/labnode_async/serial_connection.py +3 -1
  33. {labnode_async-0.16.3 → labnode_async-1.0.0}/labnode_async.egg-info/PKG-INFO +33 -17
  34. labnode_async-1.0.0/labnode_async.egg-info/SOURCES.txt +60 -0
  35. {labnode_async-0.16.3 → labnode_async-1.0.0}/labnode_async.egg-info/requires.txt +14 -9
  36. labnode_async-1.0.0/labnode_async.egg-info/scm_file_list.json +56 -0
  37. labnode_async-1.0.0/labnode_async.egg-info/scm_version.json +8 -0
  38. {labnode_async-0.16.3 → labnode_async-1.0.0}/pyproject.toml +43 -14
  39. labnode_async-1.0.0/requirements-workflows.txt +2 -0
  40. {labnode_async-0.16.3 → labnode_async-1.0.0}/setup.py +0 -1
  41. labnode_async-1.0.0/tests/__init__.py +0 -0
  42. labnode_async-1.0.0/tests/fake_labnode.py +108 -0
  43. labnode_async-1.0.0/tests/test_closing_the_transport.py +93 -0
  44. labnode_async-1.0.0/tests/test_connecting.py +44 -0
  45. labnode_async-1.0.0/tests/test_connection.py +148 -0
  46. labnode_async-1.0.0/tests/test_context_manager.py +44 -0
  47. labnode_async-1.0.0/tests/test_device_factory.py +28 -0
  48. labnode_async-1.0.0/tests/test_invalid_replies.py +44 -0
  49. labnode_async-1.0.0/tests/test_ip_connection.py +386 -0
  50. labnode_async-1.0.0/tests/test_lost_connection.py +69 -0
  51. labnode_async-1.0.0/tests/test_oversized_packet.py +34 -0
  52. labnode_async-1.0.0/tests/test_pid_controller.py +340 -0
  53. labnode_async-1.0.0/tests/test_pid_invalid_format.py +45 -0
  54. labnode_async-1.0.0/tests/test_request_data.py +31 -0
  55. labnode_async-1.0.0/tests/test_request_ids.py +32 -0
  56. labnode_async-1.0.0/tests/test_serial_connection.py +65 -0
  57. labnode_async-0.16.3/labnode_async/_version.py +0 -2
  58. labnode_async-0.16.3/labnode_async/ip_connection.py +0 -107
  59. labnode_async-0.16.3/labnode_async.egg-info/SOURCES.txt +0 -19
  60. {labnode_async-0.16.3 → labnode_async-1.0.0}/LICENSE +0 -0
  61. {labnode_async-0.16.3 → labnode_async-1.0.0}/labnode_async/__init__.py +0 -0
  62. {labnode_async-0.16.3 → labnode_async-1.0.0}/labnode_async/errors.py +0 -0
  63. {labnode_async-0.16.3 → labnode_async-1.0.0}/labnode_async.egg-info/dependency_links.txt +0 -0
  64. {labnode_async-0.16.3 → labnode_async-1.0.0}/labnode_async.egg-info/top_level.txt +0 -0
  65. {labnode_async-0.16.3 → labnode_async-1.0.0}/setup.cfg +0 -0
@@ -0,0 +1,33 @@
1
+ version: 2
2
+ updates:
3
+ - package-ecosystem: "github-actions"
4
+ # Workflow files stored in the
5
+ # default location of `.github/workflows`
6
+ directory: "/"
7
+ schedule:
8
+ interval: "daily"
9
+ commit-message:
10
+ # Prefix all commit messages with "[gha] "
11
+ prefix: "[gha] "
12
+
13
+ - package-ecosystem: "pip"
14
+ directory: "/"
15
+ schedule:
16
+ interval: "daily"
17
+ commit-message:
18
+ # Prefix all commit messages with "[pip] "
19
+ prefix: "[pip] "
20
+
21
+ - package-ecosystem: "pre-commit"
22
+ # Reads .pre-commit-config.yaml and bumps each hook's `rev`
23
+ directory: "/"
24
+ schedule:
25
+ interval: "weekly"
26
+ commit-message:
27
+ # Prefix all commit messages with "[pre-commit] "
28
+ prefix: "[pre-commit] "
29
+ groups:
30
+ # One PR for all hook updates instead of one per hook
31
+ pre-commit-hooks:
32
+ patterns:
33
+ - "*"
@@ -0,0 +1,38 @@
1
+ name: Post coverage comment
2
+
3
+ # Pull requests from forks and from Dependabot have no write access, so the workflow "Code Coverage" cannot comment on
4
+ # them. This workflow runs in the context of the repository after it has finished, and posts the comment, which the
5
+ # other workflow has stored as an artifact.
6
+ on: # zizmor: ignore[dangerous-triggers] The code of the pull request is neither checked out nor executed. The only data that is used is the text of the comment in the artifact, which is posted as it is.
7
+ workflow_run:
8
+ workflows: ["Code Coverage"]
9
+ types:
10
+ - completed
11
+
12
+ concurrency:
13
+ # Group by the branch of the pull request, so that the runs for different pull requests do not cancel each other.
14
+ # `github.ref` is always the default branch on `workflow_run`.
15
+ group: ${{ github.workflow }}-${{ github.event.workflow_run.head_branch }}
16
+ cancel-in-progress: true
17
+
18
+ permissions: {}
19
+
20
+ jobs:
21
+ comment:
22
+ name: Post the coverage comment
23
+ runs-on: ubuntu-latest
24
+ timeout-minutes: 5
25
+ if: github.event.workflow_run.event == 'pull_request' && github.event.workflow_run.conclusion == 'success'
26
+ permissions:
27
+ pull-requests: write # Post the comment, and edit it on later runs
28
+ actions: read # Download the comment artifact of the triggering run
29
+ contents: read
30
+
31
+ steps:
32
+ # DO NOT run actions/checkout here, for security reasons. For details, refer to
33
+ # https://securitylab.github.com/research/github-actions-preventing-pwn-requests/
34
+ - name: Post comment
35
+ uses: py-cov-action/python-coverage-comment-action@281cb0dcb5b15d4773037d51873558fddc5a7df8 # v4.7
36
+ with:
37
+ GITHUB_TOKEN: ${{ github.token }}
38
+ GITHUB_PR_RUN_ID: ${{ github.event.workflow_run.id }}
@@ -0,0 +1,69 @@
1
+ name: Code Coverage
2
+
3
+ # Run on pushes to the default branch (to establish the baseline) and on pull requests (to compare against it).
4
+ on:
5
+ push:
6
+ branches: [ "master" ]
7
+ pull_request:
8
+ branches: [ "master" ]
9
+
10
+ # A new push to a pull request makes the running tests obsolete. Never cancel the run on the default branch, it saves the
11
+ # coverage of the commit, which is the baseline of the pull requests.
12
+ concurrency:
13
+ group: ${{ github.workflow }}-${{ github.ref }}
14
+ cancel-in-progress: ${{ github.event_name == 'pull_request' }}
15
+
16
+ # The jobs ask for the permissions they need
17
+ permissions: {}
18
+
19
+ jobs:
20
+ coverage:
21
+ name: Measure the coverage and comment on the pull request
22
+ runs-on: ubuntu-latest
23
+ timeout-minutes: 15
24
+ permissions:
25
+ # The permissions are downgraded to read-only by GitHub for pull requests from forks and by Dependabot, so they
26
+ # do not grant write access to untrusted code. The comment of these pull requests is posted by the workflow
27
+ # "Post coverage comment".
28
+ pull-requests: write # Post the coverage comment on the pull request, and edit it on later runs
29
+ contents: write # Push the coverage data of the default branch to the branch python-coverage-comment-action-data
30
+
31
+ steps:
32
+ - name: Checkout source repository
33
+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
34
+ with:
35
+ persist-credentials: false
36
+ - name: Set up python
37
+ uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
38
+ with:
39
+ python-version: "3.15"
40
+ cache: pip
41
+ cache-dependency-path: pyproject.toml
42
+ # The library has no requirements.txt, the dependencies are defined in pyproject.toml. Install the library in
43
+ # editable mode, so the coverage is measured for the files of the checkout and not for a copy in site-packages.
44
+ - name: Install dependencies for testing
45
+ run: |
46
+ python3 -m pip install --upgrade pip
47
+ python3 -m pip install --editable ".[test]"
48
+ # This creates the file .coverage. The settings (branch coverage, relative paths, source) are in the
49
+ # [tool.coverage] sections of pyproject.toml
50
+ - name: Run tests with coverage
51
+ run: pytest --cov --cov-report=term-missing
52
+
53
+ # Comment on pull requests, and save the coverage of the default branch. Everything runs on GitHub, no data is sent
54
+ # to another service.
55
+ - name: Coverage comment
56
+ id: coverage_comment
57
+ uses: py-cov-action/python-coverage-comment-action@281cb0dcb5b15d4773037d51873558fddc5a7df8 # v4.7
58
+ with:
59
+ GITHUB_TOKEN: ${{ github.token }}
60
+
61
+ # Pull requests from forks cannot post the comment, so hand it over to the workflow "Post coverage comment"
62
+ - name: Store the pull request comment to be posted
63
+ if: steps.coverage_comment.outputs.COMMENT_FILE_WRITTEN == 'true'
64
+ uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
65
+ with:
66
+ # If you use a different name, update COMMENT_ARTIFACT_NAME in the other workflow accordingly
67
+ name: python-coverage-comment-action
68
+ # If you use a different name, update COMMENT_FILENAME in the other workflow accordingly
69
+ path: python-coverage-comment-action.txt
@@ -0,0 +1,67 @@
1
+ name: Build Documentation and push to gh-pages
2
+
3
+ on:
4
+ push:
5
+ branches: [ "master" ]
6
+
7
+ permissions: {}
8
+
9
+ concurrency:
10
+ group: ${{ github.workflow }}-${{ github.ref }}
11
+ # Do not cancel a run while it may be pushing to gh-pages
12
+ cancel-in-progress: false
13
+
14
+ jobs:
15
+ build-documentation:
16
+ name: Build and publish the documentation
17
+ runs-on: ubuntu-latest
18
+ permissions:
19
+ # Required to push to the gh-pages branch
20
+ contents: write
21
+
22
+ steps:
23
+ - name: Checkout source repository
24
+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
25
+ with:
26
+ path: master
27
+ persist-credentials: false
28
+ # setuptools-scm derives the version shown in the documentation from the git tags, so fetch them all
29
+ fetch-depth: 0
30
+ - name: Checkout gh-pages repository
31
+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
32
+ with:
33
+ ref: gh-pages
34
+ path: gh-pages
35
+ # The credentials are needed to push the documentation in the last step
36
+ persist-credentials: true # zizmor: ignore[artipacked]
37
+ - name: Set up python
38
+ uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
39
+ with:
40
+ python-version: "3.15"
41
+ cache: pip
42
+ cache-dependency-path: master/pyproject.toml
43
+ - name: Install dependencies for the documentation
44
+ working-directory: master
45
+ run: |
46
+ python3 -m pip install --upgrade pip
47
+ python3 -m pip install .[doc]
48
+ - name: Build documentation
49
+ working-directory: master/doc
50
+ run: |
51
+ make html
52
+ - name: Commit documentation changes
53
+ run: |
54
+ cp -r master/doc/build/html/* gh-pages/
55
+ cd gh-pages
56
+ # We need to disable Jekyll, because gh-pages does not copy files/folders with underscores:
57
+ # https://github.blog/2009-12-29-bypassing-jekyll-on-github-pages/
58
+ touch .nojekyll
59
+ git config user.name github-actions
60
+ git config user.email github-actions@github.com
61
+ git add .
62
+ # git commit returns an error if there are no updates, but this is ok
63
+ git commit -m "Update documentation" -a || true
64
+ - name: Push documentation changes
65
+ working-directory: gh-pages
66
+ run: |
67
+ git push
@@ -0,0 +1,42 @@
1
+ name: pre-commit
2
+
3
+ on:
4
+ push:
5
+ branches: [ "master" ]
6
+ pull_request:
7
+
8
+ permissions: {}
9
+
10
+ concurrency:
11
+ group: ${{ github.workflow }}-${{ github.ref }}
12
+ cancel-in-progress: ${{ github.event_name == 'pull_request' }}
13
+
14
+ jobs:
15
+ pre-commit:
16
+ runs-on: ubuntu-latest
17
+ permissions:
18
+ contents: read
19
+
20
+ steps:
21
+ - name: Checkout source repository
22
+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
23
+ with:
24
+ persist-credentials: false
25
+ - name: Set up python
26
+ uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
27
+ with:
28
+ python-version: "3.15"
29
+ cache: pip
30
+ cache-dependency-path: pyproject.toml
31
+ - name: Install dependencies for linting
32
+ run: |
33
+ python3 -m pip install --upgrade pip
34
+ python3 -m pip install .[lint]
35
+ - name: Cache the pre-commit environments
36
+ uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
37
+ with:
38
+ path: ~/.cache/pre-commit
39
+ key: pre-commit-${{ runner.os }}-${{ hashFiles('.pre-commit-config.yaml') }}
40
+ - name: Run pre-commit
41
+ run: |
42
+ pre-commit run --all-files --show-diff-on-failure --color=always
@@ -0,0 +1,38 @@
1
+ name: Upload to pypi.org
2
+
3
+ on:
4
+ # Triggers the workflow when a release is created
5
+ release:
6
+ types: [ published ]
7
+
8
+ workflow_dispatch:
9
+
10
+ permissions: {}
11
+
12
+ jobs:
13
+ tests:
14
+ name: Test and build
15
+ uses: ./.github/workflows/tests.yml
16
+ permissions:
17
+ contents: read
18
+
19
+ upload:
20
+ name: Upload to PyPI
21
+ needs:
22
+ - tests
23
+ # The version comes from the git tag. Run from a branch, it would be a development version like 0.16.5.dev3, which
24
+ # does not belong on PyPI.
25
+ if: github.ref_type == 'tag'
26
+ runs-on: ubuntu-latest
27
+ permissions: {}
28
+
29
+ steps:
30
+ - name: Download the tested distribution
31
+ uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8.0.2
32
+ with:
33
+ name: dist
34
+ path: dist/
35
+ - name: Upload to PyPI
36
+ uses: pypa/gh-action-pypi-publish@7245906fb61fa33a13554f9d5fb856fe61758086 # v1.14.3
37
+ with:
38
+ password: ${{ secrets.TWINE_TOKEN }}
@@ -0,0 +1,42 @@
1
+ name: Upload to test.pypi.org
2
+
3
+ on:
4
+ # Triggers the workflow on push to the master branch
5
+ push:
6
+ branches: [ "master" ]
7
+
8
+ workflow_dispatch:
9
+
10
+ permissions: {}
11
+
12
+ concurrency:
13
+ group: ${{ github.workflow }}-${{ github.ref }}
14
+ cancel-in-progress: false
15
+
16
+ jobs:
17
+ tests:
18
+ name: Test and build
19
+ uses: ./.github/workflows/tests.yml
20
+ permissions:
21
+ contents: read
22
+
23
+ upload:
24
+ name: Upload to TestPyPI
25
+ needs:
26
+ - tests
27
+ runs-on: ubuntu-latest
28
+ permissions: {}
29
+
30
+ steps:
31
+ - name: Download the tested distribution
32
+ uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8.0.2
33
+ with:
34
+ name: dist
35
+ path: dist/
36
+ - name: Upload to TestPyPI
37
+ uses: pypa/gh-action-pypi-publish@7245906fb61fa33a13554f9d5fb856fe61758086 # v1.14.3
38
+ with:
39
+ password: ${{ secrets.TWINE_TEST_TOKEN }}
40
+ repository-url: https://test.pypi.org/legacy/
41
+ # Each commit gets its own development version. This only skips the upload when a run is repeated.
42
+ skip-existing: true
@@ -0,0 +1,43 @@
1
+ name: pylint
2
+
3
+ on:
4
+ push:
5
+ branches: [ "master" ]
6
+ pull_request:
7
+
8
+ permissions: {}
9
+
10
+ concurrency:
11
+ group: ${{ github.workflow }}-${{ github.ref }}
12
+ cancel-in-progress: ${{ github.event_name == 'pull_request' }}
13
+
14
+ jobs:
15
+ build:
16
+ name: Run pylint (Python ${{ matrix.python-version }})
17
+ runs-on: ubuntu-latest
18
+ permissions:
19
+ contents: read
20
+
21
+ strategy:
22
+ fail-fast: false
23
+ matrix:
24
+ python-version: [ "3.10", "3.11", "3.12", "3.13", "3.14", "3.15" ]
25
+
26
+ steps:
27
+ - name: Checkout source repository
28
+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
29
+ with:
30
+ persist-credentials: false
31
+ - name: Set up python ${{ matrix.python-version }}
32
+ uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
33
+ with:
34
+ python-version: ${{ matrix.python-version }}
35
+ cache: pip
36
+ cache-dependency-path: pyproject.toml
37
+ - name: Install dependencies for linting
38
+ run: |
39
+ python3 -m pip install --upgrade pip
40
+ python3 -m pip install .[lint]
41
+ - name: Run pylint
42
+ run: |
43
+ pylint --reports n labnode_async examples tests
@@ -0,0 +1,80 @@
1
+ name: tests
2
+
3
+ on:
4
+ push:
5
+ branches: [ "master" ]
6
+ pull_request:
7
+ # Called by the publish workflows, so that only tested packages are uploaded
8
+ workflow_call:
9
+
10
+ permissions: {}
11
+
12
+ concurrency:
13
+ group: ${{ github.workflow }}-tests-${{ github.ref }}
14
+ cancel-in-progress: ${{ github.event_name == 'pull_request' }}
15
+
16
+ jobs:
17
+ tests:
18
+ name: Run tests (Python ${{ matrix.python-version }})
19
+ runs-on: ubuntu-latest
20
+ permissions:
21
+ contents: read
22
+
23
+ strategy:
24
+ fail-fast: false
25
+ matrix:
26
+ python-version: [ "3.10", "3.11", "3.12", "3.13", "3.14", "3.15" ]
27
+
28
+ steps:
29
+ - name: Checkout source repository
30
+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
31
+ with:
32
+ persist-credentials: false
33
+ - name: Set up python ${{ matrix.python-version }}
34
+ uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
35
+ with:
36
+ python-version: ${{ matrix.python-version }}
37
+ cache: pip
38
+ cache-dependency-path: pyproject.toml
39
+ - name: Install dependencies for testing
40
+ run: |
41
+ python3 -m pip install --upgrade pip
42
+ python3 -m pip install .[test]
43
+ - name: Test with pytest
44
+ run: |
45
+ # Fails, if the coverage is below the limit set in pyproject.toml
46
+ python3 -m pytest --verbose --cov
47
+
48
+ build:
49
+ name: Build distribution
50
+ runs-on: ubuntu-latest
51
+ permissions:
52
+ contents: read
53
+
54
+ steps:
55
+ - name: Checkout source repository
56
+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
57
+ with:
58
+ persist-credentials: false
59
+ # setuptools-scm derives the version from the git tags, so fetch the full history with all tags
60
+ fetch-depth: 0
61
+ - name: Set up python
62
+ uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
63
+ with:
64
+ python-version: "3.15"
65
+ - name: Install the build dependencies
66
+ run: |
67
+ python3 -m pip install --upgrade pip
68
+ python3 -m pip install .[build]
69
+ - name: Build and check the distribution
70
+ run: |
71
+ python3 -m build
72
+ python3 -m twine check --strict dist/*
73
+ ls dist/
74
+ - name: Store the distribution
75
+ uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
76
+ with:
77
+ name: dist
78
+ path: dist/
79
+ if-no-files-found: error
80
+ retention-days: 7
@@ -0,0 +1,41 @@
1
+ # Audits the GitHub workflows for security issues, such as actions that are not pinned to a commit SHA
2
+ name: zizmor
3
+
4
+ on:
5
+ push:
6
+ branches: [ "master" ]
7
+ paths: [ ".github/**", "requirements-workflows.txt" ]
8
+ pull_request:
9
+ paths: [ ".github/**", "requirements-workflows.txt" ]
10
+
11
+ permissions: {}
12
+
13
+ concurrency:
14
+ group: ${{ github.workflow }}-${{ github.ref }}
15
+ cancel-in-progress: ${{ github.event_name == 'pull_request' }}
16
+
17
+ jobs:
18
+ zizmor:
19
+ name: Audit the workflows
20
+ runs-on: ubuntu-latest
21
+ permissions:
22
+ contents: read
23
+
24
+ steps:
25
+ - name: Checkout source repository
26
+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
27
+ with:
28
+ persist-credentials: false
29
+ - name: Set up python
30
+ uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
31
+ with:
32
+ python-version: "3.15"
33
+ cache: pip
34
+ cache-dependency-path: requirements-workflows.txt
35
+ - name: Install zizmor
36
+ run: |
37
+ python3 -m pip install --upgrade pip
38
+ python3 -m pip install -r requirements-workflows.txt
39
+ - name: Run zizmor
40
+ run: |
41
+ zizmor --format=github --offline .
@@ -0,0 +1,14 @@
1
+ # Configuration for zizmor, see https://docs.zizmor.sh/configuration/
2
+ rules:
3
+ # The "$/" self-repository syntax is new (July 2026) and not yet understood by tools like actionlint.
4
+ # Keep using "./" for the local reusable workflow.
5
+ self-repository:
6
+ disable: true
7
+ # Uploads still authenticate with API tokens. Remove this once Trusted Publishing is configured on PyPI and TestPyPI.
8
+ use-trusted-publishing:
9
+ ignore:
10
+ - publish-pypi.yml
11
+ - publish-test-pypi.yml
12
+ # Use Dependabot's default cooldown instead of an explicit one.
13
+ dependabot-cooldown:
14
+ disable: true
@@ -0,0 +1,104 @@
1
+ # Byte-compiled / optimized / DLL files
2
+ __pycache__/
3
+ *.py[cod]
4
+ *$py.class
5
+
6
+ # C extensions
7
+ *.so
8
+
9
+ # Distribution / packaging
10
+ .Python
11
+ env/
12
+ build/
13
+ develop-eggs/
14
+ dist/
15
+ downloads/
16
+ eggs/
17
+ .eggs/
18
+ lib/
19
+ lib64/
20
+ parts/
21
+ sdist/
22
+ var/
23
+ wheels/
24
+ *.egg-info/
25
+ .installed.cfg
26
+ *.egg
27
+
28
+ # PyInstaller
29
+ # Usually these files are written by a python script from a template
30
+ # before PyInstaller builds the exe, so as to inject date/other infos into it.
31
+ *.manifest
32
+ *.spec
33
+
34
+ # Installer logs
35
+ pip-log.txt
36
+ pip-delete-this-directory.txt
37
+
38
+ # Unit test / coverage reports
39
+ htmlcov/
40
+ .tox/
41
+ .coverage
42
+ .coverage.*
43
+ .cache
44
+ nosetests.xml
45
+ coverage.xml
46
+ *.cover
47
+ .hypothesis/
48
+
49
+ # Translations
50
+ *.mo
51
+ *.pot
52
+
53
+ # Django stuff:
54
+ *.log
55
+ local_settings.py
56
+
57
+ # Flask stuff:
58
+ instance/
59
+ .webassets-cache
60
+
61
+ # Scrapy stuff:
62
+ .scrapy
63
+
64
+ # Sphinx documentation
65
+ docs/_build/
66
+
67
+ # PyBuilder
68
+ target/
69
+
70
+ # Jupyter Notebook
71
+ .ipynb_checkpoints
72
+
73
+ # pyenv
74
+ .python-version
75
+
76
+ # celery beat schedule file
77
+ celerybeat-schedule
78
+
79
+ # SageMath parsed files
80
+ *.sage.py
81
+
82
+ # dotenv
83
+ .env
84
+
85
+ # virtualenv
86
+ .venv
87
+ venv/
88
+ ENV/
89
+
90
+ # Spyder project settings
91
+ .spyderproject
92
+ .spyproject
93
+
94
+ # Rope project settings
95
+ .ropeproject
96
+
97
+ # mkdocs documentation
98
+ /site
99
+
100
+ # mypy
101
+ .mypy_cache/
102
+
103
+ # Generated by setuptools-scm
104
+ labnode_async/_version.py
@@ -0,0 +1,43 @@
1
+ # See https://pre-commit.com for more information
2
+ # See https://pre-commit.com/hooks.html for more hooks
3
+ repos:
4
+ - repo: https://github.com/pre-commit/pre-commit-hooks
5
+ rev: 3e8a8703264a2f4a69428a0aa4dcb512790b2c8c # frozen: v6.0.0
6
+ hooks:
7
+ - id: check-executables-have-shebangs
8
+ # Check for invalid files
9
+ - id: check-toml
10
+ # Check Python files
11
+ - id: end-of-file-fixer
12
+ - id: mixed-line-ending
13
+ args: [ --fix=lf ]
14
+ - id: check-executables-have-shebangs
15
+ - id: requirements-txt-fixer
16
+ - id: trailing-whitespace
17
+ args: [ --markdown-linebreak-ext=md ]
18
+ - repo: https://github.com/psf/black
19
+ rev: 258e7dbf348bc23cb70b8cdf693481c04634ebcc # frozen: 26.10.1
20
+ hooks:
21
+ - id: black
22
+ args: ['labnode_async']
23
+ - repo: https://github.com/asottile/blacken-docs
24
+ rev: a4325452c78e8296e792485f8d447ead5d9f8f09 # frozen: 1.21.0
25
+ hooks:
26
+ - id: blacken-docs
27
+ args: [ --line-length=120 ]
28
+ - repo: https://github.com/PyCQA/isort
29
+ rev: 9f905615631c545f5aea2516508109350d1d2f7d # frozen: 9.0.2
30
+ hooks:
31
+ - id: isort
32
+ - repo: local
33
+ hooks:
34
+ - id: pylint
35
+ name: pylint
36
+ entry: pylint
37
+ language: system
38
+ types: [ python ]
39
+ require_serial: true
40
+ - repo: https://github.com/pre-commit/mirrors-mypy
41
+ rev: ad26ebfa797fcb9b8f83275937c1c1d6e126719c # frozen: v2.4.1
42
+ hooks:
43
+ - id: mypy