MCPcopy Create free account
hub / github.com/DeusData/codebase-memory-mcp / parse_nonnegative

Function parse_nonnegative

scripts/ci/select-release-candidates.py:309–313  ·  view source on GitHub ↗
(row: dict[str, str], field: str, *, scan_path: str)

Source from the content-addressed store, hash-verified

307
308
309def parse_nonnegative(row: dict[str, str], field: str, *, scan_path: str) -> int:
310 value = row[field]
311 if not value.isdigit():
312 raise ContractError(f"VT result has invalid {field}: {scan_path}")
313 return int(value)
314
315
316def validate_result_row(row: dict[str, str], candidate: dict[str, str]) -> None:

Callers 1

validate_result_rowFunction · 0.85

Calls 1

ContractErrorClass · 0.70

Tested by

no test coverage detected