Skip to content

Commit

Permalink
Merge pull request #127 from scrapy-plugins/modernize
Browse files Browse the repository at this point in the history
Add Python 3.13, bump (some) tool versions, add twinecheck
  • Loading branch information
wRAR authored Oct 16, 2024
2 parents 249e79f + 7450c03 commit e00c152
Show file tree
Hide file tree
Showing 7 changed files with 33 additions and 15 deletions.
19 changes: 15 additions & 4 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,14 @@
name: CI
on: [push, pull_request]
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- python-version: "2.7"
Expand Down Expand Up @@ -41,14 +46,20 @@ jobs:
- python-version: "3.12"
env:
TOXENV: py
- python-version: "3.12"
- python-version: "3.13"
env:
TOXENV: py
- python-version: "3.13"
env:
TOXENV: pre-commit
- python-version: "3.12"
- python-version: "3.12" # Keep in sync with .readthedocs.yml
env:
TOXENV: docs
- python-version: "3.13"
env:
TOXENV: twinecheck
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: MatteoH2O1999/setup-python@v4
with:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v5
with:
python-version: "3.x"
python-version: "3.13"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
Expand Down
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
repos:
- repo: https://github.com/PyCQA/bandit
rev: 1.7.9
rev: 1.7.10
hooks:
- id: bandit
args: [-r, -c, .bandit.yml]
2 changes: 1 addition & 1 deletion .readthedocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ build:
python:
install:
- requirements: docs/requirements.txt
- path: .
- path: .
6 changes: 1 addition & 5 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,8 @@
sys.path.insert(0, path.dirname(path.dirname(__file__)))


import sphinx_rtd_theme

html_theme = "sphinx_rtd_theme"

html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]

# -- General configuration ------------------------------------------------

# If your documentation needs a minimal Sphinx version, state it here.
Expand All @@ -48,7 +44,7 @@
# You can specify multiple suffix as a list of string:
#
# source_suffix = ['.rst', '.md']
source_suffix = '.rst'
source_suffix = {'.rst': 'restructuredtext'}

# The master toctree document.
master_doc = 'index'
Expand Down
2 changes: 2 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
license='BSD',
description='Scrapy middleware for Zyte Smart Proxy Manager',
long_description=readme,
long_description_content_type="text/x-rst",
maintainer='Raul Gallegos',
maintainer_email='[email protected]',
author='Zyte',
Expand All @@ -32,6 +33,7 @@
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: 3.11',
'Programming Language :: Python :: 3.12',
'Programming Language :: Python :: 3.13',
'Framework :: Scrapy',
'Intended Audience :: Developers',
'Topic :: Internet :: WWW/HTTP',
Expand Down
11 changes: 10 additions & 1 deletion tox.ini
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# tox.ini
[tox]
envlist = pre-commit,mypy,min,py27,py34,py35,py36,py37,py38,py39,py310,py311,py312,docs
envlist = pre-commit,mypy,min,py27,py34,py35,py36,py37,py38,py39,py310,py311,py312,py313,docs

[testenv]
deps =
Expand Down Expand Up @@ -64,3 +64,12 @@ changedir = {[docs]changedir}
deps = {[docs]deps}
commands =
sphinx-build -nW -b html . {envtmpdir}/html

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

0 comments on commit e00c152

Please sign in to comment.