Add DST (Daylight Saving Time) support for Ava timezone

t-537·WorkTask·
·
·
Created3 weeks ago·Updated3 weeks ago

Description

Edit

Currently Ava uses hardcoded EST (UTC-5) year-round. During Daylight Saving Time (roughly March-November), it should use EDT (UTC-4).

Current Code

Omni/Ava/Telegram/Bot.hs has:

let easternTZ = minutesToTimeZone (-300) -- Eastern Standard Time

Options

1. Use tz library - Add tz or timezone-olson package to read system timezone files 2. Simple date check - Check if current date falls within DST period (2nd Sunday March - 1st Sunday November) 3. Environment variable - Set TZ in systemd service and use getCurrentTimeZone

Files

  • Omni/Ava/Telegram/Bot.hs - main timezone usage (lines 1072, 1498)
  • Omni/Ava/Telegram/Heartbeat.hs - also uses timezone

Context

The systemd service doesn't inherit system timezone properly, which is why we hardcoded it.

Timeline (2)

🔄[human]Open → InProgress3 weeks ago
🔄[human]InProgress → Done3 weeks ago