From d9a08ae1a9908d7de8091738c47e60c5620ad903 Mon Sep 17 00:00:00 2001 From: matosys Date: Thu, 16 Apr 2026 08:54:50 +0200 Subject: [PATCH 1/2] ci(.github): add github workflows for pylint and pypi publishing --- .github/workflows/pylint.yml | 24 ++++++++++++++++ .github/workflows/python-publish.yml | 43 ++++++++++++++++++++++++++++ 2 files changed, 67 insertions(+) create mode 100644 .github/workflows/pylint.yml create mode 100644 .github/workflows/python-publish.yml diff --git a/.github/workflows/pylint.yml b/.github/workflows/pylint.yml new file mode 100644 index 0000000..54731d8 --- /dev/null +++ b/.github/workflows/pylint.yml @@ -0,0 +1,24 @@ +name: Pylint + +on: [push] + +jobs: + build: + runs-on: ubuntu-latest + strategy: + matrix: + python-version: ["3.10", "3.11", "3.12", "3.13"] + steps: + - uses: actions/checkout@v3 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v3 + with: + python-version: ${{ matrix.python-version }} + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install -r requirements.txt + pip install pylint + - name: Analysing the code with pylint + run: | + export PYTHONPATH=$PYTHONPATH:$(readlink -f src) && pylint $(git ls-files 'src/*.py') diff --git a/.github/workflows/python-publish.yml b/.github/workflows/python-publish.yml new file mode 100644 index 0000000..302f3e8 --- /dev/null +++ b/.github/workflows/python-publish.yml @@ -0,0 +1,43 @@ +# This workflow will upload a Python Package using Twine when a release is created +# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python#publishing-to-package-registries + +# This workflow uses actions that are not certified by GitHub. +# They are provided by a third-party and are governed by +# separate terms of service, privacy policy, and support +# documentation. + +name: Upload Python Package + +on: + release: + types: [published] + +permissions: + contents: read + +jobs: + deploy: + name: upload release to PyPI + + runs-on: ubuntu-latest + + environment: pypi + permissions: + # IMPORTANT: this permission is mandatory for Trusted Publishing + id-token: write + + steps: + - uses: actions/checkout@v3 + - name: Set up Python + uses: actions/setup-python@v3 + with: + python-version: '3.10' + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install -r requirements.txt + pip install build + - name: Build package + run: python -m build + - name: Publish package + uses: pypa/gh-action-pypi-publish@release/v1 From ccfc33c72b2f40df7ee2691e26258d5f1d46981c Mon Sep 17 00:00:00 2001 From: matosys Date: Thu, 16 Apr 2026 08:59:32 +0200 Subject: [PATCH 2/2] ci(.pylint): add `fixme` to disabled list --- .pylintrc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.pylintrc b/.pylintrc index aef1289..ffbbaf6 100644 --- a/.pylintrc +++ b/.pylintrc @@ -420,7 +420,8 @@ disable=raw-checker-failed, consider-iterating-dictionary, missing-module-docstring, logging-fstring-interpolation, - duplicate-code + duplicate-code, + fixme # Enable the message, report, category or checker with the given id(s). You can # either give multiple identifier separated by comma (,) or put this option