fix: 오늘 날씨 0~6시가 비면 전날 23시 발표를 다시 받아 채움
This commit is contained in:
1 parent
4ebf1cd894
commit
73294622ad
3 files changed
+58
-6
No files matched your search
@@ -52,6 +52,9 @@ class WeatherCRUD:
|
||||
async def latest_issued(self, s: AsyncSession, region_code: str) -> Optional[datetime]:
|
||||
return await s.scalar(select(func.max(WeatherHourly.issued_at)).where(WeatherHourly.region_code == region_code))
|
||||
|
||||
async def has_hourly_at(self, s: AsyncSession, region_code: str, at: datetime) -> bool:
|
||||
return await s.get(WeatherHourly, (region_code, at)) is not None
|
||||
|
||||
async def hourly_between(self, s: AsyncSession, region_code: str, start: datetime, end: datetime) -> list[WeatherHourly]:
|
||||
stmt = (
|
||||
select(WeatherHourly)
|
||||
|
||||
Reference in new issue
Block a user