Skip to content

Commit

Permalink
Drop support for Python 3.8
Browse files Browse the repository at this point in the history
  • Loading branch information
jacebrowning committed Feb 22, 2025
1 parent 1d7b5e8 commit 787a208
Show file tree
Hide file tree
Showing 10 changed files with 395 additions and 186 deletions.
3 changes: 1 addition & 2 deletions .appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ image: Visual Studio 2022
environment:
matrix:
- PYTHON_MAJOR: 3
PYTHON_MINOR: 8
PYTHON_MINOR: 9

cache:
- .venv -> poetry.lock
Expand All @@ -18,7 +18,6 @@ install:
- set PATH=C:\Python%PYTHON_MAJOR%%PYTHON_MINOR%\Scripts;%PATH%
# Install system dependencies
- choco install make
- set POETRY_VERSION=1.8.5
- curl -sSL https://install.python-poetry.org | python -
- set PATH=%USERPROFILE%\AppData\Roaming\Python\Scripts;%PATH%
- make doctor
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.8', '3.9', '3.10', '3.11']
python-version: ['3.9', '3.10', '3.11', '3.12', '3.13']

steps:
- uses: actions/checkout@v2
Expand All @@ -19,7 +19,7 @@ jobs:
python-version: ${{ matrix.python-version }}

- name: Install Poetry
run: curl -sSL https://install.python-poetry.org | POETRY_VERSION=1.8.5 python3 -
run: curl -sSL https://install.python-poetry.org | python3 -

- name: Check dependencies
run: make doctor
Expand Down
4 changes: 2 additions & 2 deletions .tool-versions
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
python 3.11.5
poetry 1.8.5
python 3.13.2
poetry 2.0.1
2 changes: 1 addition & 1 deletion .verchew.ini
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ version = 3
[Poetry]

cli = poetry
version = 1
version = 2

[Graphviz]

Expand Down
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Release Notes

## 3.0.0 (2025-02-23)

- Dropped support for Python 3.8.
- Added support for Python 3.12 and 3.13.

## 2.3.1 (2025-02-11)

- Removed unnecessary `eval()` call to map annotations to types.
Expand Down
28 changes: 14 additions & 14 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ MODULES := $(wildcard $(PACKAGE)/*.py)
all: doctor format check test mkdocs ## Run all tasks that determine CI status

.PHONY: dev
dev: install ## Continuously run all CI tasks when files chanage
dev: install ## Continuously run all CI tasks when files change
poetry run ptw

.PHONY: shell
Expand All @@ -24,12 +24,12 @@ demo: install
.PHONY: bootstrap
bootstrap: ## Attempt to install system dependencies
asdf plugin add python || asdf plugin update python
asdf plugin add poetry https://github.com/asdf-community/asdf-poetry.git || asdf plugin update poetry
asdf plugin add poetry || asdf plugin update poetry
asdf install

.PHONY: doctor
doctor: ## Confirm system dependencies are available
bin/verchew
bin/verchew --exit-code

# PROJECT DEPENDENCIES ########################################################

Expand All @@ -47,7 +47,7 @@ $(DEPENDENCIES): poetry.lock

ifndef CI
poetry.lock: pyproject.toml
poetry lock --no-update
poetry lock
@ touch $@
endif

Expand All @@ -63,7 +63,7 @@ format: install
@ echo

.PHONY: check
check: install format ## Run formaters, linters, and static analysis
check: install format ## Run formatters, linters, and static analysis
ifdef CI
git diff --exit-code
endif
Expand All @@ -74,7 +74,7 @@ endif
# TESTS #######################################################################

.PHONY: test
test: install ## Run unit and integration tests
test: install ## Run unit and integration tests
poetry run pytest --random
poetry run coveragespace update overall

Expand All @@ -91,7 +91,7 @@ test-profile: install
MKDOCS_INDEX := site/index.html

.PHONY: docs
docs: mkdocs uml notebooks ## Generate documentation and UML
docs: mkdocs uml notebooks ## Generate documentation and UML

.PHONY: mkdocs
mkdocs: install $(MKDOCS_INDEX)
Expand All @@ -104,11 +104,11 @@ $(MKDOCS_INDEX): docs/requirements.txt mkdocs.yml docs/*.md

docs/requirements.txt: poetry.lock
@ rm -f $@
@ poetry export --with dev --without-hashes | grep jinja2 >> $@
@ poetry export --with dev --without-hashes | grep markdown >> $@
@ poetry export --with dev --without-hashes | grep mkdocs >> $@
@ poetry export --with dev --without-hashes | grep pygments >> $@
@ poetry export --with dev --without-hashes | grep importlib-metadata >> $@
@ poetry export --all-groups --without-hashes | grep jinja2 >> $@
@ poetry export --all-groups --without-hashes | grep markdown >> $@
@ poetry export --all-groups --without-hashes | grep mkdocs >> $@
@ poetry export --all-groups --without-hashes | grep pygments >> $@
@ poetry export --all-groups --without-hashes | grep importlib-metadata >> $@

.PHONY: mkdocs-serve
mkdocs-serve: mkdocs
Expand Down Expand Up @@ -140,15 +140,15 @@ $(DIST_FILES): $(MODULES) pyproject.toml
poetry build

.PHONY: upload
upload: dist ## Upload the current version to PyPI
upload: dist ## Upload the current version to PyPI
git diff --name-only --exit-code
poetry publish
bin/open https://pypi.org/project/$(PACKAGE)

# CLEANUP #####################################################################

.PHONY: clean
clean: ## Delete all generated and temporary files
clean: ## Delete all generated and temporary files
rm -rf .venv

# HELP ########################################################################
Expand Down
8 changes: 6 additions & 2 deletions bin/verchew
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ else:
import configparser
from urllib.request import urlretrieve

__version__ = "3.4.1"
__version__ = "3.4.2"

SCRIPT_URL = (
"https://raw.githubusercontent.com/jacebrowning/verchew/main/verchew/script.py"
Expand Down Expand Up @@ -308,7 +308,11 @@ def get_version(program, argument=None):

def match_version(pattern, output):
lines = output.splitlines()
if not lines or "not found" in lines[0]:
if not lines:
return False
if "not found" in lines[0]:
return False
if re.match(r"No .+ executable found", " ".join(lines)):
return False

regex = pattern.replace(".", r"\.") + r"(\b|/)"
Expand Down
12 changes: 6 additions & 6 deletions docs/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
jinja2==3.1.5 ; python_version >= "3.8" and python_version < "4.0"
markdown==3.3.4 ; python_version >= "3.8" and python_version < "4.0"
mkdocs==1.4.2 ; python_version >= "3.8" and python_version < "4.0"
jupyterlab-pygments==0.2.2 ; python_version >= "3.8" and python_version < "4.0" and os_name != "nt"
pygments==2.15.0 ; python_version >= "3.8" and python_version < "4.0"
importlib-metadata==4.12.0 ; python_version >= "3.8" and python_version < "3.10"
jinja2==3.1.4 ; python_version >= "3.9" and python_version < "4.0"
markdown==3.3.4 ; python_version >= "3.9" and python_version < "4.0"
mkdocs==1.4.2 ; python_version >= "3.9" and python_version < "4.0"
jupyterlab-pygments==0.2.2 ; python_version >= "3.9" and python_version < "4.0" and os_name != "nt"
pygments==2.15.0 ; python_version >= "3.9" and python_version < "4.0"
importlib-metadata==4.12.0 ; python_version >= "3.9" and python_version < "3.10"
Loading

0 comments on commit 787a208

Please sign in to comment.