You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the Bug
The schemaV1 is currently not up to date with the one from the specification (e.g. spec schema contains source minLength 1, SDK schema doesn't). Therefore, event.validate() does for instance not throw when source is an empty string.
Steps to Reproduce
Use the following snippet:
constevent=newCloudEvent({id: '0815',specversion: '1.0',type: 'my.event.type',source: '',})constvalidated=event.validate()// does not throwconsole.log(validated)// true
Expected Behavior
Schema should be up to date so that event.validate() throws accordingly.