def _extend_or_set_attribute(self, existing_image, image, attribute_name):
        attribute = image.get(attribute_name, [])
        if attribute:
            try:
                existing_image[attribute_name].extend(attribute)
            except __HOLE__:
                existing_image[attribute_name] = attribute
dataset/ETHPy150Open openstack/tripleo-common/tripleo_common/image/base.py/BaseImageManager._extend_or_set_attribute