-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Labels
bugSomething isn't workingSomething isn't workinggood first issueGood for newcomersGood for newcomers
Description
The input schema generator performs some validations like checking that types and descriptions exist etc...
It currently treats defaults like any other schema elements and therefore can raise validation issue that are not valid.
e.g. in the data-mapper connector, the map_one_value operation has a default value for the mappings input of:
default: [
{
type: 'object',
value: {
from: {
type: 'string',
value: '',
},
to: {
type: 'string',
value: '',
},
},
},
],This issues the following validation errors:
┌─────────┬─────────────────────────────────────────────┬───────────┬─────────────┬────────────────────┐
│ (index) │ key │ type │ description │ ending punctuation │
├─────────┼─────────────────────────────────────────────┼───────────┼─────────────┼────────────────────┤
│ 0 │ 'map_one_value.mappings.default.value' │ 'missing' │ │ │
│ 1 │ 'map_one_value.mappings.default.value' │ │ 'missing' │ │
│ 2 │ 'map_one_value.mappings.default.value.from' │ │ 'missing' │ │
│ 3 │ 'map_one_value.mappings.default.value.to' │ │ 'missing' │ │
└─────────┴─────────────────────────────────────────────┴───────────┴─────────────┴────────────────────┘
There should be no errors because the default values are not schema declarations, they are just values.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workinggood first issueGood for newcomersGood for newcomers