From e972cbc4071e1b838ce1640a50dbd85532d43679 Mon Sep 17 00:00:00 2001 From: Felipe Vicens Date: Fri, 22 May 2020 15:14:31 +0200 Subject: [PATCH] Fix #1076 slice instantiation without CP in NSD fail Change-Id: I7a62b7d73fc57fa5c3630475043eb6dd39fc2ef5 Signed-off-by: Felipe Vicens --- osm_lcm/netslice.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osm_lcm/netslice.py b/osm_lcm/netslice.py index fe8a7b9a..4d731afe 100644 --- a/osm_lcm/netslice.py +++ b/osm_lcm/netslice.py @@ -248,7 +248,7 @@ class NetsliceLcm(LcmBase): if nss_cp_item["nss-ref"] == nss["nss-id"]: db_nsds = self.db.get_one("nsds", {"_id": nss["nsdId"]}) # Go for nsd, and search the CP that match with nst:CP to get vld-id-ref - for cp_nsd in db_nsds["connection-point"]: + for cp_nsd in db_nsds.get("connection-point", ()): if cp_nsd["name"] == nss_cp_item["nsd-connection-point-ref"]: if nslcmop.get("operationParams"): if nslcmop["operationParams"].get("nsName") == nss["nsName"]: -- 2.25.1