[Talk-us] Updating opening_hours for COVID-19.

Jmapb jmapb at gmx.com
Thu Mar 19 16:55:27 UTC 2020


On 3/19/2020 10:43 AM, Eric H. Christensen via Talk-us wrote:
> Sure, I get that. The flip side is that it is likely to get confusing
> what is open and when with all the changes occurring. It would be good
> to have a resource to help people determine where they can go if they
> need something.

When interpreting opening_hours, software (and humans reading manually!)
should follow the LAST of semicolon-separated rules that matches a
particular datetime. So if you expect normal hours to resume at some
point, it's possible to encode temporary hours using exceptions appended
to the end of the value.

For example, a shop with "opening_hours=Mo-Fr 10:00-20:00" could be
retagged "opening_hours=Mo-Fr 10:00-20:00; 2020 Mar-May Mo-Fr 11:00-16:00".

Problems apparent offhand:
  - You have to pick an end date. Will "this all be over" by the end of
the year? End of the summer? Or do you want to recheck each POI every month?
  - No idea if any software actually correctly interprets adding years
as part of the date range, though it is part of the spec.
  - If hours are different for different days of the week, each weekday
or weekday range needs its own override. (Eg, opening_hours=Mo-Th
10:00-20:00; Fr 10:00-21:00; Sa 12:00-21:00; Su 12:00-20:00; 2020
Mar-May Mo-Th 11:00-16:00; 2020 Mar-May Fr 11:00-17:00; 2020 Mar-May Sa
12:00-17:00; 2020 Mar-May Su 12:00-16:00") The value can easily become
unwieldy bordering on absurd, and risks going over the 255 char limit.
  - Especially if the value is long and complex, it's hard for humans to
read. We don't tend to read through the entire list and look for
possible exceptions once we've found a match. Not to mention that no
other tag values in OSM use semicolons in this way. (We don't look at
"cuisine=italian;pizza" and think "This place serves pizza, which
overrides other Italian food, so don't go here for spaghetti".)

Jason




More information about the Talk-us mailing list