{ "task_id": "memory_leak_medium_1", "task_name": "File Handle Leak", "description": "Find the memory leak where file handles are not properly closed", "difficulty": "medium", "code_diff": "def read_files(file_list):\n contents = []\n for filename in file_list:\n f = open(filename, 'r')\n data = f.read()\n contents.append(data)\n return contents", "expected_issues": [ { "line": 4, "type": "resource_leak", "severity": "high", "description": "File not closed after reading" } ] }