fix: MLS 수집 중단·live 고착 경기 복구
- ESPN scoreboard 날짜 범위 조회가 400을 반환해 9/16부터 MLS 일정·결과·순위 수집이 전부 실패 → 일/월 단위 조회로 분할(_fetch_events) - MLB 연기·취소 경기는 abstractGameState 가 Final 로 와서 취소로 잡히지 않고 live 에 고착 → detailedState 만으로 취소 판정 - settle_baseball: 소스가 연기·취소로 보고하거나 소스 일정에서 사라진 (킥오프 후 24h 경과) 미정산 경기를 취소 처리. 수집 실패(빈 응답) 시에는 아무것도 취소하지 않음
This commit is contained in:
1 parent
bb930cc59f
commit
36742042f5
3 files changed
+106
-23
No files matched your search
@@ -107,7 +107,9 @@ async def _fetch_mlb(days_back: int, days_ahead: int) -> list[dict]:
|
||||
"dateKst": kickoff.strftime("%Y%m%d"),
|
||||
"kickoffKst": kickoff.isoformat(),
|
||||
"venue": (g.get("venue") or {}).get("name", ""),
|
||||
"cancelled": abstract != "Final" and detailed.startswith(
|
||||
# 연기·취소 경기도 abstractGameState 는 "Final" 로 온다(스코어 없음) —
|
||||
# 취소 여부는 abstract 와 무관하게 detailedState 로만 판정한다.
|
||||
"cancelled": detailed.startswith(
|
||||
("Postponed", "Cancelled", "Suspended")
|
||||
),
|
||||
"gamePk": g.get("gamePk"), # MLB 라이브 피드 키
|
||||
|
||||
Reference in new issue
Block a user