Drop support for Python 3.7 (#546)

This commit is contained in:
Hasan Ramezani 2023-07-13 23:56:08 +02:00 committed by GitHub
parent 060473919b
commit 2c595f174c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 14 additions and 28 deletions

View file

@ -9,7 +9,7 @@ jobs:
fail-fast: false
max-parallel: 5
matrix:
python-version: ['3.7', '3.8', '3.9', '3.10', '3.11']
python-version: ['3.8', '3.9', '3.10', '3.11']
services:
postgres:

View file

@ -7,7 +7,7 @@ repos:
language_version: python3.8
args:
- "--target-version"
- "py37"
- "py38"
- repo: https://github.com/PyCQA/flake8
rev: "6.0.0"
hooks:
@ -21,7 +21,7 @@ repos:
rev: v3.9.0
hooks:
- id: pyupgrade
args: [--py37-plus]
args: [--py38-plus]
- repo: https://github.com/adamchainz/django-upgrade
rev: 1.14.0
hooks:

View file

@ -5,6 +5,7 @@
#### Breaking Changes
- feat: Change `LogEntry.change` field type to `JSONField` rather than `TextField`. This change include a migration that may take time to run depending on the number of records on your `LogEntry` table ([#407](https://github.com/jazzband/django-auditlog/pull/407))
- Python: Drop support for Python 3.7 ([#546](https://github.com/jazzband/django-auditlog/pull/546))
#### Improvements

View file

@ -1,15 +1,3 @@
try:
from importlib.metadata import version # New in Python 3.8
except ImportError:
from pkg_resources import ( # from setuptools, deprecated
DistributionNotFound,
get_distribution,
)
from importlib.metadata import version
try:
__version__ = get_distribution("django-auditlog").version
except DistributionNotFound:
# package is not installed
pass
else:
__version__ = version("django-auditlog")
__version__ = version("django-auditlog")

View file

@ -11,10 +11,10 @@ The repository can be found at https://github.com/jazzband/django-auditlog/.
**Requirements**
- Python 3.7 or higher
- Django 3.2 or higher
- Python 3.8 or higher
- Django 3.2, 4.1 and 4.2
Auditlog is currently tested with Python 3.7+ and Django 3.2 and 4.0. The latest test report can be found
Auditlog is currently tested with Python 3.8+ and Django 3.2, 4.1 and 4.2. The latest test report can be found
at https://github.com/jazzband/django-auditlog/actions.
Adding Auditlog to your Django application

View file

@ -1,5 +1,5 @@
[tool.black]
target-version = ["py37"]
target-version = ["py38"]
[tool.isort]
profile = "black"

View file

@ -27,12 +27,11 @@ setup(
description="Audit log app for Django",
long_description=long_description,
long_description_content_type="text/markdown",
python_requires=">=3.7",
python_requires=">=3.8",
install_requires=["Django>=3.2", "python-dateutil>=2.7.0"],
zip_safe=False,
classifiers=[
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",

View file

@ -1,9 +1,9 @@
[tox]
envlist =
{py37,py38,py39,py310}-django32
{py38,py39,py310}-django32
{py38,py39,py310,py311}-django{41,42}
{py310,py311}-djangomain
py37-docs
py38-docs
py38-lint
[testenv]
@ -34,9 +34,8 @@ basepython =
py310: python3.10
py39: python3.9
py38: python3.8
py37: python3.7
[testenv:py37-docs]
[testenv:py38-docs]
changedir = docs/source
deps = -rdocs/requirements.txt
commands = sphinx-build -W -b html -d {envtmpdir}/doctrees . {envtmpdir}/html
@ -48,7 +47,6 @@ commands =
[gh-actions]
python =
3.7: py37
3.8: py38
3.9: py39
3.10: py310