forked from ChelseaKR/constituent-reconciler
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
122 lines (107 loc) · 3.69 KB
/
Copy pathpyproject.toml
File metadata and controls
122 lines (107 loc) · 3.69 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
114
115
116
117
118
119
120
121
122
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[project]
name = "constituent-reconciler"
version = "0.7.0"
description = "Offline-first pipeline that resolves and deduplicates nonprofit constituent records with a human review gate."
readme = "README.md"
requires-python = ">=3.12"
license = { file = "LICENSE" }
authors = [{ name = "Chelsea Kelly-Reif" }]
keywords = [
"nonprofit",
"record-linkage",
"deduplication",
"entity-resolution",
"data-intake",
"human-services",
]
classifiers = [
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"License :: OSI Approved :: Apache Software License",
"Programming Language :: Python :: 3.12",
"Topic :: Scientific/Engineering :: Information Analysis",
]
dependencies = [
"splink>=4.0,<5",
]
[project.scripts]
reconcile = "constituent_reconciler.cli:main"
[project.optional-dependencies]
extract = ["pdfplumber>=0.11"]
ocr = ["pytesseract>=0.3.10"]
# The AI assistant package (constituent_reconciler.assistant) is opt-in and
# never imported by the deterministic pipeline. This extra installs the
# default provider's SDK only; the Bedrock provider's boto3 dependency is
# intentionally left undeclared here, matching extract/seam.py's existing
# BedrockSeam convention (lazy-imported, install-hint-on-missing) rather
# than adding a second, inconsistent way to depend on boto3.
ai = ["anthropic>=0.40"]
[dependency-groups]
dev = [
"pytest>=8",
"pytest-cov>=5",
"mypy>=1.18",
"ruff>=0.15",
"pip-audit>=2.7",
"pdfplumber>=0.11",
"anthropic>=0.40",
"boto3>=1.34",
]
[project.urls]
Homepage = "https://github.com/ChelseaKR/constituent-reconciler"
Documentation = "https://github.com/ChelseaKR/constituent-reconciler/tree/main/docs"
[tool.hatch.build.targets.wheel]
packages = ["src/constituent_reconciler"]
[tool.ruff]
line-length = 100
src = ["src", "tests", "tools"]
extend-exclude = ["src/constituent_reconciler/_vendor/genai_telemetry"]
[tool.ruff.lint]
select = ["E", "F", "I", "UP", "B", "W", "S", "C90"]
[tool.ruff.lint.mccabe]
max-complexity = 10
[tool.ruff.lint.per-file-ignores]
# `assert` is the pytest idiom, not a runtime assertion to strip (S101); tests
# also deliberately construct fake credentials (S105/S106), a
# bind-all-interfaces call to assert it is refused (S104), and urlopen calls
# against the in-test loopback server (S310) — all expected-in-tests patterns,
# not findings. test_corpusgen.py's `random.Random` calls exercise the
# corpus generator's error channels directly and are never a security
# decision either (S311). Real code in src/ still gets the full S set with
# per-line noqas where a specific call is a reviewed false positive.
"tests/*" = ["S101", "S104", "S105", "S106", "S110", "S310", "S311"]
# The corpus generator's randomness is for reproducible synthetic test data,
# never a security decision, so `random.Random` (S311, "not for cryptographic
# purposes") is the correct choice here, not a finding.
"tools/corpusgen/*" = ["S311"]
[tool.mypy]
python_version = "3.12"
strict = true
files = ["src", "tests", "tools"]
explicit_package_bases = true
mypy_path = ["src"]
[[tool.mypy.overrides]]
module = [
"splink.*",
"pandas.*",
"duckdb.*",
"pdfplumber.*",
"boto3.*",
"botocore.*",
"postal.*",
"pytesseract.*",
]
ignore_missing_imports = true
[[tool.mypy.overrides]]
module = ["constituent_reconciler._vendor.genai_telemetry.*"]
ignore_errors = true
[tool.pytest.ini_options]
testpaths = ["tests"]
addopts = "-q --strict-markers --strict-config --import-mode=importlib --cov=constituent_reconciler --cov-branch --cov-report=term-missing --cov-fail-under=85"
[tool.coverage.run]
branch = true
source = ["constituent_reconciler"]
omit = ["src/constituent_reconciler/_vendor/*"]