8000 FixedTZ timezone handling inconsistent with documentation · Issue #432 · google/cel-spec · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
FixedTZ timezone handling inconsistent with documentation #432
Open
@warhammerkid

Description

@warhammerkid

In both langdef.md and in cel-go, the initial + | - is documented as not optional:

  • landef.md: FixedTZ = ( "+" | "-" ) Digit Digit ":" Digit Digit ;
  • cel-go: in the format ^(+|-)(0[0-9]|1[0-4]):[0-5][0-9]$.

However, there is a conformance test where the initial + is missing.

Is there a preference for which of these is more correct? For Ruby we're currently using getlocal to handle the FixedTZ string, and it also expects the initial + to be there, although I can certainly swap to a different parsing approach.

> Time.now.getlocal("02:00")
(irb):2:in 'Time#getlocal': "+HH:MM", "-HH:MM", "UTC" or "A".."I","K".."Z" expected for utc_offset: 02:00 (ArgumentError)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0