hyungi
f4e5db9723
fix(news): 304 를 redirect 로 오인하던 버그 — is_redirect → has_redirect_location
...
httpx 의 Response.is_redirect 는 3xx 전체(304 Not Modified 포함)에 True 라,
조건부 GET 으로 304 를 받으면 location 없는 같은 URL 을 3회 재요청 후
'redirect 3회 초과'로 오류 처리 → ETag/Last-Modified 받는 안정 피드(SEP/HSE/OSHA
/철학 RSS 등)가 2번째 사이클부터 전멸하던 systematic 버그.
- 304 처리를 redirect 루프보다 앞으로 이동.
- redirect 판별을 has_redirect_location(=location 헤더 있는 진짜 redirect)으로 교체.
news_collector._fetch_rss + crawl_politeness.fetch_page 동일 함정 양쪽 수정.
- 사이클 1 파일럿(경향)은 304 를 받은 적 없어 잠복했고, 안정 피드 첫 304 에서 발현.
- 회귀 테스트 3건(304 비-redirect / 진짜 redirect / 코드 패턴 audit).
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com >
2026-06-11 06:32:15 +09:00
hyungi
69db9bcb94
fix(news): 안티봇 챌린지 페이지 식별 게이트 — DataDome corruption 차단 (B-3 실측)
...
르몽드 기사 = DataDome Client Challenge(316자)가 200자 본문 floor 통과 → 챌린지
HTML 이 기사 본문으로 승격되는 silent corruption 위험. fetch_page_via_browser 에
챌린지 마커 게이트 추가 → CrawlBlocked(degrade=RSS 요약 유지). 헤드리스 탐지라 재시도 무의미.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com >
2026-06-10 17:04:11 +09:00
hyungi
61e5a416d0
fix(news): fetch_page content-type 허용 파라미터 — TWI sitemap(text/xml) 수집 (검증 게이트 발견)
...
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com >
2026-06-10 16:41:30 +09:00
hyungi
1842f27d89
feat(news): crawl-24x7 사이클 2 — B-2/B-3/C-1/C-2/C-3/C-5 (마이그 324-326)
...
- 채널 인지화: news_sources.source_channel(324, documents enum 재사용) →
문서 생성 정체성(_doc_identity)·embed/chunk 30일 게이트(crawl=전량 색인)·
extract 후속 override(crawl→classify, preview 스킵) 분기.
- B-2 Guardian Open Platform: API 디스패치(호스트 분기, 미지 호스트=명시 실패)
+ show-fields=bodyText 전문 어댑터. fixture live 박제 + call-shape 테스트.
- B-3 구독지: playwright-fetcher 격리 컨테이너(동시 1·요청당 브라우저·storage_state
ro mount) + politeness 사람속도(30-60s) 브라우저 경로 + fulltext 인증 라우팅
(내용 기반 probe 게이트·relogin_requested 소비=open-스킵보다 앞·본문 페이월 마커
게이트) + source_health probe 컬럼(325) + 세션 박제 스크립트(맥북용).
- C-2 KOSHA: 3 API live 검증·fixture 박제(board/attach/guide) — 재해사례 daily diff
+첨부 PDF/HWP→extract 파이프라인, GUIDE 일일 cap 점진 백필(silent cap 금지 로그).
키는 URL 직결합(재인코딩 함정 회피). daily 06:40 KST.
- C-3 정적 코퍼스: National Board 86 + TWI job-knowledge 153 일괄 CLI(멱등·politeness
·crawl_raw 보존·fulltext_worker 승격 필드 규약 동일).
- C-1/C-5 시드(326): 전 URL live 검증 — UK HSE(feed-full)/안전신문/고용노동부 3종
(rss/*.do)/OSHA/EU-OSHA(후보)/SEP/1000-Word(feed-full)/Doing Philosophy/Aeon/Psyche
(skip-video quirk).
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com >
2026-06-10 15:08:18 +09:00
hyungi
53a30449e2
fix(news): crawl_politeness logger 를 setup_logger 로 정합화 — INFO 대기 로그 가시화
...
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com >
2026-06-10 13:47:18 +09:00
hyungi
ab668d7990
fix(news): crawl_raw 파일명 CHAR(64) 패딩 strip + politeness 대기 로그
...
- documents.file_hash 실 컬럼이 character(64) — 32자 해시가 공백 패딩되어
gz 파일명에 공백 32개 포함 (실배포 1건 실측). _raw_html_path 에서 strip.
- _respect_domain_rate silent sleep 에 대기 로그 1줄 (검증 게이트·운영 가시성).
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com >
2026-06-10 13:43:29 +09:00
hyungi
7cd8cfde0a
feat(news): crawl-24x7 A그룹 — 레지스트리 증축·조건부 GET·fulltext 승격·politeness·source_health
...
A-3 migrations 319-323 (news_sources 9컬럼 + source_channel 'crawl' + process_stage 'fulltext' + source_health)
A-1 조건부 GET(ETag/Last-Modified 그대로 재전송)+콘텐츠 해시 변경감지, A-4 politeness 코어(per-domain 직렬+robots+정직UA),
A-2+A-7 fulltext_worker(4-tier 재사용·NAS crawl_raw gzip 보존·격하 경로·03:40 reconcile 안전망),
A-5 circuit breaker(3/10 임계, enabled 미터치), A-6 포털 전재 2차 dedup(제목+3일, 12자 게이트).
기존 소스 fulltext_policy='none' 기본 = 무회귀. plan crawl-24x7-1, 예외 박제 crawl-24x7-exec1-20260610.md
2026-06-10 13:03:31 +09:00