From 21739e6c446a459cae8f13aca3c54924b7102d16 Mon Sep 17 00:00:00 2001 From: Vlad Iftime Date: Wed, 30 Apr 2025 12:47:05 +0200 Subject: [PATCH 1/7] Fix for transition argument Signed-off-by: Vlad Iftime --- pytest.ini | 3 +++ src/s2python/generated/gen_s2.py | 1 + tests/unit/message_test.py | 3 +++ 3 files changed, 7 insertions(+) create mode 100644 pytest.ini diff --git a/pytest.ini b/pytest.ini new file mode 100644 index 0000000..4522608 --- /dev/null +++ b/pytest.ini @@ -0,0 +1,3 @@ +[pytest] +testpaths = tests +addopts = --cov=s2python --cov-report=html:./unit_test_coverage/ -v tests/unit/ diff --git a/src/s2python/generated/gen_s2.py b/src/s2python/generated/gen_s2.py index f09a9f6..22dd0f7 100644 --- a/src/s2python/generated/gen_s2.py +++ b/src/s2python/generated/gen_s2.py @@ -180,6 +180,7 @@ class NumberRange(BaseModel): class Transition(BaseModel): model_config = ConfigDict( extra="forbid", + populate_by_name=True ) id: ID = Field( ..., diff --git a/tests/unit/message_test.py b/tests/unit/message_test.py index f667306..954a738 100644 --- a/tests/unit/message_test.py +++ b/tests/unit/message_test.py @@ -61,3 +61,6 @@ def test_import_s2_messages__pebc(self): def test_import_s2_messages__ppbc(self): self._test_import_s2_messages("s2python.ppbc") + + def test_import_s2_messages__ombc(self): + self._test_import_s2_messages("s2python.ombc") From 825cf78f1b8350ae99ce68dec004b79e75fb2dfe Mon Sep 17 00:00:00 2001 From: Dr Maurice Hendrix Date: Thu, 1 May 2025 09:39:21 +0200 Subject: [PATCH 2/7] Update tests/unit/message_test.py --- tests/unit/message_test.py | 1 - 1 file changed, 1 deletion(-) diff --git a/tests/unit/message_test.py b/tests/unit/message_test.py index 954a738..1d3c4a9 100644 --- a/tests/unit/message_test.py +++ b/tests/unit/message_test.py @@ -61,6 +61,5 @@ def test_import_s2_messages__pebc(self): def test_import_s2_messages__ppbc(self): self._test_import_s2_messages("s2python.ppbc") - def test_import_s2_messages__ombc(self): self._test_import_s2_messages("s2python.ombc") From e907c325df885cf078afb685d9ec54aeab0face4 Mon Sep 17 00:00:00 2001 From: Dr Maurice Hendrix Date: Tue, 6 May 2025 09:43:54 +0200 Subject: [PATCH 3/7] Update ci.yml checking it's really a python 3.8 issue --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7ca3906..247adf9 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -57,7 +57,7 @@ jobs: strategy: matrix: python: - - "3.8" +# - "3.8" - "3.9" - "3.10" - "3.11" From 5e72267f9f18309dd51cb24279e4c55fba8708e1 Mon Sep 17 00:00:00 2001 From: Dr Maurice Hendrix Date: Tue, 6 May 2025 09:45:23 +0200 Subject: [PATCH 4/7] Update ci.yml checking if it's a 3.8 issue --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 247adf9..305f080 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -96,7 +96,7 @@ jobs: strategy: matrix: python: - - "3.8" +# - "3.8" - "3.9" - "3.10" - "3.11" @@ -125,7 +125,7 @@ jobs: strategy: matrix: python: - - "3.8" +# - "3.8" - "3.9" - "3.10" - "3.11" From 56762f89ba62a531d0c771bd11bfa6d3332da8b6 Mon Sep 17 00:00:00 2001 From: Dr Maurice Hendrix Date: Tue, 6 May 2025 09:57:40 +0200 Subject: [PATCH 5/7] Update ci.yml reanable 3.8 for tests --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 305f080..28fc8d7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -57,7 +57,7 @@ jobs: strategy: matrix: python: -# - "3.8" + - "3.8" - "3.9" - "3.10" - "3.11" From 2de0cc53040808d892a0a03c2d0e05999eb6daef Mon Sep 17 00:00:00 2001 From: Dr Maurice Hendrix Date: Tue, 6 May 2025 10:44:06 +0200 Subject: [PATCH 6/7] Update ci.yml testing if it's down to ubuntu version --- .github/workflows/ci.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 28fc8d7..c4e1d95 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -63,7 +63,8 @@ jobs: - "3.11" - "3.12" # newest Python that is stable platform: - - ubuntu-latest + - ubuntu-22.04 + # - ubuntu-latest # - macos-latest # - windows-latest runs-on: ${{ matrix.platform }} From d3ba0f6a80a93d697102aa3feed9b5c3c1a8a238 Mon Sep 17 00:00:00 2001 From: Dr Maurice Hendrix Date: Tue, 6 May 2025 15:17:39 +0200 Subject: [PATCH 7/7] dropping python 3.8 support (#117) * dropping python 3.8 adding 3.13 support --- .github/workflows/ci.yml | 22 ++++++++++------------ pyproject.toml | 4 ++-- 2 files changed, 12 insertions(+), 14 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c4e1d95..e55622e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -57,14 +57,13 @@ jobs: strategy: matrix: python: - - "3.8" - "3.9" - "3.10" - "3.11" - - "3.12" # newest Python that is stable + - "3.12" + - "3.13" # newest Python that is stable platform: - - ubuntu-22.04 - # - ubuntu-latest + - ubuntu-latest # - macos-latest # - windows-latest runs-on: ${{ matrix.platform }} @@ -80,8 +79,7 @@ jobs: - name: Run tests run: >- pipx run --python '${{ steps.setup-python.outputs.python-path }}' - tox --installpkg '${{ needs.prepare.outputs.wheel-distribution }}' - -- -rFEx --durations 10 --color yes # pytest args + tox --develop # - name: Generate coverage report # run: pipx run coverage lcov -o coverage.lcov # - name: Upload partial coverage report @@ -97,11 +95,11 @@ jobs: strategy: matrix: python: -# - "3.8" - "3.9" - "3.10" - "3.11" - - "3.12" # newest Python that is stable + - "3.12" + - "3.13" # newest Python that is stable platform: - ubuntu-latest # - macos-latest @@ -119,18 +117,18 @@ jobs: - name: Run tests run: >- pipx run --python '${{ steps.setup-python.outputs.python-path }}' - tox -e lint --installpkg '${{ needs.prepare.outputs.wheel-distribution }}' + tox -e lint --develop typecheck: needs: prepare strategy: matrix: python: -# - "3.8" - "3.9" - "3.10" - "3.11" - - "3.12" # newest Python that is stable + - "3.12" + - "3.13" # newest Python that is stable platform: - ubuntu-latest # - macos-latest @@ -148,7 +146,7 @@ jobs: - name: Run tests run: >- pipx run --python '${{ steps.setup-python.outputs.python-path }}' - tox -e typecheck --installpkg '${{ needs.prepare.outputs.wheel-distribution }}' + tox -e typecheck --develop finalize: needs: [test, lint, typecheck] diff --git a/pyproject.toml b/pyproject.toml index 85788e6..35d8840 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -12,7 +12,7 @@ version = "0.5.0" readme = "README.rst" license = "Apache-2.0" license-files = ["LICENSE"] -requires-python = ">=3.8, < 3.13" +requires-python = ">=3.9, < 3.14" dependencies = [ "pydantic>=2.8.2", "pytz", @@ -20,11 +20,11 @@ dependencies = [ ] classifiers = [ "Development Status :: 4 - Beta", - "Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", + "Programming Language :: Python :: 3.13", ] [project.urls] "Source code" = "https://github.com/flexiblepower/s2-ws-json-python"