Record file-level metrics after AST generation.
(
self,
python_files_data: List[Dict[str, Any]],
skipped: int = 0,
errors: int = 0,
)
| 98 | |
| 99 | |
| 100 | def record_files( |
| 101 | self, |
| 102 | python_files_data: List[Dict[str, Any]], |
| 103 | skipped: int = 0, |
| 104 | errors: int = 0, |
| 105 | ) -> None: |
| 106 | """Record file-level metrics after AST generation.""" |
| 107 | self.files_scanned = len(python_files_data) |
| 108 | self.files_skipped = skipped |
| 109 | self.parse_errors = errors |
| 110 | self.total_loc = sum( |
| 111 | f.get("content", "").count("\n") + 1 |
| 112 | for f in python_files_data |
| 113 | ) |
| 114 | |
| 115 | def record_rules(self, rules_toml_str: str) -> None: |
| 116 | try: |