Skip to content

Commit

Permalink
src/reports.py: Use range instead of calendar.Day to support < 3.12
Browse files Browse the repository at this point in the history
  • Loading branch information
cbrxyz committed Sep 2, 2024
1 parent 9a234d8 commit e4ddbd4
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/reports.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@ class Column(IntEnum):
SCORE_COLUMN = 8


# Effectively: [calendar.MONDAY, calendar.TUESDAY, ..., calendar.SUNDAY]
EVERYDAY = list(range(7))


@dataclass
class WeekColumn:
"""
Expand Down Expand Up @@ -931,7 +935,7 @@ async def refresh_sheet(self) -> None:
],
)

@run_on_weekday(day=[*calendar.Day], hour=6, minute=0)
@run_on_weekday(day=EVERYDAY, hour=6, minute=0)
async def regular_refresh(self) -> None:
await self.refresh_sheet()

Expand Down

0 comments on commit e4ddbd4

Please sign in to comment.