Skip to content

Commit

Permalink
Add Python 3.13, drop Python 3.8 and PyPy 3.9, update tool versions (#87
Browse files Browse the repository at this point in the history
)
  • Loading branch information
wRAR authored Oct 16, 2024
1 parent 02c72ad commit a75802e
Show file tree
Hide file tree
Showing 7 changed files with 26 additions and 24 deletions.
9 changes: 5 additions & 4 deletions .github/workflows/checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,16 @@ jobs:
checks:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- python-version: 3.12
- python-version: 3.13
env:
TOXENV: pylint
- python-version: 3.12
- python-version: 3.13
env:
TOXENV: typing
- python-version: 3.12
- python-version: 3.13
env:
TOXENV: twinecheck

Expand All @@ -37,4 +38,4 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pre-commit/action@v3.0.0
- uses: pre-commit/action@v3.0.0
4 changes: 2 additions & 2 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Set up Python 3.12
- name: Set up Python 3.13
uses: actions/setup-python@v5
with:
python-version: 3.12
python-version: 3.13

- name: Build
run: |
Expand Down
13 changes: 7 additions & 6 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,9 @@ jobs:
name: "Test: ${{ matrix.python-version }}, Ubuntu"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "pypy3.9", "pypy3.10"]
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "pypy3.10"]

steps:
- uses: actions/checkout@v4
Expand All @@ -31,7 +32,7 @@ jobs:
./codecov
tests-other:
name: "Test: py38-scrapy22, Ubuntu"
name: "Test: py39-scrapy22, Ubuntu"
runs-on: ubuntu-latest

steps:
Expand All @@ -40,13 +41,13 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.8
python-version: 3.9

- name: Install tox
run: pip install tox

- name: Run tests
run: tox -e py38-scrapy22
run: tox -e py39-scrapy22

- name: Upload coverage report
run: |
Expand All @@ -55,7 +56,7 @@ jobs:
./codecov
tests-other-os:
name: "Test: py38, ${{ matrix.os }}"
name: "Test: py39, ${{ matrix.os }}"
runs-on: "${{ matrix.os }}"
strategy:
matrix:
Expand All @@ -67,7 +68,7 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.8
python-version: 3.9

- name: Install tox
run: pip install tox
Expand Down
8 changes: 4 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
repos:
- repo: https://github.com/PyCQA/bandit
rev: 1.7.8
rev: 1.7.10
hooks:
- id: bandit
args: [-r, -c, .bandit.yml]
- repo: https://github.com/PyCQA/flake8
rev: 7.0.0
rev: 7.1.1
hooks:
- id: flake8
- repo: https://github.com/psf/black.git
rev: 24.4.2
rev: 24.10.0
hooks:
- id: black
- repo: https://github.com/pycqa/isort
rev: 5.13.2
hooks:
- id: isort
- id: isort
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ a pre-defined interface (see [extending `itemadapter`](#extending-itemadapter)).

## Requirements

* Python 3.8+, either the CPython implementation (default) or the PyPy implementation
* Python 3.9+, either the CPython implementation (default) or the PyPy implementation
* [`scrapy`](https://scrapy.org/): optional, needed to interact with `scrapy` items
* [`attrs`](https://pypi.org/project/attrs/): optional, needed to interact with `attrs`-based items
* [`pydantic`](https://pypi.org/project/pydantic/): optional, needed to interact with
Expand Down
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,16 +19,16 @@
"itemadapter": ["py.typed"],
},
include_package_data=True,
python_requires=">=3.8",
python_requires=">=3.9",
classifiers=[
"Development Status :: 3 - Alpha",
"License :: OSI Approved :: BSD License",
"Programming Language :: Python",
"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.13",
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy",
"Framework :: Scrapy",
Expand Down
10 changes: 5 additions & 5 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@ envlist = typing,py,py38-scrapy22,pylint,pre-commit,twinecheck
[testenv]
deps =
-rtests/requirements.txt
py38-scrapy22: scrapy==2.2
py39-scrapy22: scrapy==2.2
commands =
pytest --verbose --cov=itemadapter --cov-report=term-missing --cov-report=html --cov-report=xml --doctest-glob=README.md {posargs: itemadapter README.md tests}

[testenv:typing]
basepython = python3
deps =
mypy==1.5.1
mypy==1.11.2
attrs
pydantic
scrapy
Expand All @@ -21,15 +21,15 @@ commands =

[testenv:pylint]
deps =
pylint==3.1.0
pylint==3.3.1
commands =
pylint {posargs:itemadapter}

[testenv:twinecheck]
basepython = python3
deps =
twine==5.0.0
build==1.2.1
twine==5.1.1
build==1.2.2
commands =
python -m build --sdist
twine check dist/*
Expand Down

0 comments on commit a75802e

Please sign in to comment.