From: Ritu Sood Date: Wed, 23 May 2018 14:18:45 +0000 (-0700) Subject: Fix matching issues for attribute block X-Git-Tag: v1.1.1^0 X-Git-Url: https://gerrit.onap.org/r/gitweb?a=commitdiff_plain;h=4d7952a6082d3bad5c5a931c491b94fa563b44a6;p=optf%2Fhas.git Fix matching issues for attribute block For cloud inventory type empty strings in the attribute block of the demand are being matched Issue-ID: OPTFRA-244 Change-Id: I0ac3a256f32ba497d9f74ddb8ca873604ca67773 Signed-off-by: Ritu Sood --- diff --git a/conductor/conductor/data/plugins/inventory_provider/aai.py b/conductor/conductor/data/plugins/inventory_provider/aai.py index b556ef7..4a9748d 100644 --- a/conductor/conductor/data/plugins/inventory_provider/aai.py +++ b/conductor/conductor/data/plugins/inventory_provider/aai.py @@ -741,6 +741,9 @@ class AAI(base.InventoryProviderBase): attribute_key == 'model-version-id'): continue + if not attribute_values: + continue + match_type = 'any' if type(attribute_values) is dict: if 'any' in attribute_values: