openmobilityfoundation / curb-data-specification

A data specification to help cities manage their curb zone programs and surrounding areas, and measure the utilization and impact.
https://www.openmobilityfoundation.org/about-cds/
Other
44 stars 15 forks source link

Representing Exception TimeSpans #117

Open josh-p-thompson opened 1 year ago

josh-p-thompson commented 1 year ago

Is your feature request related to a problem? Please describe.

There is no way to define and communicate an exception Time Span that includes periods of time, based on our reading of the Time Span spec (exception periods are "externally-defined").

Describe the solution you'd like

We would like

Example 1: Time Span to communicate that a rule does not apply on Sundays:

{
    'days_of_week': ['sun'],
    'designated_period_except': true, 
}

Example 2: Time Span to communicate that a rule does not apply on New Years Day:

{
    'days_of_mont': [1],
    'months': [1],
    'designated_period': "New Year's Day",
    'designated_period_except': true, 
}

Is this a breaking change

A breaking change would require consumers or implementors of an API to modify their code for it to continue to function (ex: renaming of a required field or the change in data type of an existing field). A non-breaking change would allow existing code to continue to function (ex: addition of an optional field or the creation of a new optional endpoint).

Impacted Spec

For which spec is this feature being requested?

Describe alternatives you've considered

There does not appear to be any other way to communicate the actual time period of the exception Time Span.

Additional context

schnuerle commented 1 year ago

We will be talking about this at next week's Working Group meeting for inclusion in a forthcoming CDS 1.0.1 patch release, so please attend if you can.

LaurentG-AMD commented 8 months ago

How did the discussion go? I was about to open the same issue when I saw this one since most regulations in Montreal are written as "No Parking except between X-Y" and this would definetly complicate updating the information later one if every regulation has to have it's logic reversed.

schnuerle commented 7 months ago

The meeting didn't lead to any concerns about adding this as a patch in the upcoming 1.0.1 release. Feel free to make a PR and speed this along. We may bring it up in tomorrow's end of year event.

schnuerle commented 4 months ago

If anyone wants to do a PR for this, that would be welcome and you and your org will be recognized in the acknowledgements for 1.0.1. Otherwise the OMF staff will make a PR soon.

schnuerle commented 1 month ago

There is a PR now #136. The question is, based on the comments there, is this a breaking change or not? Please look at the PR and discuss.

Also see issue #124 for a similar discussion. We should decide how to execute on this to determine if both issues and be addressed in a patch or a minor release.