Recommend hatch and add more linting in the pyproject.toml proposal

This commit is contained in:
Gerard Vermeulen 2023-01-05 14:51:19 +01:00
parent 1d2a8d8ec9
commit 6a24b41bee

View File

@ -4612,14 +4612,8 @@ Complete the result with \"system\"."
#+caption: Kickoff =pyproject.toml= proposal.
#+name: lst:pyproject-toml-kickoff
#+begin_src toml :tangle pyproject.toml
# [project]
# name = "catchy-name"
# version = "0.0.1"
# description = "Catchy Acronym Description"
# [build-system]
# requires = [ "setuptools>=61.0" ]
# build-backend = "setuptools.build_meta"
# Use for instance "hatch new" to create or initialize a project.
# See: https://pypi.org/project/hatch
[tool.black]
line-length = 88
@ -4630,21 +4624,26 @@ select = [
"ARG", # flake8-unused-arguments
"B", # flake8-bugbear
"C", # mccabe
"C4", # flake8-comprehensions
"E", # pycodestyle
"D", # pydocstyle
"F", # pyflakes
# "W", # ruff emits no pycodestyle warnings yet
"UP", # pyupgrade
"W", # pycodestyle
]
ignore = [
"D107", # ignore: missing docstring in __init__
"D203", # ignore: single blank line required before class docstring
"D212", # ignore: multi-line docstring summary should start at the first line
"D213", # ignore: multi-line docstring summary should start at the second line
"D402", # ignore: first line should not be the function signature
"D413", # ignore: missing blank line after last section
"D415", # ignore: 1st line should end with a ".", "?", or "?"
"D416", # ignore: section name should end with a ":"
"D417", # ignore: missing argument descriptions in the docstring
"B905", # `zip()` without an explicit `strict=` parameter
# https://www.pydocstyle.org/en/stable/error_codes.html#default-conventions
# pydocstyle numpy convention:
# "D107", # missing docstring in __init__
# "D203", # single blank line required before class docstring
# "D212", # multi-line docstring summary should start at the first line
# "D213", # multi-line docstring summary should start at the second line
# "D402", # first line should not be the function signature
# "D413", # missing blank line after last section
# "D415", # 1st line should end with a ".", "?", or "?"
# "D416", # section name should end with a ":"
# "D417", # missing argument descriptions in the docstring
]
[tool.ruff.mccabe]