Skip to content

Commit

Permalink
Drop support for Python 3.6.
Browse files Browse the repository at this point in the history
  • Loading branch information
jendrikseipp committed Aug 20, 2023
1 parent fc23f33 commit 2bac0ab
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 14 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# 2.9 (unreleased)
* Use exit code 3 when dead code is found (whosayn, #319).
* Simplify decorator names that are too hard to parse to "@" (Llandy3d and Jendrik Seipp, #284).
* Drop support for Python 3.6 (Jendrik Seipp).

# 2.8 (2023-08-10)

Expand Down
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ tool for higher code quality.
* tested: tests itself and has complete test coverage
* complements pyflakes and has the same output syntax
* sorts unused classes and functions by size with `--sort-by-size`
* supports Python \>= 3.6
* supports Python \>= 3.7

## Installation

Expand Down Expand Up @@ -161,8 +161,6 @@ def foo(arg: Sequence):
...
```

if you're using Python 3.7+.


## Configuration

Expand Down
1 change: 0 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@

[tool.black]
line-length = 79
# target-version = ['py36', 'py37', 'py38']
include = '\.pyi?$'
exclude = '''
/(
Expand Down
3 changes: 1 addition & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ def find_version(*parts):
"License :: OSI Approved :: MIT License",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
Expand All @@ -50,7 +49,7 @@ def find_version(*parts):
],
install_requires=["toml"],
entry_points={"console_scripts": ["vulture = vulture.core:main"]},
python_requires=">=3.6",
python_requires=">=3.7",
packages=setuptools.find_packages(exclude=["tests"]),
package_data={"vulture": ["whitelists/*.py"]},
)
5 changes: 0 additions & 5 deletions tests/test_conditions.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import ast
import sys

from vulture import utils

Expand All @@ -21,10 +20,6 @@ def test_false():
check_condition("False", False)
check_condition("None", False)
check_condition("0", False)
# Only Python 3.0-3.6 allows addition and subtraction in ast.literal_eval.
# (see https://bugs.python.org/issue31778)
if (3, 0) <= sys.version_info < (3, 7):
check_condition("1 - 1", False)


def test_empty():
Expand Down
6 changes: 3 additions & 3 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[tox]
envlist = cleanup, py{36,37,38,310,311}, style # Skip py39 since it chokes on distutils.
envlist = cleanup, py{37,38,310,311}, style # Skip py39 since it chokes on distutils.
skip_missing_interpreters = true

# Erase old coverage results, then accumulate them during this tox run.
Expand Down Expand Up @@ -37,7 +37,7 @@ commands =
# B028: use !r conversion flag
# C408: unnecessary dict call
flake8 --extend-ignore=B028,C408 setup.py tests/ vulture/
bash -c "pyupgrade --py36-plus `find dev/ tests/ vulture/ -name '*.py'` setup.py"
bash -c "pyupgrade --py37-plus `find dev/ tests/ vulture/ -name '*.py'` setup.py"

[testenv:fix-style]
basepython = python3
Expand All @@ -48,4 +48,4 @@ allowlist_externals =
bash
commands =
black .
bash -c "pyupgrade --py36-plus --exit-zero `find dev/ tests/ vulture/ -name '*.py'` setup.py"
bash -c "pyupgrade --py37-plus --exit-zero `find dev/ tests/ vulture/ -name '*.py'` setup.py"

0 comments on commit 2bac0ab

Please sign in to comment.