Skip to content

Commit

Permalink
⬆️ Drop Python 3.9, test 3.13
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisjsewell committed Nov 30, 2024
1 parent 21335c8 commit 0671993
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 22 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/benchmark.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Set up Python 3.8
- name: Set up Python 3.9
uses: actions/setup-python@v5
with:
python-version: 3.8
python-version: 3.9

- name: install pandoc
uses: r-lib/actions/setup-pandoc@v2
Expand Down
19 changes: 10 additions & 9 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,18 +20,19 @@ jobs:

steps:
- uses: actions/checkout@v4
- name: Set up Python 3.8
- name: Set up Python 3.9
uses: actions/setup-python@v5
with:
python-version: '3.8'
python-version: '3.9'
- uses: pre-commit/[email protected]

tests:

runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ['pypy-3.8', '3.8', '3.9', '3.10', '3.11', '3.12']
python-version: ['pypy-3.9', '3.9', '3.10', '3.11', '3.12', '3.13']

steps:
- uses: actions/checkout@v4
Expand All @@ -48,7 +49,7 @@ jobs:
run: |
pytest tests/ --cov=markdown_it --cov-report=xml --cov-report=term-missing
- name: Upload to Codecov
if: matrix.python-version == '3.8' && github.repository == 'executablebooks/markdown-it-py'
if: matrix.python-version == '3.9' && github.repository == 'executablebooks/markdown-it-py'
uses: codecov/codecov-action@v3
with:
name: markdown-it-py-pytests
Expand All @@ -62,7 +63,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.8']
python-version: ['3.9']
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
Expand All @@ -86,10 +87,10 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Set up Python 3.8
- name: Set up Python 3.9
uses: actions/setup-python@v5
with:
python-version: '3.8'
python-version: '3.9'

- name: Install tox
run: |
Expand All @@ -115,10 +116,10 @@ jobs:
steps:
- name: Checkout source
uses: actions/checkout@v4
- name: Set up Python 3.8
- name: Set up Python 3.9
uses: actions/setup-python@v5
with:
python-version: '3.8'
python-version: '3.9'
- name: install flit
run: |
pip install flit~=3.4
Expand Down
3 changes: 2 additions & 1 deletion markdown_it/common/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
from __future__ import annotations

import re
from typing import Match, TypeVar
from re import Match
from typing import TypeVar

from .entities import entities

Expand Down
3 changes: 2 additions & 1 deletion markdown_it/utils.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
from __future__ import annotations

from collections.abc import Iterable, MutableMapping
from collections.abc import MutableMapping as MutableMappingABC
from pathlib import Path
from typing import Any, Callable, Iterable, MutableMapping, TypedDict, cast
from typing import Any, Callable, TypedDict, cast

EnvType = MutableMapping[str, Any] # note: could use TypeAlias in python 3.10
"""Type for the environment sandbox used in parsing and rendering,
Expand Down
8 changes: 4 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,18 +14,18 @@ classifiers = [
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Programming Language :: Python :: 3",
"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.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Text Processing :: Markup",
]
keywords = ["markdown", "lexer", "parser", "commonmark", "markdown-it"]
requires-python = ">=3.8"
requires-python = ">=3.9"
dependencies = [
"mdurl~=0.1",
]
Expand Down
10 changes: 5 additions & 5 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,18 @@
# then run `tox` or `tox -- {pytest args}`
# run in parallel using `tox -p`
[tox]
envlist = py38
envlist = py39

[testenv]
usedevelop = true

[testenv:py{38,39,310,311,312}]
[testenv:py{39,310,311,312,313}]
extras =
linkify
testing
commands = pytest {posargs:tests/}

[testenv:py{38,39,310,311}-plugins]
[testenv:py{39,310,311,312,313}-plugins]
extras = testing
changedir = {envtmpdir}
allowlist_externals =
Expand All @@ -27,11 +27,11 @@ commands_pre =
commands =
pytest {posargs}

[testenv:py{38,39,310,311,312}-bench-core]
[testenv:py{39,310,311,312,313}-bench-core]
extras = benchmarking
commands = pytest benchmarking/bench_core.py {posargs}

[testenv:py{38,39,310,311,312}-bench-packages]
[testenv:py{39,310,311,312,313}-bench-packages]
extras = benchmarking,compare
commands = pytest benchmarking/bench_packages.py {posargs}

Expand Down

0 comments on commit 0671993

Please sign in to comment.