Skip to content

Commit

Permalink
Merge pull request #576 from azmeuk/pyproject.toml
Browse files Browse the repository at this point in the history
move from setup.cfg to pyproject.toml
  • Loading branch information
azmeuk committed Sep 29, 2023
2 parents 65dbb59 + 90b4fcc commit af39209
Show file tree
Hide file tree
Showing 5 changed files with 106 additions and 87 deletions.
1 change: 1 addition & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ repos:
additional_dependencies:
- flake8-bugbear
- flake8-implicit-str-concat
- flake8-pyproject
- repo: https://github.com/peterdemin/pip-compile-multi
rev: v2.6.3
hooks:
Expand Down
1 change: 1 addition & 0 deletions docs/changes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ Unreleased
- Fixed Flask 2.3 deprecations of ``werkzeug.urls.url_encode`` and
``flask.Markup`` :pr:`565` :issue:`561`
- Stop support for python 3.7 :pr:`574`
- Use `pyproject.toml` instead of `setup.cfg` :pr:`576`

Version 1.1.1
-------------
Expand Down
104 changes: 104 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,104 @@
[project]
name = "Flask-WTF"
description = "Form rendering, validation, and CSRF protection for Flask with WTForms."
readme = "README.rst"
license = {file = "LICENSE.rst"}
maintainers = [{name = "WTForms"}]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Environment :: Web Environment",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Topic :: Internet :: WWW/HTTP :: Dynamic Content",
"Topic :: Internet :: WWW/HTTP :: WSGI",
"Topic :: Internet :: WWW/HTTP :: WSGI :: Application",
"Topic :: Software Development :: Libraries :: Application Frameworks",
]
requires-python = ">=3.8"
dependencies = [
"Flask",
"WTForms",
"itsdangerous",
]
dynamic = ["version"]

[project.urls]
Documentation = "https://flask-wtf.readthedocs.io/"
Changes = "https://flask-wtf.readthedocs.io/changes/"
"Source Code" = "https://github.com/wtforms/flask-wtf/"
"Issue Tracker" = "https://github.com/wtforms/flask-wtf/issues/"
Chat = "https://discord.gg/pallets"

[project.optional-dependencies]
email = ["email_validator"]

[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"

[tool.hatch.build.targets.wheel]
packages = ["src/flask_wtf"]

[tool.hatch.version]
path = "src/flask_wtf/__init__.py"

[tool.hatch.build]
include = [
"src/",
"docs/",
"tests/",
"CHANGES.rst",
"tox.ini",
]
exclude = [
"docs/_build/",
]

[tool.pytest.ini_options]
testpaths = ["tests"]
filterwarnings = [
"error",
]

[tool.coverage.run]
branch = true
source = ["flask_wtf", "tests"]

[tool.coverage.paths]
source = ["src", "*/site-packages"]

[tool.coverage.report]
exclude_lines = [
"pragma: no cover",
"except ImportError:",
]

[tool.flake8]
# B = bugbear
# E = pycodestyle errors
# F = flake8 pyflakes
# W = pycodestyle warnings
# B9 = bugbear opinions
# ISC = implicit-str-concat
select = ["B", "E", "F", "W", "B9", "ISC"]
ignore = [
# slice notation whitespace, invalid
"E203",
# line length, handled by bugbear B950
"E501",
# bare except, handled by bugbear B001
"E722",
# bin op line break, invalid
"W503",
# requires 'strict' argument for 'zip'
# that needs python >= 3.10
"B905",
]
# up to 88 allowed by bugbear B950
max-line-length = 80
per-file-ignores = [
# __init__ modules export names
"**/__init__.py: F401, F403",
]
80 changes: 0 additions & 80 deletions setup.cfg

This file was deleted.

7 changes: 0 additions & 7 deletions setup.py

This file was deleted.

0 comments on commit af39209

Please sign in to comment.