agromatrix: tighten numeric source contract guard
This commit is contained in:
@@ -338,12 +338,12 @@ def _numeric_contract_present(text: str) -> bool:
|
|||||||
has_explicit_source = any(
|
has_explicit_source = any(
|
||||||
re.search(pattern, low) is not None
|
re.search(pattern, low) is not None
|
||||||
for pattern in (
|
for pattern in (
|
||||||
r"\bsheet\s*[:#]?\s*[a-z0-9_]+",
|
r"\bsheet(?:\s*[:#]\s*[a-z0-9_]+|\s+[a-z0-9_]+![a-z]+\d+)",
|
||||||
r"\brow\s*[:#]?\s*\d+",
|
r"\brow\s*[:#]\s*\d+",
|
||||||
r"\bрядок\s*[:#]?\s*\d+",
|
r"\bрядок\s*[:#]\s*\d+",
|
||||||
r"\bлист\s*[:#]?\s*[a-zа-я0-9_]+",
|
r"\bлист(?:\s*[:#]\s*[a-zа-я0-9_]+|\s+[a-zа-я0-9_]+![a-zа-я]+\d+)",
|
||||||
r"\bcell\s*[:#]?\s*[a-z]+\d+",
|
r"\bcell\s*[:#]\s*[a-z]+\d+",
|
||||||
r"\bкомірк[а-я]*\s*[:#]?\s*[a-zа-я]+\d+",
|
r"\bкомірк[а-я]*\s*[:#]\s*[a-zа-я]+\d+",
|
||||||
r"\bsource\s*[:#]",
|
r"\bsource\s*[:#]",
|
||||||
r"\bджерел[оа]\s*[:#]",
|
r"\bджерел[оа]\s*[:#]",
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user