There are problems when one specifies start and stop with a time zone (e.g. 15:00 -0700) but also provides a location.
Specifically, it is neither well specified nor obvious what the behavior should be when the location is inconsistent with the time zone.
Even when the location is consistent with the time zone (e.g. America/Vancouver during PDT, which is -0700), the interpretation of start and stop is wrong. This is because func (*TimeOfDay) UnmarshalJSON for some reason converts start and stop to UTC before extracting hour and minute. This can easily be verified by running check with the following input at 00:30 -0700, which produces no new version:
There are problems when one specifies start and stop with a time zone (e.g.
15:00 -0700
) but also provides a location.Specifically, it is neither well specified nor obvious what the behavior should be when the location is inconsistent with the time zone.
Even when the location is consistent with the time zone (e.g.
America/Vancouver
during PDT, which is-0700
), the interpretation of start and stop is wrong. This is becausefunc (*TimeOfDay) UnmarshalJSON
for some reason converts start and stop to UTC before extracting hour and minute. This can easily be verified by runningcheck
with the following input at00:30 -0700
, which produces no new version:Due to all of the above, I think
check
should simply abort with error in such case.