From 73cc3a8d37369db5011364b00151cf78c6e1979b Mon Sep 17 00:00:00 2001 From: "Felipe N. Schuch" Date: Mon, 16 Dec 2024 20:24:52 -0300 Subject: [PATCH] Dropped support for Python 3.8 (#73) --- .github/workflows/ci.yaml | 9 ++------- pyproject.toml | 5 ++--- xcompact3d_toolbox/io.py | 5 ++++- 3 files changed, 8 insertions(+), 11 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index bd000fe..ba13394 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -26,12 +26,7 @@ jobs: fail-fast: false matrix: os: [ubuntu-latest, windows-latest, macos-latest] - python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"] - exclude: - - os: macos-latest - python-version: "3.8" - - os: windows-latest - python-version: "3.8" + python-version: ["3.9", "3.10", "3.11", "3.12"] runs-on: ${{ matrix.os }} steps: - uses: actions/checkout@v4 @@ -91,7 +86,7 @@ jobs: args: > -Dsonar.organization=fschuch -Dsonar.projectKey=fschuch_xcompact3d_toolbox - -Dsonar.python.version=3.8,3.9,3.10,3.11,3.12 + -Dsonar.python.version=3.9,3.10,3.11,3.12 -Dsonar.sources=xcompact3d_toolbox -Dsonar.tests=tests -Dsonar.python.coverage.reportPaths=coverage.*.xml diff --git a/pyproject.toml b/pyproject.toml index d3c8ce4..9d3e93e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -6,7 +6,7 @@ build-backend = "hatchling.build" name = "xcompact3d_toolbox" description = "A set of tools for pre and postprocessing prepared for the high-order Navier-Stokes solver XCompact3d" readme = "README.md" -requires-python = ">=3.8" +requires-python = ">=3.9" authors = [{ name = "Felipe N. Schuch", email = "me@fschuch.com" }] classifiers = [ "Development Status :: 5 - Production/Stable", @@ -15,7 +15,6 @@ classifiers = [ "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", - "Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.9", "Programming Language :: Python", "Topic :: Scientific/Engineering", @@ -146,7 +145,7 @@ extra-dependencies = ["pytest-randomly", "pytest-rerunfailures", "pytest-xdist"] extended = "test -n auto --reruns 7 --reruns-delay 1 {args}" [[tool.hatch.envs.test.matrix]] -python = ["3.8", "3.9", "3.10", "3.11", "3.12"] +python = ["3.9", "3.10", "3.11", "3.12"] [tool.hatch.envs.docs] description = "Documentation environment" diff --git a/xcompact3d_toolbox/io.py b/xcompact3d_toolbox/io.py index 2905cda..0472015 100644 --- a/xcompact3d_toolbox/io.py +++ b/xcompact3d_toolbox/io.py @@ -7,7 +7,10 @@ import os import os.path import warnings -from typing import Iterator +from typing import TYPE_CHECKING + +if TYPE_CHECKING: + from collections.abc import Iterator import numpy as np import pandas as pd