curb-data-specification
curb-data-specification copied to clipboard
Add weeks_of_month to timespans for street cleaning
Is your feature request related to a problem? Please describe.
Cannot describe street cleaning that alternate weeks using existing timespans. Ex. 1st and 3rd week of month
Describe the solution you'd like
Add field weeks_of_month array to timespan that takes integers. 1 = 1st week, 2 = 2nd week...
Is this a breaking change
- No, not breaking
Impacted Spec
Curbs
Describe alternatives you've considered
Creating a designated_period for 1st week, 2nd week, etc. but this will make it harder to parse timespans for the purpose of detecting conflicts in policies with overlapping timespans and equal priority
How do you determine week 1 - Is it the week containing the 1st of the month, or the first full week of the month?
For this to work I think you would need to define what day weeks start on (Sun or Mon). ISO8601 uses Monday.
In this example, if weeks start on Mondays, and the month starts on the 1st:
Week 1 = March 1-2
Week 2 = March 3-9
Week 3 = March 10-16
Week 4 = March 17-23
Week 5 = March 24-30
Week 6 = March 31
6 weeks in a single month seems odd.
Good point. Perhaps a descriptor for the day of week, such as "1st", "2nd", "3rd", etc. would work. So, it would read like "1st & 3rd Monday of the month".
Need a name to be added to days_of_month field that is ordinal (1st, 2nd, 3rd, etc) in addition to specific cardinal dates (1, 2, 3, etc), used in conjunction with day_of_week.
https://github.com/openmobilityfoundation/curb-data-specification/tree/1.0.0/curbs#time-span
Check MDS for if this is in there.
Solved with this commit in PR #194.