diff --git a/elleelleaime/evaluate/strategies/google/google.py b/elleelleaime/evaluate/strategies/google/google.py index 5070914d..c1ad5eaa 100644 --- a/elleelleaime/evaluate/strategies/google/google.py +++ b/elleelleaime/evaluate/strategies/google/google.py @@ -23,6 +23,9 @@ def _evaluate_impl(self, bug: Bug, sample: dict) -> Optional[List[dict]]: for generation in sample["generation"]: for candidate in generation["candidates"]: + if "content" not in candidate: + evaluation.append(None) + continue candidate_patch = candidate["content"]["parts"][0]["text"] candidate_patch = self.extract_patch_from_message(candidate_patch) evaluation.append(