Skip to content

Commit

Permalink
Remove support for Python v3.8
Browse files Browse the repository at this point in the history
  • Loading branch information
mondeja committed Nov 2, 2024
1 parent 549e8f8 commit 921228f
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 52 deletions.
69 changes: 22 additions & 47 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,68 +30,43 @@ jobs:
strategy:
fail-fast: false
matrix:
include:
- platform: ubuntu-latest
python-version: 3.8
py: py38
- platform: ubuntu-latest
python-version: 3.9
py: py39
- platform: ubuntu-latest
python-version: "3.10"
py: py310
- platform: ubuntu-latest
python-version: "3.11"
py: py311
- platform: ubuntu-latest
python-version: "3.12"
py: py312
- platform: macos-latest
python-version: 3.8
py: py38
- platform: macos-latest
python-version: 3.9
py: py39
- platform: macos-latest
python-version: "3.10"
py: py310
- platform: macos-latest
python-version: "3.11"
py: py311
- platform: macos-latest
python-version: "3.12"
py: py312
- platform: windows-latest
python-version: 3.8
py: py38
- platform: windows-latest
python-version: 3.9
py: py39
- platform: windows-latest
python-version: "3.10"
py: py310
- platform: windows-latest
python-version: "3.11"
py: py311
- platform: windows-latest
python-version: "3.12"
py: py312
py:
- 3.9
- "3.10"
- "3.11"
- "3.12"
- "3.13"
platform:
- ubuntu-latest
- macos-latest
- windows-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Pick environment to run
id: env
shell: python
run: |
import codecs, os, sys
env = f"py=py3{sys.version_info[1]}\n"
print(f"Picked {env.split('=')[1].strip()} for {sys.version}")
with codecs.open(os.environ["GITHUB_OUTPUT"], "a", "utf-8") as file_handler:
file_handler.write(env)
- name: Install Hatch
run: pip install -U hatch
- name: Run tests
run: hatch run +py=${{ matrix.py }} tests:all
run: hatch run +py=${{ steps.env.outputs.py }} tests:all
- name: Convert coverage to XML
run: |
pip install coverage covdefaults
coverage xml
- name: Upload coverage
uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}

build-dist:
if: startsWith(github.ref, 'refs/tags/')
Expand Down
9 changes: 4 additions & 5 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
[project]
name = "importlib-metadata-argparse-version"
version = "2.1.0"
version = "3.0.0"
description = "Argparse action to define CLI version with a delayed call to importlib.metadata"
readme = "README.md"
license = "BSD-3-Clause"
requires-python = ">=3.8"
requires-python = ">=3.9"
authors = [{ name = "Álvaro Mondéjar Rubio", email = "mondejar1994@gmail.com" }]
classifiers = [
"Development Status :: 5 - Production/Stable",
Expand All @@ -14,7 +14,6 @@ classifiers = [
"Topic :: Software Development :: Libraries",
"Programming Language :: Python",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
Expand Down Expand Up @@ -64,7 +63,7 @@ cov = [
]

[[tool.hatch.envs.tests.matrix]]
python = ["py38", "py39", "py310", "py311", "py312", "py313"]
python = ["py39", "py310", "py311", "py312", "py313"]

[tool.project-config]
cache = "2 days"
Expand All @@ -87,7 +86,7 @@ exclude_lines = [

[tool.ruff]
line-length = 80
target-version = "py38"
target-version = "py39"

[tool.ruff.lint]
select = [
Expand Down

0 comments on commit 921228f

Please # to comment.