fix: product_id 충돌 해결 (임의 생성 5종 → MASTER-017~021)

This commit is contained in:
청춘약국
2026-03-18 23:45:32 +09:00
parent a8db5be015
commit 8a18b530bd
8 changed files with 224 additions and 70 deletions

16
check_json.py Normal file
View File

@@ -0,0 +1,16 @@
# -*- coding: utf-8 -*-
import json
import os
master_dir = r'C:\Users\청춘약국\source\animal-medication-api\data\master'
for filename in sorted(os.listdir(master_dir)):
if filename.endswith('.json'):
filepath = os.path.join(master_dir, filename)
try:
with open(filepath, 'r', encoding='utf-8') as f:
data = json.load(f)
pid = data.get('product_id', 'NO_ID')
print(f'OK: {filename} ({pid})')
except Exception as e:
print(f'ERROR: {filename} - {e}')