eclipse-ditto / ditto

Eclipse Ditto™: Digital Twin framework of Eclipse IoT - main repository

Home Page:https://eclipse.dev/ditto/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Default value for `date-time` format in referenced WoT ThingModel is generated as empty string

thjaeckle opened this issue · comments

Currently, when Ditto generates the JSON Skeleton for a Thing when a WoT "ThingModel" is referenced in the "definition" field on creation, non-optional properties with:

{
  "type": "string",
  "format": "date-time"
}

Are generated as:

"propertyName": ""

-> which is the "neutral element" for Strings.

We should however generate the "neutral element" for dates, which IMO would be EPOCH:

"propertyName": "1970-01-01T00:00:00Z"