diff --git a/src/qibolab/backends.py b/src/qibolab/backends.py index fc6aa4d9e..5baaa3921 100644 --- a/src/qibolab/backends.py +++ b/src/qibolab/backends.py @@ -1,4 +1,5 @@ from collections import deque +from typing import Union import numpy as np from qibo import __version__ as qibo_version @@ -51,11 +52,11 @@ def __init__(self, platform): self.compiler = Compiler.default() @property - def qubits(self) -> list[str | int]: + def qubits(self) -> list[Union[str, int]]: return list(self.platform.qubits.keys()) @property - def connectivity(self) -> list[tuple[str | int, str | int]]: + def connectivity(self) -> list[tuple[Union[str, int], Union[str, int]]]: return list(self.platform.pairs) @property