DB_JOB/작업파일/완료/광역_사이트맵/전북특별자치도/5.무주군/_dump.py
hehihoho3 df16c98366 백업: DB수집 전체 스냅샷 (공공기관2 정리 전)
공공기관2 작업 중. _temp 몽타주(재생성가능)는 제외.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-18 18:15:40 +09:00

24 lines
1.0 KiB
Python

# -*- coding: utf-8 -*-
import sys
sys.stdout.reconfigure(encoding='utf-8')
import openpyxl
wb = openpyxl.load_workbook('전북특별자치도_무주군.xlsx'); ws = wb.active
print('max_row', ws.max_row)
def show(rng):
for r in rng:
vals = [ws.cell(r, c).value for c in range(2, 12)] # B..K
k = ws.cell(r,11)
link = k.hyperlink.target if k.hyperlink else None
print(r, vals, '| Klink:', link)
for region in [range(153,160), range(180,186)]:
print('=====')
show(region)
print('===== B values continuity check (first/last) =====')
content = [r for r in range(3, ws.max_row+1)
if ws.cell(r,2).value not in (None,'') or ws.cell(r,11).value not in (None,'')
or any(ws.cell(r,c).value not in (None,'') for c in range(4,11))]
print('content rows count:', len(content), 'first', content[0], 'last', content[-1])
# show rows that are NOT content between 3..max to see truly empty rows
noncontent = [r for r in range(3, ws.max_row+1) if r not in content]
print('non-content rows in range:', noncontent)