Skip to content

Commit f37f5da

Browse files
committed
feat!: drop Python 3.8
1 parent 67be1d1 commit f37f5da

File tree

10 files changed

+28
-20
lines changed

10 files changed

+28
-20
lines changed

.copier-answers.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# Answer file maintained by Copier for: https://github.com/KyleKing/mdformat-plugin-template
33
# DO NOT MODIFY THIS FILE. Edit by re-running copier and changing responses to the questions
44
# Check into version control.
5-
_commit: 0.2.7
5+
_commit: 1.0.0
66
_src_path: gh:KyleKing/mdformat-plugin-template
77
author_email: [email protected]
88
author_name: Kyle King

.github/workflows/tests.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
runs-on: ${{ matrix.os }}
2020
strategy:
2121
matrix:
22-
python-version: [3.8, 3.12]
22+
python-version: [3.9, 3.12]
2323
os: [ubuntu-latest, windows-latest]
2424
steps:
2525
- uses: actions/checkout@v4

.pre-commit-test.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
# A pre-commit hook for testing unreleased changes
3-
# Run from tox with: tox -e py38-hook
3+
# Run from tox with: tox -e py39-hook
44
repos:
55
- repo: local
66
hooks:

.tool-versions

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
python 3.8.12 3.12.5
1+
python 3.9.13 3.12.5

CONTRIBUTING.md

+8-2
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ tox
2727
and with test coverage:
2828

2929
```bash
30-
tox -e py38-cov
30+
tox -e py39-cov
3131
```
3232

3333
The easiest way to write tests, is to edit `tests/fixtures.md`
@@ -49,7 +49,7 @@ pre-commit run --all
4949
To run the pre-commit hook test:
5050

5151
```bash
52-
tox -e py38-hook
52+
tox -e py39-hook
5353
```
5454

5555
## `ptw` testing
@@ -70,6 +70,12 @@ Run the latest local code anywhere with pipx.
7070
pipx install . --include-deps --force --editable
7171
```
7272

73+
Or with uv:
74+
75+
```sh
76+
uv tool install mdformat --force --with-editable=.
77+
```
78+
7379
## Publish to PyPi
7480

7581
First, update the version in `mdformat_mkdocs/__init__.py`

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ Add this package wherever you use `mdformat` and the plugin will be auto-recogni
4646
```yaml
4747
repos:
4848
- repo: https://github.com/executablebooks/mdformat
49-
rev: 0.7.16
49+
rev: 0.7.18
5050
hooks:
5151
- id: mdformat
5252
additional_dependencies:

mdformat_mkdocs/_normalize_list.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,11 @@
33
from __future__ import annotations
44

55
import re
6+
from collections.abc import Mapping
67
from contextlib import suppress
78
from enum import Enum
89
from itertools import starmap
9-
from typing import Any, Callable, Literal, Mapping, NamedTuple, TypeVar
10+
from typing import Any, Callable, Literal, NamedTuple, TypeVar
1011

1112
from mdformat.renderer import RenderContext, RenderTreeNode
1213
from more_itertools import unzip, zip_equal

mdformat_mkdocs/plugin.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,9 @@
33
from __future__ import annotations
44

55
import argparse
6+
from collections.abc import Mapping
67
from functools import partial
7-
from typing import Any, Mapping
8+
from typing import Any
89

910
from markdown_it import MarkdownIt
1011
from mdformat.renderer import DEFAULT_RENDERERS, RenderContext, RenderTreeNode

pyproject.toml

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[build-system]
22
build-backend = "flit_core.buildapi"
3-
requires = ["flit_core >=3.2.0,<4"]
3+
requires = ["flit_core >=3.9.0,<4"]
44

55
[project]
66
authors = [
@@ -13,7 +13,7 @@ classifiers = [
1313
"Topic :: Software Development :: Libraries :: Python Modules",
1414
]
1515
dependencies = [
16-
"mdformat >= 0.7.17",
16+
"mdformat >= 0.7.18",
1717
"mdformat-admon >= 2.0.6",
1818
"mdformat-gfm >= 0.3.6",
1919
"mdit-py-plugins >= 0.4.1",
@@ -23,7 +23,7 @@ dynamic = ["description", "version"]
2323
keywords = ["markdown", "markdown-it", "mdformat", "mdformat_plugin_template"]
2424
name = "mdformat_mkdocs"
2525
readme = "README.md"
26-
requires-python = ">=3.8.5"
26+
requires-python = ">=3.9.0"
2727

2828
[project.entry-points."mdformat.parser_extension"]
2929
mkdocs = "mdformat_mkdocs"
@@ -67,7 +67,7 @@ enable_error_code = ["ignore-without-code", "possibly-undefined", "redundant-exp
6767
extra_checks = true
6868
files = ["mdformat_mkdocs", "tests"]
6969
no_implicit_reexport = true
70-
python_version = "3.8"
70+
python_version = "3.9"
7171
show_column_numbers = true
7272
show_error_codes = true
7373
strict_equality = true
@@ -79,7 +79,7 @@ warn_unused_ignores = true
7979

8080
[tool.pyright]
8181
include = ["mdformat_mkdocs", "tests"]
82-
pythonVersion = "3.8"
82+
pythonVersion = "3.9"
8383

8484
[tool.pytest-watcher]
8585
ignore_patterns = []
@@ -92,7 +92,7 @@ runner_args = ["-e", "py312-beartype"]
9292
# Docs: https://github.com/charliermarsh/ruff
9393
# Tip: poetry run python -m ruff --explain RUF100
9494
line-length = 88
95-
target-version = 'py38'
95+
target-version = 'py39'
9696

9797
[tool.ruff.lint]
9898
ignore = [

tox.ini

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
[tox]
22
envlist =
33
py{312}-beartype
4-
py{38}-cov
4+
py{39}-cov
55
py{312}-pre-commit
6-
py{38}-hook
6+
py{39}-hook
77
py{312}-mypy
88
py{312}-ruff
99
isolated_build = True
@@ -13,19 +13,19 @@ skip_missing_interpreters = False
1313
extras = test
1414
commands = pytest {posargs} --ff --nf -vv --exitfirst --beartype-packages='mdformat_mkdocs'
1515

16-
[testenv:py{38}-snapshot-update]
16+
[testenv:py{39}-snapshot-update]
1717
extras = test
1818
commands = pytest {posargs} --snapshot-update
1919

20-
[testenv:py{38}-cov]
20+
[testenv:py{39}-cov]
2121
extras = test
2222
commands = pytest --cov=mdformat_mkdocs {posargs}
2323

2424
[testenv:py{312}-pre-commit]
2525
extras = dev
2626
commands = pre-commit run {posargs:--all-files}
2727

28-
[testenv:py{38}-hook]
28+
[testenv:py{39}-hook]
2929
extras = dev
3030
commands = pre-commit run --config .pre-commit-test.yaml {posargs:--all-files --verbose --show-diff-on-failure}
3131

0 commit comments

Comments
 (0)