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
{{ message }}
Repository navigation
Reject empty asset link list in discovery PostAllAssetLinksById #689
Currently, POST /lookup/shells/{aasIdentifier} accepts an empty list [] as request body. post_all_asset_links_by_id then deletes the
existing links and add_specific_asset_ids_to_aas() stores an empty set for the AAS:
DiscoveryStore.to_file() persists the empty entry.
The specification defines the input parameter assetLinks of PostAllAssetLinksById as mandatory with cardinality 1..*, see IDTA-01002 v3.1.1, Operation PostAllAssetLinksById. Note that the OpenAPI file (V3.1_SSP-001.yaml) does not enforce this with minItems: 1, so a schema validator would not catch it.
The server should respond with 400 (ClientErrorBadRequest) to an empty list, without changing the stored asset links. A test should
cover this case.
Activity