mfeckie / rrule

Elixr iCalendar RRule support
1 stars 1 forks source link

Wrong Sequence Generated for Africa/Cairo #2

Open theshapguy opened 4 months ago

theshapguy commented 4 months ago

Output

> RRule.all("DTSTART;TZID=Africa/Cairo:20240708T090024\nFREQ=WEEKLY;INTERVAL=1;BYDAY=MO;BYHOUR=08;BYMINUTE=00", 2)

> {:ok, [~U[2024-07-15 06:00:24Z], ~U[2024-07-22 06:00:24Z]]}

Expected Output

> {:ok, [~U[2024-07-15 05:00:24Z], ~U[2024-07-22 05:00:24Z]]}

The rrule is for 8am, BYHOUR=08. However, 06 AM (as generated by the function) in UTC is 09 AM in Africa/Cairo which is incorrect. It should be 5am.

I think it is due to the tz datatime that is currently being used. Would be willing to investigate it myself if you give the go ahead.

mfeckie commented 4 months ago

Feel free to take a look. This library calls our to the rust based rrule, so if there's an issue that's a good place to investigate