| { | |
| "task_id": "bug_detection_easy_1", | |
| "task_name": "Division by Zero", | |
| "description": "Find the division by zero vulnerability in the calculate_average function", | |
| "difficulty": "easy", | |
| "code_diff": "def calculate_average(numbers):\n total = sum(numbers)\n return total / len(numbers)", | |
| "expected_issues": [ | |
| { | |
| "line": 3, | |
| "type": "division_by_zero", | |
| "severity": "high", | |
| "description": "No check for empty list before division" | |
| } | |
| ] | |
| } |