Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

py39-plus #1267

Merged
merged 1 commit into from
Oct 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 9 additions & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,6 @@ jobs:
- os: ubuntu-latest
py: pypy3.10
toxenv: py
- os: ubuntu-latest
py: 3.8
toxenv: py
- os: ubuntu-latest
py: 3.9
toxenv: py
Expand All @@ -29,7 +26,13 @@ jobs:
py: '3.11'
toxenv: py
- os: ubuntu-latest
py: '3.12-dev'
py: '3.12'
toxenv: py
- os: ubuntu-latest
py: '3.13'
toxenv: py
- os: ubuntu-latest
py: '3.14-dev'
toxenv: py
- os: ubuntu-latest
py: 3.9
Expand All @@ -40,10 +43,10 @@ jobs:
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.py }}
if: matrix.py != '3.12-dev'
if: matrix.py != '3.14-dev'
- uses: deadsnakes/[email protected]
with:
python-version: ${{ matrix.py }}
if: matrix.py == '3.12-dev'
if: matrix.py == '3.14-dev'
- run: pip install tox
- run: tox -e ${{ matrix.toxenv }}
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@ repos:
rev: v3.13.0
hooks:
- id: reorder-python-imports
args: [--py38-plus]
args: [--py39-plus]
- repo: https://github.com/asottile/pyupgrade
rev: v3.17.0
hooks:
- id: pyupgrade
args: [--py38-plus]
args: [--py39-plus]
- repo: https://github.com/asottile/setup-cfg-fmt
rev: v2.5.0
hooks:
Expand Down
7 changes: 2 additions & 5 deletions pycodestyle.py
Original file line number Diff line number Diff line change
Expand Up @@ -785,7 +785,6 @@ def whitespace_before_parameters(logical_line, tokens):
# Allow "return (a.foo for a in range(5))"
not keyword.iskeyword(prev_text) and
(
sys.version_info < (3, 9) or
# 3.12+: type is a soft keyword but no braces after
prev_text == 'type' or
not keyword.issoftkeyword(prev_text)
Expand Down Expand Up @@ -960,10 +959,8 @@ def missing_whitespace(logical_line, tokens):
# Allow argument unpacking: foo(*args, **kwargs).
if prev_type == tokenize.OP and prev_text in '}])' or (
prev_type != tokenize.OP and
prev_text not in KEYWORDS and (
sys.version_info < (3, 9) or
not keyword.issoftkeyword(prev_text)
)
prev_text not in KEYWORDS and
not keyword.issoftkeyword(prev_text)
):
need_space = None
elif text in WS_OPTIONAL_OPERATORS:
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ project_urls =

[options]
py_modules = pycodestyle
python_requires = >=3.8
python_requires = >=3.9
include_package_data = True
zip_safe = False

Expand Down
Loading