From 1354e098312bb42e37bbc75eaaa672ed1701e3be Mon Sep 17 00:00:00 2001 From: Roberto Guagliardo Date: Mon, 2 Feb 2026 20:18:44 +0000 Subject: [PATCH] fix diff file --- .../__pycache__/diff.cpython-311.pyc | Bin 7968 -> 7968 bytes .../__pycache__/prompt.cpython-311.pyc | Bin 1391 -> 1391 bytes src/ai_reviewer/diff.py | 8 ++++---- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/ai_reviewer/__pycache__/diff.cpython-311.pyc b/src/ai_reviewer/__pycache__/diff.cpython-311.pyc index 646eced0a4e28c74c3f20f3350d3c59e40ed5112..18b212e380ebf3b68563fdac8758403594042d70 100644 GIT binary patch delta 20 acmZ2rx4@2jIWI340}#luHE!e str: def parse_diff(diff_text: str) -> list[FileDiff]: files: list[FileDiff] = [] current_path: str | None = None - header_ lines: list[str] = [] + header_lines: list[str] = [] hunks: list[Hunk] = [] current_hunk_header: str | None = None current_hunk_lines: list[str] = [] @@ -89,9 +89,9 @@ def parse_diff(diff_text: str) -> list[FileDiff]: if line.startswith("diff --git "): flush_file() header_lines = [line] - p = line.split() - if len(parts) >= 4 and p[3].startswith("b/"): - current_path = p[3][len("b/") :] + parts = line.split() + if len(parts) >= 4 and parts[3].startswith("b/"): + current_path = parts[3][len("b/") :] else: current_path = None continue