-
Notifications
You must be signed in to change notification settings - Fork 112
Expand file tree
/
Copy pathpyproject.toml
More file actions
113 lines (102 loc) · 3.26 KB
/
Copy pathpyproject.toml
File metadata and controls
113 lines (102 loc) · 3.26 KB
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
106
107
108
109
110
111
112
113
[project]
name = "nameparser"
description = "A simple Python module for parsing human names into their individual components."
readme = "README.rst"
requires-python = ">=3.11"
license = {text = "LGPL"}
authors = [{name = "Derek Gulbranson", email = "derek73@gmail.com"}]
dynamic = ["version"]
keywords = ["names", "parser"]
classifiers = [
"Intended Audience :: Developers",
"License :: OSI Approved :: GNU Library or Lesser General Public License (LGPL)",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Development Status :: 5 - Production/Stable",
"Natural Language :: English",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Text Processing :: Linguistic",
]
dependencies = []
[project.optional-dependencies]
# Japanese kanji-name segmentation (#272), wrapped by
# locales.ja_segmenter(). Optional and never bundled: the core stays
# zero-dependency. 0.4 is the floor its BasicNameDivider/DividedName
# API dates from.
ja = ["namedivider-python>=0.4"]
[build-system]
requires = ["setuptools (>=82.0.1)"]
build-backend = "setuptools.build_meta"
[tool.setuptools.dynamic]
version = {attr = "nameparser._version.__version__"}
[tool.setuptools.package-data]
nameparser = ["py.typed"]
[dependency-groups]
dev = [
"pytest (>=8)",
"dill (>=0.2.5)",
"sphinx (>=8)",
"furo",
"mypy (>=2.1)",
"ruff (>=0.15)",
"pytest-timeout>=2.4.0",
"pytest-cov>=6",
"hypothesis",
]
[tool.mypy]
packages = ["nameparser", "tests"]
[[tool.mypy.overrides]]
module = [
"dill.*",
# optional extras, unstubbed and absent from the dev environment:
# the ja pack imports namedivider lazily, inside the factory
"namedivider.*",
]
ignore_missing_imports = true
[[tool.mypy.overrides]]
module = [
"nameparser._types",
"nameparser._lexicon",
"nameparser._policy",
"nameparser._render",
"nameparser._locale",
"nameparser._pipeline.*",
"nameparser._parser",
]
disallow_untyped_defs = true
disallow_incomplete_defs = true
disallow_any_generics = true
warn_return_any = true
strict_equality = true
[[tool.mypy.overrides]]
module = ["tests.v2.*"]
check_untyped_defs = true
[tool.pytest.ini_options]
testpaths = ["tests", "nameparser"]
addopts = "--doctest-modules"
python_classes = ["*Tests", "*TestCase"]
# Fail if an xfail-marked test unexpectedly passes, so a fixed/regressed
# expectation surfaces instead of silently turning into an xpass.
xfail_strict = true
# Unexpected warnings are failures: warnings are load-bearing API in 2.0
# (the multi-word-entry UserWarning, the facade deprecation warnings), and
# without this a warning regression is invisible to the suite -- a real
# bug (eight spurious warnings on restoring a 1.4 Constants pickle)
# shipped to review this way. Tests that EXPECT a warning assert it with
# pytest.warns; targeted ignores below need a comment justifying each.
filterwarnings = [
"error",
]
[tool.ruff.lint]
extend-select = [
"ANN", # flake8-annotations
"UP", # pyupgrade
]
ignore = [
"E74", # ambiguous-{variable,class,function}-name (I have trouble believing that these are real rules)
]