-
-
Notifications
You must be signed in to change notification settings - Fork 14
/
Copy pathpyproject.toml
105 lines (94 loc) · 2.92 KB
/
pyproject.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
[build-system]
requires = ["poetry-core>=1.0.0"]
build-backend = "poetry.core.masonry.api"
[tool.poetry]
name = "babelfish"
version = "0.6.1"
description = "A module to work with countries and languages"
authors = [
"Antoine Bertin <[email protected]>",
"Nicolas Wack <[email protected]>",
"Rémi Alvergnat <[email protected]>",
]
license = "BSD-3-Clause"
readme = "README.md"
repository = "https://github.com/Diaoul/babelfish"
keywords = [
"language",
"country",
"locale",
]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Topic :: Software Development :: Internationalization",
"Topic :: Software Development :: Libraries :: Python Modules",
]
[tool.poetry.dependencies]
python = "^3.8"
importlib-resources = {version = "^5.0", python = "<3.9"}
importlib-metadata = {version = "^4.6", python = "<3.10"}
[tool.poetry.group.dev.dependencies]
pytest = "^8.2.0"
# https://docs.astral.sh/ruff/
[tool.ruff]
line-length = 120
src = ["babelfish", "tests"]
[tool.ruff.lint]
pydocstyle = { convention = "pep257" }
select = [
"E", # style errors
"F", # flakes
"W", # warnings
# "D", # pydocstyle
# "D417", # Missing argument descriptions in Docstrings
"I", # isort
"UP", # pyupgrade
"S", # bandit
"C4", # flake8-comprehensions
"B", # flake8-bugbear
"TCH", # flake8-typecheck
"TID", # flake8-tidy-imports
"RUF", # ruff-specific rules
"ISC", # flake8-implicit-str-concat
"PT", # flake8-pytest-style
"FA", # flake8-future-annotations
"BLE", # flake8-blind-except
"RET", # flake8-return
"SIM", # flake8-simplify
"DTZ", # flake8-datetimez
"A", # flake8-builtins
"FBT", # flake8-boolean-trap
"ANN0", # flake8-annotations
"ANN2",
"ASYNC", # flake8-async
"TRY", # tryceratops
]
ignore = [
"D105", # Missing docstring in magic method
"D107", # Missing docstring in `__init__`
"D401", # First line should be in imperative mood
]
[tool.ruff.lint.flake8-pytest-style]
mark-parentheses = true
[tool.ruff.lint.per-file-ignores]
"docs/conf*.py" = ["ALL"]
"babelfish/__init__.py" = ["E402"]
"tests/*.py" = ["D", "S", "RUF012", "ANN", "FBT", "PT011"]
# https://docs.astral.sh/ruff/formatter/
[tool.ruff.format]
docstring-code-format = true
quote-style = "single"
# https://mypy.readthedocs.io/en/stable/config_file.html
[tool.mypy]
pretty = true