Closed jgat closed 9 years ago
I think the best solution is for the server to store due dates in UTC.
The tutorial creation script can handle the conversion.
I agree - it's a one-time conversion
@jgat Did you intend the hacky fix in 1bcb282 to fix this, or to be undone when we apply a proper fix?
That's only semi-relevant to this issue (that fix was for the web-view of submissions for issue #87). I made that change when I was very tired and wasn't bothered to find out if there was a better way to do timezone conversion (I hope that there is a better way, but I'm not sure). That fix should be readded into the progress script.
It's probably not that hacky, something like that should go in the script which generates the due-dates that get stored on the server.
Gotcha. I normally use pytz
, combined with dateutil
where necessary, but I'm yet to see timezone code anywhere which doesn't look hacky in some form or another :P
I'll add it into the due dates script when I get a chance.
When a user submits a task, the web server takes the current timestamp in UTC, but the due dates (17:00 on the respective days) are stored on the server in UTC+10. This timezone difference doesn't appear to be accounted for in the server code, meaning that students can submit code "on time" up to 10 hours after the intended deadline.