#!/usr/bin/env python3
"""Fix last 2 entries"""
import json

with open('/root/gov_crawler/daily_crawl_config.json', 'r') as f:
    items = json.load(f)

changes = 0
for item in items:
    if item['name'] == '巴音尔堡生态环境':
        item['group'] = '内蒙古'
        changes += 1
        print("Fixed: 巴音尔堡 -> 内蒙古")
    elif item['name'] == '环保公示网-全部':
        item['group'] = '其他'
        changes += 1
        print("Fixed: 环保公示网 -> 其他")

if changes:
    with open('/root/gov_crawler/daily_crawl_config.json', 'w') as f:
        json.dump(items, f, ensure_ascii=False, indent=2)
    print(f"Applied {changes} changes")
else:
    print("No changes needed")
