freaktechnik / twitch-events-ical

Generate iCals for Twitch Events
https://twitch-events-ical.herokuapp.com/
MIT License
10 stars 4 forks source link

Timezone not explicitly defined #7

Closed BasO closed 6 years ago

BasO commented 6 years ago

Steps to reproduce:

(my timezone is set to Berlin time)

  1. check events of e.g. https://www.twitch.tv/lekkerspelen/events
  2. get channel's calendar url, i.e. https://twitch-events-ical.herokuapp.com/channel/52385053 and add url to calendar (in my case, Apple's native calendar).
  3. compare events' start/end time in calendar with events on the website.
freaktechnik commented 6 years ago

The calendar is in UTC, and should tell your client that it is in UTC. Sadly timezones and ical aren't friends...

freaktechnik commented 6 years ago

Actually, it doesn't seem to say that it is in UTC.

freaktechnik commented 6 years ago

I'll have to check this whenever I find some channel that actually has some events scheduled. The timestamp for the event should end with "Z" which would indicate that it is relative to UTC.

ryanmarkel commented 6 years ago

I just ran across this and verified that it doesn't do so; here's an example event from my channel's calendar:

BEGIN:VCALENDAR
VERSION:2.0
PRODID:twitchcal-channel/59192512
X-PUBLISHED-TTL:P1H
BEGIN:VEVENT
DTSTART:20180428T010000
DTEND:20180428T040000
SUMMARY:Friday Raid Night!
DESCRIPTION:Our usual suspects will run one of the two existing raid activi
 ties. (Or both of them?) Drop on by and learn something!
ORGANIZER;CN=backlogathon:noreply-backlogathon@twitch.tv
URL:https://twitch.tv/events/QfA1bOvOT0CMG9iBqdOIxw
UID:QfA1bOvOT0CMG9iBqdOIxw
TRANSP:TRANSPARENT
STATUS:CONFIRMED
CLASS:PUBLIC
LOCATION:https://twitch.tv/backlogathon
ATTACH;FMTTYPE=image/jpeg:https://static-cdn.jtvnw.net/twitch-event-images-
 v2/2a8caa46-4349-42dc-b4ad-2f4f805db3a1-640x360
CATEGORIES:backlogathon
END:VEVENT
freaktechnik commented 6 years ago

Thank you. I'll have to look into how I can convince the ical generator to add a trailing Z to the timestamps.

freaktechnik commented 6 years ago

There should now be trailing Z in the timestamps (some may still be cached when I write this, cache holds for max 1h) to indicate UTC time.

freaktechnik commented 6 years ago

Example:

BEGIN:VCALENDAR
VERSION:2.0
PRODID:twitchcal-channel/10817445
X-PUBLISHED-TTL:P1H
REFRESH-INTERVAL;VALUE=DURATION:P1H
SOURCE;VALUE=URI:https://twitch-events-ical.herokuapp.com/channel/10817445
BEGIN:VEVENT
DTSTART:2018-09-20T19:00:00.000Z
DTEND:2018-09-20T22:00:00.000Z
SUMMARY:Rollplay: Oddballs
DESCRIPTION:.
ORGANIZER;CN=itmeJP:noreply-itmejp@twitch.tv
URL:https://twitch.tv/events/hp2JdRaXTxami-Uabipr6A
UID:hp2JdRaXTxami-Uabipr6A
TRANSP:TRANSPARENT
STATUS:CONFIRMED
CLASS:PUBLIC
LOCATION;VALUE=URI:https://twitch.tv/itmejp
ATTACH;FMTTYPE=image/jpeg:https://static-cdn.jtvnw.net/twitch-event-images-
 v2/fe9753cb-1068-411a-9dc0-a0c89651dc02-640x360
IMAGE;FMTTYPE=image/jpeg;DISPLAY=FULLSIZE;VALUE=URI:https://static-cdn.jtvn
 w.net/twitch-event-images-v2/fe9753cb-1068-411a-9dc0-a0c89651dc02-640x360
IMAGE;DISPLAY=BADGE;VALUE=URI:https://static-cdn.jtvnw.net/jtv_user_picture
 s/itmejp-profile_image-64703923f21827e3-300x300.png
CATEGORIES:itmeJP
END:VEVENT
END:VCALENDAR