nori icon indicating copy to clipboard operation
nori copied to clipboard

[Issue #22] consider time as local if no offset is given

Open robuye opened this issue 11 years ago • 3 comments

it uses ENV['TZ'] or can be passed as an option (global), if something goes wrong (no env var or unknown timezone) it will fallback to UTC. It's not perfect, but i don't have better idea.

Added facets/date dependency. Also added pry as development dependency, its really helpful.

robuye avatar Jun 18 '13 21:06 robuye

thanks @robuye!

can this change be backed by a specification? that would be something to put in the changelog for everyone to follow through as this change probably affects a lot of people. also, timezone changes might not break people's tests and they surely don't expect them. there are people that don't review libraries before updating and this could possibly result in very nasty surprises.

what do you think? what do others think?

rubiii avatar Jun 18 '13 22:06 rubiii

good point about affecting others, I didn't think about it. As @cschiewek described, ISO8601 specifies that timezone without offset should be considered as local:

(...)Without any further additions, a date and time as written above is assumed to be in some local time zone.

I think it would be good idea to wait some time and possibly get feedback, this is not an urgent fix.

robuye avatar Jun 19 '13 00:06 robuye

good idea. thanks.

rubiii avatar Jun 19 '13 17:06 rubiii