(line: str, *, allow_prefix: bool = False)
| 1740 | |
| 1741 | |
| 1742 | def stop_section_reason(line: str, *, allow_prefix: bool = False) -> str: |
| 1743 | normalized = normalize_heading(line) |
| 1744 | if not normalized: |
| 1745 | return "" |
| 1746 | reason = STOP_SECTION_REASONS.get(normalized, "") |
| 1747 | if reason or not allow_prefix: |
| 1748 | return reason |
| 1749 | if normalized.startswith(("references ", "bibliography ")): |
| 1750 | return "references" |
| 1751 | if normalized.startswith(("appendix ", "appendices ", "supplementary material ")): |
| 1752 | return "appendix" |
| 1753 | if normalized.startswith(("acknowledgments ", "acknowledgements ")): |
| 1754 | return "acknowledgments" |
| 1755 | return "" |
| 1756 | |
| 1757 | |
| 1758 | def pdf_coverage_summary(pdf_path: Path, max_pages: int | None = None) -> dict[str, Any]: |
no test coverage detected