Bug 445824 - Combine same day ranges
Summary: Combine same day ranges
Status: REPORTED
Alias: None
Product: KOpeningHours
Classification: Applications
Component: normalization (other bugs)
Version First Reported In: unspecified
Platform: Other Other
: NOR minor
Target Milestone: ---
Assignee: David Faure
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-11-20 16:31 UTC by HubMiner
Modified: 2021-11-26 19:48 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description HubMiner 2021-11-20 16:31:50 UTC
Consider this actual value (multiple roads in Los Angeles):
Mo-Fr 05:00-09:00; Mo-Fr 16:00-19:00; Mo-Fr 00:00-05:00; Mo-Fr 09:00-16:00; Mo-Fr 19:00-00:00; Sa-Su

For insane values like these, it would be helpful if the ranges were (1) sorted and (2) combined:

(1) sorted
Mo-Fr 00:00-05:00,05:00-09:00,09:00-16:00,16:00-19:00,19:00-00:00; Sa-Su

(2.a) combined:
Mo-Fr 00:00-24:00; Sa-Su

Note, I see a lot of strange examples with overlapping time ranges, suggesting editor may have missed day specifier.  Do not combine times automatically if there is an overlap (too suspicious), for example: 10:00-13:00,12:00-15:00

(2.b) combined as a special case:
24/7


This is nice-to-have and probably hard to implement - setting a lower severity.
Comment 1 HubMiner 2021-11-26 19:48:20 UTC
An extra UT (combine days, one day different. one day not specified)
IN:  Mo 09:30-12:00,16:00-19:00; We 09:30-12:00; Th 09:30-12:00,16:00-19:00; Sa-Su 09:30-12:00,16:00-19:00
OUT: Mo,Th,Sa,Su 09:30-12:00,16:00-19:00; We 09:30-12:00