Skip to content

Use key_properties = [] vs null per Singer spec

Niall requested to merge NiallRees/sdk:nw/primary_key_empty_list into main

Key properties is defined in the Singer spec to be:

key_properties - a list of strings indicating which properties make up the primary key for this stream. Each item in the list must be the name of a top-level property defined in the schema. An empty list may be used to indicate there is no primary key for the stream

Currently, empty lists or None types which are specified in the primary_key config of a stream are coerced into a null value when sent in the schema message. This MR changes that behaviour to always send an empty list [] whether the primary_key config is set to None or [].

Merge request reports