def get_devices(self, context, filters=None, fields=None): devices = self._get_collection(context, Device, self._make_device_dict, filters=filters, fields=fields) # Ugly hack to mask internaly used record return [ device for device in devices if uuidutils.is_uuid_like(device['id']) ]
def _validate_uuid(data, valid_values=None): if not uuidutils.is_uuid_like(data): msg = _("'%s' is not a valid UUID") % data LOG.debug(msg) return msg
def get_devices(self, context, filters=None, fields=None): devices = self._get_collection(context, Device, self._make_device_dict, filters=filters, fields=fields) # Ugly hack to mask internaly used record return [device for device in devices if uuidutils.is_uuid_like(device['id'])]