Skip to content

Commit

Permalink
Fix error messages.
Browse files Browse the repository at this point in the history
  • Loading branch information
RolandMacDoland committed Jun 27, 2024
1 parent 2bbdc6a commit 4f2705b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions qadence/extensions.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ def _available_backends() -> dict[BackendName, Backend]:
try:
res[backend] = import_backend(backend)
except (ModuleNotFoundError, ImportError) as e:
raise type(e)(f"Failed to import backend {backend_name} due to {e}.") from e
raise type(e)(f"Failed to import backend {backend} due to {e}.") from e
logger.debug(f"Found backends: {res.keys()}")
return res

Expand All @@ -67,7 +67,7 @@ def _available_engines() -> dict[Engine, DifferentiableBackend]:
try:
res[engine] = import_engine(engine)
except (ModuleNotFoundError, ImportError) as e:
raise type(e)(f"Failed to import engine {engine_name} due to {e}.") from e
raise type(e)(f"Failed to import engine {engine} due to {e}.") from e
logger.debug(f"Found engines: {res.keys()}")
return res

Expand Down

0 comments on commit 4f2705b

Please sign in to comment.