Merge pull request #372 from SamR1/drop-python-3.7

Drop python 3.7 support
This commit is contained in:
Sam 2023-06-18 09:45:02 +02:00 committed by GitHub
commit 3a6315d62f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 165 additions and 361 deletions

View File

@ -4,3 +4,4 @@ per-file-ignores =
fittrackee/application/app_config.py:E501
fittrackee/tests/test_email.py:E501
fittrackee/tests/test_email_template_password_request.py:E501
exclude = fittrackee/migrations

View File

@ -32,7 +32,7 @@ jobs:
--health-retries 5
strategy:
matrix:
python-version: [ "3.7", "3.8", "3.9", "3.10", "3.11" ]
python-version: [ "3.8", "3.9", "3.10", "3.11" ]
steps:
- uses: actions/checkout@v2
- name: Install Poetry and Dependencies
@ -44,9 +44,12 @@ jobs:
- name: Bandit
if: matrix.python-version == '3.10'
run: bandit -r fittrackee -c pyproject.toml
- name: Lint
- name: Lint (isort & black)
if: matrix.python-version == '3.10'
run: pytest --flake8 --isort --black -m "flake8 or isort or black" fittrackee e2e --ignore=fittrackee/migrations -p no:warnings
run: pytest --isort --black -m "isort or black" fittrackee e2e --ignore=fittrackee/migrations -p no:warnings
- name: Lint (flake8)
if: matrix.python-version == '3.10'
run: flake8 fittrackee e2e
- name: Mypy
if: matrix.python-version == '3.10'
run: mypy fittrackee

View File

@ -182,7 +182,9 @@ lint-client-fix:
cd fittrackee_client && $(NPM) lint-fix
lint-python:
$(PYTEST) --flake8 --isort --black -m "flake8 or isort or black" fittrackee e2e --ignore=fittrackee/migrations
$(PYTEST) --isort --black -m "isort or black" fittrackee e2e --ignore=fittrackee/migrations
echo 'Running flake8...'
$(FLAKE8) fittrackee e2e
lint-python-fix:
$(BLACK) fittrackee e2e

View File

@ -22,6 +22,7 @@ FLASK = $(VENV)/bin/flask
PYTEST = $(VENV)/bin/py.test -c pyproject.toml -W ignore::DeprecationWarning
GUNICORN = $(VENV)/bin/gunicorn
BLACK = $(VENV)/bin/black
FLAKE8 = $(VENV)/bin/flake8
MYPY = $(VENV)/bin/mypy
BANDIT = $(VENV)/bin/bandit
PYBABEL = $(VENV)/bin/pybabel

495
poetry.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -14,7 +14,6 @@ classifiers = [
"License :: OSI Approved :: GNU Affero General Public License v3",
"Operating System :: POSIX :: Linux",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
@ -24,7 +23,7 @@ classifiers = [
exclude = ["fittrackee/tests"]
[tool.poetry.dependencies]
python = "^3.7"
python = "^3.8.1"
authlib = "=1.2.0"
babel = "^2.11.0"
dramatiq = {version = "^1.14", extras = ["redis"]}
@ -48,26 +47,25 @@ ua-parser = "^0.16.1"
[tool.poetry.group.dev.dependencies]
bandit = "^1.7.5"
black = "^23.3"
flake8 = "^6.0" # requires Python >=3.8.1
freezegun = "^1.2"
mypy = "^1.3"
pytest = "^7.3"
pytest-black = "^0.3"
pytest-cov = "^3.0"
pytest-flake8 = "^1.1"
pytest-cov = "^4.1"
pytest-isort = "^3.1"
pytest-metadata = "^2.0" # to remove when dropping python 3.7
pytest-runner = "^6.0"
pytest-selenium = "^2.0.1"
pytest-variables = "^2.0" # to remove when dropping python 3.7
pytest-selenium = "^4.0"
pytest-xdist = {extras = ["psutil"], version = "^3.3"}
recommonmark = "^0.7"
sphinx = "^5.3"
sphinx = "^7.0"
sphinx-bootstrap-theme = "^0.8.1"
sphinxcontrib-httpdomain = "^1.8"
types-freezegun = "^1.1"
types-pytz = "^2023.3"
types-redis = "^4.5"
types-requests = "^2.31"
selenium = "4.9.0"
[tool.poetry.scripts]
fittrackee = 'fittrackee.__main__:main'
@ -79,7 +77,7 @@ fittrackee_upgrade_db = 'fittrackee.__main__:upgrade_db' # deprecated
[tool.black]
line-length = 79
skip-string-normalization = true
target-version = ["py37", "py38"]
target-version = ["py38"]
include = ".py$"
exclude = "migrations"