Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
name: Name of the requested backend.
**kwargs: Used for filtering, not implemented.
Returns:
List of backends that meet the filter requirements.
"""
if self._api is None:
raise ApiError('Authentication details have not been set.')
available_backends = self._api.get_backend_types()
if name is not None:
available_backends = list(filter(lambda b: b['name'] == name, available_backends))
backends = []
for backend in available_backends:
if backend['is_allowed']:
config = copy(QuantumInspireBackend.DEFAULT_CONFIGURATION)
self._adjust_backend_configuration(config, backend)
backends.append(QuantumInspireBackend(self._api, provider=self, configuration=config))
return backends