diff --git a/graphqomb/euler.py b/graphqomb/euler.py index 0b4e0bb9..13767d85 100644 --- a/graphqomb/euler.py +++ b/graphqomb/euler.py @@ -130,7 +130,7 @@ def __init__(self, alpha: float = 0, beta: float = 0, gamma: float = 0) -> None: def print_angles(self) -> None: """Print the Euler angles.""" - print(f"alpha: {self.alpha}, beta: {self.beta}, gamma: {self.gamma}") # noqa: T201 + print(f"alpha: {self.alpha}, beta: {self.beta}, gamma: {self.gamma}") # ruff:ignore[print] def conjugate(self) -> LocalUnitary: """Return the conjugate of the `LocalUnitary` object. diff --git a/graphqomb/feedforward.py b/graphqomb/feedforward.py index 395b0f01..4118a10c 100644 --- a/graphqomb/feedforward.py +++ b/graphqomb/feedforward.py @@ -83,7 +83,7 @@ def dag_from_flow( ------ TypeError If the flowlike object is not a Flow or GFlow - """ # noqa: E501 + """ # ruff:ignore[line-too-long] dag: dict[int, set[int]] = {} output_nodes = set(graph.output_node_indices) non_output_nodes = graph.nodes - output_nodes @@ -202,7 +202,7 @@ def check_flow( The X correction flow (flow and gflow are included) zflow : `collections.abc.Mapping`\[`int`, `int`\] | `collections.abc.Mapping`\[`int`, `collections.abc.Set`\[`int`\]\] | `None` The Z correction flow. If `None`, it is generated from xflow by odd neighbors. - """ # noqa: E501 + """ # ruff:ignore[line-too-long] dag = dag_from_flow(graph, xflow, zflow) check_dag(dag) @@ -245,7 +245,7 @@ def signal_shifting( return new_xflow, new_zflow -def propagate_correction_map( # noqa: C901, PLR0912 +def propagate_correction_map( # ruff:ignore[complex-structure, too-many-branches] target_node: int, graph: BaseGraphState, xflow: Mapping[int, AbstractSet[int]], @@ -331,7 +331,7 @@ def propagate_correction_map( # noqa: C901, PLR0912 return new_xflow, new_zflow -def pauli_simplification( # noqa: C901, PLR0912 +def pauli_simplification( # ruff:ignore[complex-structure, too-many-branches] graph: BaseGraphState, xflow: Mapping[int, AbstractSet[int]], zflow: Mapping[int, AbstractSet[int]] | None = None, diff --git a/graphqomb/focus_flow.py b/graphqomb/focus_flow.py index 365ee8e1..3e4a85d8 100644 --- a/graphqomb/focus_flow.py +++ b/graphqomb/focus_flow.py @@ -41,7 +41,7 @@ def is_focused(flowlike: Mapping[int, int] | Mapping[int, AbstractSet[int]], gra ------ TypeError If the flowlike object is not a Flow or GFlow - """ # noqa: E501 + """ # ruff:ignore[line-too-long] meas_bases = graph.meas_bases outputs = set(graph.output_node_indices) @@ -88,7 +88,7 @@ def focus_gflow( ------ TypeError If the flowlike object is not a Flow or GFlow - """ # noqa: E501 + """ # ruff:ignore[line-too-long] if _is_flow(flowlike): flowlike = {key: {value} for key, value in flowlike.items()} elif _is_gflow(flowlike): diff --git a/graphqomb/gates.py b/graphqomb/gates.py index 9dc6b12a..9e4aaa3f 100644 --- a/graphqomb/gates.py +++ b/graphqomb/gates.py @@ -166,7 +166,7 @@ def unit_gates(self) -> list[UnitGate]: """ return [self] - def matrix( # noqa: PLR6301 + def matrix( # ruff:ignore[no-self-use] self, ) -> NDArray[np.complex128]: r"""Get the `matrix` representation of the gate. @@ -267,7 +267,7 @@ def unit_gates(self) -> list[UnitGate]: """ return [J(self.qubit, 0), J(self.qubit, 0)] - def matrix(self) -> NDArray[np.complex128]: # noqa: PLR6301 + def matrix(self) -> NDArray[np.complex128]: # ruff:ignore[no-self-use] r"""Get the `matrix` representation of the gate. Returns @@ -308,7 +308,7 @@ def unit_gates(self) -> list[UnitGate]: """ return [J(self.qubit, 0), J(self.qubit, math.pi)] - def matrix(self) -> NDArray[np.complex128]: # noqa: PLR6301 + def matrix(self) -> NDArray[np.complex128]: # ruff:ignore[no-self-use] r"""Get the `matrix` representation of the gate. Returns @@ -354,7 +354,7 @@ def unit_gates(self) -> list[UnitGate]: J(self.qubit, 0), ] - def matrix(self) -> NDArray[np.complex128]: # noqa: PLR6301 + def matrix(self) -> NDArray[np.complex128]: # ruff:ignore[no-self-use] r"""Get the `matrix` representation of the gate. Returns @@ -395,7 +395,7 @@ def unit_gates(self) -> list[UnitGate]: """ return [J(self.qubit, math.pi), J(self.qubit, 0)] - def matrix(self) -> NDArray[np.complex128]: # noqa: PLR6301 + def matrix(self) -> NDArray[np.complex128]: # ruff:ignore[no-self-use] r"""Get the `matrix` representation of the gate. Returns @@ -436,7 +436,7 @@ def unit_gates(self) -> list[UnitGate]: """ return [J(self.qubit, 0)] - def matrix(self) -> NDArray[np.complex128]: # noqa: PLR6301 + def matrix(self) -> NDArray[np.complex128]: # ruff:ignore[no-self-use] r"""Get the `matrix` representation of the gate. Returns @@ -478,7 +478,7 @@ def unit_gates(self) -> list[UnitGate]: """ return [J(self.qubit, math.pi / 2), J(self.qubit, 0)] - def matrix(self) -> NDArray[np.complex128]: # noqa: PLR6301 + def matrix(self) -> NDArray[np.complex128]: # ruff:ignore[no-self-use] r"""Get the `matrix` representation of the gate. Returns @@ -519,7 +519,7 @@ def unit_gates(self) -> list[UnitGate]: """ return [J(self.qubit, math.pi / 4), J(self.qubit, 0)] - def matrix(self) -> NDArray[np.complex128]: # noqa: PLR6301 + def matrix(self) -> NDArray[np.complex128]: # ruff:ignore[no-self-use] r"""Get the `matrix` representation of the gate. Returns @@ -560,7 +560,7 @@ def unit_gates(self) -> list[UnitGate]: """ return [J(self.qubit, -math.pi / 4), J(self.qubit, 0)] - def matrix(self) -> NDArray[np.complex128]: # noqa: PLR6301 + def matrix(self) -> NDArray[np.complex128]: # ruff:ignore[no-self-use] r"""Get the `matrix` representation of the gate. Returns @@ -830,7 +830,7 @@ def unit_gates(self) -> list[UnitGate]: J(target, 0), ] - def matrix(self) -> NDArray[np.complex128]: # noqa: PLR6301 + def matrix(self) -> NDArray[np.complex128]: # ruff:ignore[no-self-use] r"""Get the `matrix` representation of the gate. Returns @@ -885,7 +885,7 @@ def unit_gates(self) -> list[UnitGate]: unit_gates.extend(macro_gate.unit_gates()) return unit_gates - def matrix(self) -> NDArray[np.complex128]: # noqa: PLR6301 + def matrix(self) -> NDArray[np.complex128]: # ruff:ignore[no-self-use] r"""Get the `matrix` representation of the gate. Returns @@ -1170,7 +1170,7 @@ def unit_gates(self) -> list[UnitGate]: unit_gates.extend(macro_gate.unit_gates()) return unit_gates - def matrix(self) -> NDArray[np.complex128]: # noqa: PLR6301 + def matrix(self) -> NDArray[np.complex128]: # ruff:ignore[no-self-use] r"""Get the `matrix` representation of the gate. Returns @@ -1238,7 +1238,7 @@ def unit_gates(self) -> list[UnitGate]: unit_gates.extend(macro_gate.unit_gates()) return unit_gates - def matrix(self) -> NDArray[np.complex128]: # noqa: PLR6301 + def matrix(self) -> NDArray[np.complex128]: # ruff:ignore[no-self-use] r"""Get the `matrix` representation of the gate. Returns diff --git a/graphqomb/graphstate.py b/graphqomb/graphstate.py index 37c5853a..4ed44917 100644 --- a/graphqomb/graphstate.py +++ b/graphqomb/graphstate.py @@ -746,7 +746,7 @@ def _expand_output_local_cliffords(self) -> dict[int, LocalCliffordExpansion]: return node_index_addition_map @classmethod - def from_graph( # noqa: C901, PLR0912, PLR0913, PLR0917 + def from_graph( # ruff:ignore[complex-structure, too-many-branches, too-many-arguments, too-many-positional-arguments] cls, nodes: Iterable[NodeT], edges: Iterable[tuple[NodeT, NodeT]], @@ -946,7 +946,7 @@ class ExpansionMaps(NamedTuple): output_node_map: dict[int, LocalCliffordExpansion] -def compose( # noqa: C901, PLR0912 +def compose( # ruff:ignore[complex-structure, too-many-branches] graph1: BaseGraphState, graph2: BaseGraphState ) -> tuple[GraphState, dict[int, int], dict[int, int]]: r"""Compose two graph states sequentially. diff --git a/graphqomb/greedy_scheduler.py b/graphqomb/greedy_scheduler.py index 942f18d8..f47c6e1c 100644 --- a/graphqomb/greedy_scheduler.py +++ b/graphqomb/greedy_scheduler.py @@ -25,7 +25,7 @@ from graphqomb.graphstate import BaseGraphState -def greedy_minimize_time( # noqa: PLR0914 +def greedy_minimize_time( # ruff:ignore[too-many-locals] graph: BaseGraphState, dag: Mapping[int, AbstractSet[int]], max_qubit_count: int | None = None, @@ -163,7 +163,7 @@ def greedy_minimize_time( # noqa: PLR0914 return prepare_time, measure_time -def _prepare_remaining_nodes_at_tail( # noqa: PLR0913 +def _prepare_remaining_nodes_at_tail( # ruff:ignore[too-many-arguments] current_time: int, *, nodes: AbstractSet[int], @@ -191,7 +191,7 @@ def _prepare_remaining_nodes_at_tail( # noqa: PLR0913 alive.update(remaining) -def _phase1_measure_ready_nodes( # noqa: PLR0913 +def _phase1_measure_ready_nodes( # ruff:ignore[too-many-arguments] current_time: int, *, dag: Mapping[int, AbstractSet[int]], @@ -251,7 +251,7 @@ def _has_initial_input_input_entanglement_wait( return False -def _phase2_prepare_nodes_with_slack( # noqa: PLR0913 +def _phase2_prepare_nodes_with_slack( # ruff:ignore[too-many-arguments] current_time: int, *, nodes: AbstractSet[int], @@ -364,7 +364,7 @@ def _get_prep_candidates_with_priority( return scores -def greedy_minimize_space( # noqa: PLR0914 +def greedy_minimize_space( # ruff:ignore[too-many-locals] graph: BaseGraphState, dag: Mapping[int, AbstractSet[int]], ) -> tuple[dict[int, int], dict[int, int]]: diff --git a/graphqomb/noise_model.py b/graphqomb/noise_model.py index 4ec66393..41ae6820 100644 --- a/graphqomb/noise_model.py +++ b/graphqomb/noise_model.py @@ -273,14 +273,14 @@ class Coordinate: @property def xy(self) -> tuple[float, float] | None: """The first two dimensions as (x, y), or None if fewer than 2 dimensions.""" - if len(self.values) < 2: # noqa: PLR2004 + if len(self.values) < 2: # ruff:ignore[magic-value-comparison] return None return (self.values[0], self.values[1]) @property def xyz(self) -> tuple[float, float, float] | None: """The first three dimensions as (x, y, z), or None if fewer than 3 dimensions.""" - if len(self.values) < 3: # noqa: PLR2004 + if len(self.values) < 3: # ruff:ignore[magic-value-comparison] return None return (self.values[0], self.values[1], self.values[2]) @@ -758,7 +758,7 @@ class NoiseModel: """ - def on_prepare(self, event: PrepareEvent) -> Sequence[NoiseOp]: # noqa: ARG002, PLR6301 + def on_prepare(self, event: PrepareEvent) -> Sequence[NoiseOp]: # ruff:ignore[unused-method-argument, no-self-use] r"""Return noise operations to inject at qubit preparation. Parameters @@ -773,7 +773,7 @@ def on_prepare(self, event: PrepareEvent) -> Sequence[NoiseOp]: # noqa: ARG002, """ return [] - def on_entangle(self, event: EntangleEvent) -> Sequence[NoiseOp]: # noqa: ARG002, PLR6301 + def on_entangle(self, event: EntangleEvent) -> Sequence[NoiseOp]: # ruff:ignore[unused-method-argument, no-self-use] r"""Return noise operations to inject at entanglement. Parameters @@ -788,7 +788,7 @@ def on_entangle(self, event: EntangleEvent) -> Sequence[NoiseOp]: # noqa: ARG00 """ return [] - def on_measure(self, event: MeasureEvent) -> Sequence[NoiseOp]: # noqa: ARG002, PLR6301 + def on_measure(self, event: MeasureEvent) -> Sequence[NoiseOp]: # ruff:ignore[unused-method-argument, no-self-use] r"""Return noise operations to inject at measurement. Parameters @@ -803,7 +803,7 @@ def on_measure(self, event: MeasureEvent) -> Sequence[NoiseOp]: # noqa: ARG002, """ return [] - def on_idle(self, event: IdleEvent) -> Sequence[NoiseOp]: # noqa: ARG002, PLR6301 + def on_idle(self, event: IdleEvent) -> Sequence[NoiseOp]: # ruff:ignore[unused-method-argument, no-self-use] r"""Return noise operations to inject during idle periods. Parameters @@ -819,7 +819,7 @@ def on_idle(self, event: IdleEvent) -> Sequence[NoiseOp]: # noqa: ARG002, PLR63 return [] -def noise_op_to_stim(op: NoiseOp) -> tuple[str, int]: # noqa: PLR0911, C901 +def noise_op_to_stim(op: NoiseOp) -> tuple[str, int]: # ruff:ignore[too-many-return-statements, complex-structure] r"""Convert a NoiseOp into a Stim instruction line and record delta. Parameters @@ -913,7 +913,7 @@ def _normalize_pauli_channel_2_sequence(probabilities: Sequence[float]) -> tuple def _normalize_pauli_channel_2_targets(targets: Sequence[tuple[int, int]]) -> tuple[tuple[int, int], ...]: normalized: list[tuple[int, int]] = [] for pair in targets: - if len(pair) != 2: # noqa: PLR2004 + if len(pair) != 2: # ruff:ignore[magic-value-comparison] msg = f"PAULI_CHANNEL_2 targets must be pairs, got: {pair!r}" raise ValueError(msg) normalized.append((pair[0], pair[1])) @@ -923,7 +923,7 @@ def _normalize_pauli_channel_2_targets(targets: Sequence[tuple[int, int]]) -> tu def _flatten_pairs(pairs: Sequence[tuple[int, int]]) -> tuple[int, ...]: flat: list[int] = [] for pair in pairs: - if len(pair) != 2: # noqa: PLR2004 + if len(pair) != 2: # ruff:ignore[magic-value-comparison] msg = f"PAULI_CHANNEL_2 targets must be pairs, got: {pair!r}" raise ValueError(msg) flat.extend(pair) diff --git a/graphqomb/ptn_format.py b/graphqomb/ptn_format.py index 8765e667..2c16d12c 100644 --- a/graphqomb/ptn_format.py +++ b/graphqomb/ptn_format.py @@ -365,7 +365,7 @@ def _parse_node_qubit_pairs(parts: Sequence[str]) -> dict[int, int]: result: dict[int, int] = {} for part in parts: pair = part.split(":") - if len(pair) != 2: # noqa: PLR2004 + if len(pair) != 2: # ruff:ignore[magic-value-comparison] msg = f"Invalid node:qubit pair: {part!r}" raise ValueError(msg) node_str, qidx_str = pair @@ -419,7 +419,7 @@ def _parse_arrow_mapping(line: str, label: str) -> tuple[int, set[int]]: If the mapping is malformed. """ parts = line.split("->") - if len(parts) != 2: # noqa: PLR2004 + if len(parts) != 2: # ruff:ignore[magic-value-comparison] msg = f"{label} must contain exactly one '->'" raise ValueError(msg) source_part = parts[0].strip() @@ -860,7 +860,7 @@ def _parse_n_command(self, parts: Sequence[str]) -> None: msg = "N command requires a node and optional 2D or 3D coordinates" raise ValueError(msg) node = _parse_int(parts[1], "node") - coord: tuple[float, ...] | None = _parse_coord(parts[2:]) if len(parts) > 2 else None # noqa: PLR2004 + coord: tuple[float, ...] | None = _parse_coord(parts[2:]) if len(parts) > 2 else None # ruff:ignore[magic-value-comparison] self.result.commands.append(N(node=node, coordinate=coord)) def _parse_e_command(self, parts: Sequence[str]) -> None: @@ -871,7 +871,7 @@ def _parse_e_command(self, parts: Sequence[str]) -> None: ValueError If the command is malformed. """ - if len(parts) != 3: # noqa: PLR2004 + if len(parts) != 3: # ruff:ignore[magic-value-comparison] msg = "E command requires exactly two nodes" raise ValueError(msg) node1 = _parse_int(parts[1], "node") @@ -886,7 +886,7 @@ def _parse_m_command(self, parts: Sequence[str]) -> None: ValueError If the command is malformed. """ - if len(parts) != 4: # noqa: PLR2004 + if len(parts) != 4: # ruff:ignore[magic-value-comparison] msg = "M command requires a node, basis, and angle/sign" raise ValueError(msg) node = _parse_int(parts[1], "node") diff --git a/graphqomb/qompiler.py b/graphqomb/qompiler.py index d49dec39..3abc1d37 100644 --- a/graphqomb/qompiler.py +++ b/graphqomb/qompiler.py @@ -26,7 +26,7 @@ from graphqomb.graphstate import BaseGraphState -def qompile( # noqa: PLR0913 +def qompile( # ruff:ignore[too-many-arguments] graph: BaseGraphState, xflow: Mapping[int, AbstractSet[int]], zflow: Mapping[int, AbstractSet[int]] | None = None, diff --git a/graphqomb/rng.py b/graphqomb/rng.py index a3302c4a..98760f3a 100644 --- a/graphqomb/rng.py +++ b/graphqomb/rng.py @@ -36,5 +36,5 @@ def ensure_rng(rng: Generator | None = None) -> Generator: return stored rng = np.random.default_rng() # MEMO: Cannot perform type check - setattr(_rng_local, "rng", rng) # noqa: B010 + setattr(_rng_local, "rng", rng) # ruff:ignore[set-attr-with-constant] return rng diff --git a/graphqomb/scheduler.py b/graphqomb/scheduler.py index 177bf818..77d15bd1 100644 --- a/graphqomb/scheduler.py +++ b/graphqomb/scheduler.py @@ -38,7 +38,7 @@ class TimeSlice(NamedTuple): measure_nodes: set[int] #: Set of node indices to measure in this time slice. -def compress_schedule( # noqa: C901, PLR0912 +def compress_schedule( # ruff:ignore[complex-structure, too-many-branches] prepare_time: Mapping[int, int | None], measure_time: Mapping[int, int | None], entangle_time: Mapping[tuple[int, int], int | None] | None = None, diff --git a/graphqomb/simulator.py b/graphqomb/simulator.py index 1d523dbb..0ecde0f6 100644 --- a/graphqomb/simulator.py +++ b/graphqomb/simulator.py @@ -168,12 +168,12 @@ def apply_cmd(self, cmd: Command, *, rng: np.random.Generator) -> None: self.apply_cmd(cmd, rng=rng) @apply_cmd.register - def _(self, cmd: N, *, rng: np.random.Generator) -> None: # noqa: ARG002 + def _(self, cmd: N, *, rng: np.random.Generator) -> None: # ruff:ignore[unused-method-argument] self.state.add_node(1) self.node_indices.append(cmd.node) @apply_cmd.register - def _(self, cmd: E, *, rng: np.random.Generator) -> None: # noqa: ARG002 + def _(self, cmd: E, *, rng: np.random.Generator) -> None: # ruff:ignore[unused-method-argument] node_id1 = self.node_indices.index(cmd.nodes[0]) node_id2 = self.node_indices.index(cmd.nodes[1]) self.state.entangle(node_id1, node_id2) diff --git a/graphqomb/visualizer.py b/graphqomb/visualizer.py index a714fad8..75bba3ec 100644 --- a/graphqomb/visualizer.py +++ b/graphqomb/visualizer.py @@ -63,7 +63,7 @@ class FigureSetup(NamedTuple): fig_height: float -def visualize( # noqa: PLR0913 +def visualize( # ruff:ignore[too-many-arguments] graph: BaseGraphState, *, ax: Axes | None = None, diff --git a/graphqomb/zx_util.py b/graphqomb/zx_util.py index 9687919b..9e5b8497 100644 --- a/graphqomb/zx_util.py +++ b/graphqomb/zx_util.py @@ -9,7 +9,7 @@ """ # ignore D102: Undocumented public method especially for Protocols, which are primarily for internal use # and may not be directly instantiated by users. -# ruff: noqa: D102 +# ruff:file-ignore[undocumented-public-method] from __future__ import annotations diff --git a/pyproject.toml b/pyproject.toml index c04e0ccc..204ca879 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ dev = [ "pyright==1.1.411", "pytest==9.1.1", "pytest-cov==7.1.0", - "ruff==0.15.20", + "ruff==0.15.22", "scipy-stubs>=1.15.3.0", "types-networkx==3.6.1.20260624", ] @@ -93,20 +93,20 @@ preview = true select = ["ALL"] ignore = [ # Conflicts with ruff format - "COM812", - "COM819", - "D206", - "D300", - "E111", - "E114", - "E117", - "ISC001", - "ISC002", - "Q000", - "Q001", - "Q002", - "Q003", - "W191", + "missing-trailing-comma", + "prohibited-trailing-comma", + "docstring-tab-indentation", + "triple-single-quotes", + "indentation-with-invalid-multiple", + "indentation-with-invalid-multiple-comment", + "over-indented", + "single-line-implicit-string-concatenation", + "multi-line-implicit-string-concatenation", + "bad-quotes-inline-string", + "bad-quotes-multiline-string", + "bad-quotes-docstring", + "avoidable-escaped-quote", + "tab-indentation", # Not necessary for this project "AIR", @@ -116,11 +116,11 @@ ignore = [ # Manually disabled "CPY", # copyright missing - "D105", # undocumented magic method + "undocumented-magic-method", # undocumented magic method "ERA", # commented-out code "FBT", # boolean-trap "FIX", # fixme - "PLR0904", # too-many-public-methods + "too-many-public-methods", # too-many-public-methods ] [tool.ruff.lint.pylint] @@ -136,20 +136,20 @@ docstring-code-format = true [tool.ruff.lint.per-file-ignores] "tests/*.py" = [ - "S101", # `assert` detected - "SLF001", # private method - "PLC2701", # private method - "PLR2004", # magic value in test - "PLR6301", # method could be static - "D100", - "D103", - "D104", - "D400", - "D417", # return not documented (numpy style) - "DOC201", # return not documented (pydoclint) + "assert", # `assert` detected + "private-member-access", # private method + "import-private-name", # private method + "magic-value-comparison", # magic value in test + "no-self-use", # method could be static + "undocumented-public-module", + "undocumented-public-function", + "undocumented-public-package", + "missing-trailing-period", + "undocumented-param", # return not documented (numpy style) + "docstring-missing-returns", # return not documented (pydoclint) ] "examples/*.py" = [ - "T201", # print + "print", # print "D", ] diff --git a/tests/test_zx_util.py b/tests/test_zx_util.py index a8c9c34c..1c4a6947 100644 --- a/tests/test_zx_util.py +++ b/tests/test_zx_util.py @@ -60,7 +60,7 @@ class _PyZXModule(Protocol): EdgeType: _PyZXEdgeTypeNamespace VertexType: _PyZXVertexTypeNamespace - def Graph(self) -> _PyZXTestDiagram: ... # noqa: N802 + def Graph(self) -> _PyZXTestDiagram: ... # ruff:ignore[invalid-function-name] zx = pytest.importorskip("pyzx") diff --git a/uv.lock b/uv.lock index c73283cf..5953d546 100644 --- a/uv.lock +++ b/uv.lock @@ -761,7 +761,7 @@ requires-dist = [ { name = "pytest", marker = "extra == 'dev'", specifier = "==9.1.1" }, { name = "pytest-cov", marker = "extra == 'dev'", specifier = "==7.1.0" }, { name = "pyzx", marker = "extra == 'pyzx'", specifier = ">=0.10" }, - { name = "ruff", marker = "extra == 'dev'", specifier = "==0.15.20" }, + { name = "ruff", marker = "extra == 'dev'", specifier = "==0.15.22" }, { name = "scipy", specifier = ">=1.15.3" }, { name = "scipy-stubs", marker = "extra == 'dev'", specifier = ">=1.15.3.0" }, { name = "sphinx", marker = "extra == 'doc'", specifier = ">=8.1.3" }, @@ -2335,27 +2335,27 @@ wheels = [ [[package]] name = "ruff" -version = "0.15.20" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/43/dc/35b341fc554ba02f217fc10da57d1a75168cfbcf75b0ef2202176d4c4f2d/ruff-0.15.20.tar.gz", hash = "sha256:1416eb04349192646b54de98f146c4f59afe37d0decfc02c3cbbf396f3a28566", size = 4755489, upload-time = "2026-06-25T17:20:37.578Z" } -wheels = [ - { url = "https://files.pythonhosted.org/packages/94/d9/2d5014f0253ba541d2061d9fa7193f48e941c8b21bb88a7ff9bbe0bd0596/ruff-0.15.20-py3-none-linux_armv6l.whl", hash = "sha256:00e188c53e499c3c1637f73c91dcf2fb56d576cab76ce1be50a27c4e80e37078", size = 10839665, upload-time = "2026-06-25T17:19:44.702Z" }, - { url = "https://files.pythonhosted.org/packages/c6/d3/ac1798ba64f670698867fcfc591d50e7e421bef137db564858f619a30fcf/ruff-0.15.20-py3-none-macosx_10_12_x86_64.whl", hash = "sha256:9ebd1fd9b9c95fc0bd7b2761aebec1f030013d2e193a2901b224af68fe47251b", size = 11208649, upload-time = "2026-06-25T17:19:48.787Z" }, - { url = "https://files.pythonhosted.org/packages/47/47/d3ac899991202095dfcf3d5176be4272642be3cf981a2f1a30f72a2afb95/ruff-0.15.20-py3-none-macosx_11_0_arm64.whl", hash = "sha256:c5b16cdd67ca108185cd36dce98c576350c03b1660a751de725fb049193a0632", size = 10622638, upload-time = "2026-06-25T17:19:51.354Z" }, - { url = "https://files.pythonhosted.org/packages/33/13/4e043fe30aa94d4ff5213a9881fc296d12960f5971b234a5263fdc225312/ruff-0.15.20-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3413bb3c3d2ca6a8208f1f4809cd2dca3c6de6d0b491c0e70847672bde6e6efd", size = 10984227, upload-time = "2026-06-25T17:19:54.044Z" }, - { url = "https://files.pythonhosted.org/packages/76/e6/92e7bf40388bc5800073b96564f56264f7e48bfd1a498f5ced6ae6d5a769/ruff-0.15.20-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:bd7ec42b3bb3da066488db093308a69c4ac5ee6d2af333a86ba6e2eb2e7dd44b", size = 10622882, upload-time = "2026-06-25T17:19:57.037Z" }, - { url = "https://files.pythonhosted.org/packages/13/7a/43460be3f24495a3aa46d4b16873e2c4941b3b5f0b00cf88c03b7b94b339/ruff-0.15.20-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:e1a36ad0eb77fba9aabfb69ede54de6f376d04ac18ebea022847046d340a8267", size = 11474808, upload-time = "2026-06-25T17:20:00.357Z" }, - { url = "https://files.pythonhosted.org/packages/27/a0/f37077884873221c6b33b4ab49eb18f9f88e54a16a25a5bca59bef46dd66/ruff-0.15.20-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:b6df3b1e4610432f0386dba04d853b5f08cbbc903410c6fcc02f620f05aff53c", size = 12293094, upload-time = "2026-06-25T17:20:03.446Z" }, - { url = "https://files.pythonhosted.org/packages/a6/74/165545b60256a9704c21ac0ec4a0d07933b320812f9584836c9f4aca4292/ruff-0.15.20-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:e89f198a1ea6ef0d727c1cf16088bc91a6cb0ab947dedc966715691647186eae", size = 11526176, upload-time = "2026-06-25T17:20:06.301Z" }, - { url = "https://files.pythonhosted.org/packages/86/b1/a976a136d40ade83ce743578399865f57001003a409acadc0ecbb3051082/ruff-0.15.20-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:309809086c2acb67624950a3c8133e80f32d0d3e27106c0cd60ff26657c9f24b", size = 11520767, upload-time = "2026-06-25T17:20:09.191Z" }, - { url = "https://files.pythonhosted.org/packages/19/0f/f032696cb01c9b54c0263fa393474d7758f1cdc021a01b04e3cbc2500999/ruff-0.15.20-py3-none-manylinux_2_31_riscv64.whl", hash = "sha256:2d2374caa2f2c2f9e2b7da0a50802cfb8b79f55a9b5e49379f564544fbf56487", size = 11500132, upload-time = "2026-06-25T17:20:13.602Z" }, - { url = "https://files.pythonhosted.org/packages/4b/f4/51b1a14bc69e8c224b15dab9cce8e99b425e0455d462caa2b3c9be2b6a8e/ruff-0.15.20-py3-none-musllinux_1_2_aarch64.whl", hash = "sha256:a1ed17b65293e0c2f22fc387bc13198a5de94bf4429589b0ff6946b0feaf21a3", size = 10943828, upload-time = "2026-06-25T17:20:16.635Z" }, - { url = "https://files.pythonhosted.org/packages/71/4b/fe267640783cd02bf6c5cc290b1df1051be2ec294c678b5c15fe19e52343/ruff-0.15.20-py3-none-musllinux_1_2_armv7l.whl", hash = "sha256:f701305e66b38ea6c91882490eb73459796808e4c6362a1b765255e0cdcd4053", size = 10645418, upload-time = "2026-06-25T17:20:19.4Z" }, - { url = "https://files.pythonhosted.org/packages/b0/c0/a65aa4ec2f5e87a1df32dc3ec1fede434fe3dfd5cbcf3b503cafc676ab54/ruff-0.15.20-py3-none-musllinux_1_2_i686.whl", hash = "sha256:5b9c0c367ad8e5d0d5b5b8537864c469a0a0e55417aadfbeca41fa61333be9f4", size = 11211770, upload-time = "2026-06-25T17:20:22.033Z" }, - { url = "https://files.pythonhosted.org/packages/5a/a4/0caa331d954ae2723d729d351c989cb4ca8b6077d5c6c2cb6de75e98c041/ruff-0.15.20-py3-none-musllinux_1_2_x86_64.whl", hash = "sha256:01cc00dd58f0df339d0e902219dd53990ea99996a0344e5d9cc8d45d5307e460", size = 11618698, upload-time = "2026-06-25T17:20:25.259Z" }, - { url = "https://files.pythonhosted.org/packages/10/9b/5f14927848d2fd4aa891fd88d883788c5a7baba561c7874732364045708c/ruff-0.15.20-py3-none-win32.whl", hash = "sha256:ed65ef510e43a137207e0f01cfcf998aeddb1aeeda5c9d35023e910284d7cf21", size = 10857322, upload-time = "2026-06-25T17:20:28.612Z" }, - { url = "https://files.pythonhosted.org/packages/fa/f0/fe47c501f9dea92a26d788ff98bb5d92ed4cb4c88792c5c88af6b697dc8e/ruff-0.15.20-py3-none-win_amd64.whl", hash = "sha256:a525c81c70fb0380344dd1d8745d8cc1c890b7fc94a58d5a07bd8eb9557b8415", size = 11993274, upload-time = "2026-06-25T17:20:31.871Z" }, - { url = "https://files.pythonhosted.org/packages/d7/2b/9555445e1201d92b3195f45cdb153a0b68f24e0a4273f6e3d5ab46e212bb/ruff-0.15.20-py3-none-win_arm64.whl", hash = "sha256:2f5b2a6d614e8700388806a14996c40fab2c47b819ef57d790a34878858ed9ca", size = 11343498, upload-time = "2026-06-25T17:20:35.03Z" }, +version = "0.15.22" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/3a/06/ae069393fc66e8ff33036d4b368003833bf6e88ccf182e17e7a2f1c754fd/ruff-0.15.22.tar.gz", hash = "sha256:3f15175b1fb580126f58285a5dae6b2ea89000136d980c64499211f116b54809", size = 4785063, upload-time = "2026-07-16T15:14:13.244Z" } +wheels = [ + { url = "https://files.pythonhosted.org/packages/23/18/ee54b7ae1e121be7a28ea6da4b67564ebb0530e183a54415ab7e3bcd2c4e/ruff-0.15.22-py3-none-linux_armv6l.whl", hash = "sha256:44423e73493737f5e7c5b41d475483898ff37afcdae38bc3da5085e29af1c2d8", size = 10781258, upload-time = "2026-07-16T15:13:19.452Z" }, + { url = "https://files.pythonhosted.org/packages/2f/d2/2520cb14761ddbeaf57642a76942fc36adcbdbe53b4532241995f6fc485c/ruff-0.15.22-py3-none-macosx_10_12_x86_64.whl", hash = "sha256:b82c6482946e9eda7ff2e091d25b8bad3f718684e1916d41bd56873cee05b697", size = 10999477, upload-time = "2026-07-16T15:13:23.318Z" }, + { url = "https://files.pythonhosted.org/packages/c9/10/74e53572aa758dfaa678c2a2646b5c5515d884b7ca56be4d2ce03ca4b560/ruff-0.15.22-py3-none-macosx_11_0_arm64.whl", hash = "sha256:11c1c715af53a09f714e011106bffc419751ec8232fcb5da42173284ea3fec6f", size = 10466716, upload-time = "2026-07-16T15:13:26.162Z" }, + { url = "https://files.pythonhosted.org/packages/1e/cc/44eaaf0844e028182f2d0a8f2190d0f359159aed0a9e5ab861d892f1ae2a/ruff-0.15.22-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:742a29cf29bddb7c8327895d6a10e0e6c5b38a96dd407af9b5d0857f809c0576", size = 10892644, upload-time = "2026-07-16T15:13:29.229Z" }, + { url = "https://files.pythonhosted.org/packages/9f/21/8edf559014d2b0f82beea19cfb713993ad802ccda16868769979c6090a84/ruff-0.15.22-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:72af58b951b0ae395935ae79763dc349bc0eb706319d28f7a33ad2cfb3cfc178", size = 10576719, upload-time = "2026-07-16T15:13:32.35Z" }, + { url = "https://files.pythonhosted.org/packages/bf/1e/3a13abd392a3b50b62e5938a831f9ab6e588358cacad5c18545b716d2182/ruff-0.15.22-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:62d425005c1835eb24e2ee4161cb90e8db263415f4a71c8c72c33abaa6c0c224", size = 11376494, upload-time = "2026-07-16T15:13:35.958Z" }, + { url = "https://files.pythonhosted.org/packages/bf/3e/422d3d95bcf04dd78e1aeac22184d4f9a8fb2c01865d39d44618484a0317/ruff-0.15.22-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:e8b9b3f8779a4f08c969defc3c8c35abffaa757e601ed5ae66d6d1db6519969a", size = 12208370, upload-time = "2026-07-16T15:13:39.185Z" }, + { url = "https://files.pythonhosted.org/packages/1e/91/5d065a0e0a02bf4813f5119ad278462eed081d2b832eb7c021ade0ec9e65/ruff-0.15.22-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:1e0dd1b2e4d3d585f897a0d137cbf4eaf6223bef4e8ce34d6bb12556c5f9249e", size = 11581098, upload-time = "2026-07-16T15:13:42.132Z" }, + { url = "https://files.pythonhosted.org/packages/f6/f9/a0d4871d12fae702eb1f41b686caf05f1f8b124dc6db6f784f53d74918fa/ruff-0.15.22-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:365523eb91d9224e1bcb03b022fbf0facb8f9e23792a2c53d9d4b3924bdbdebb", size = 11399422, upload-time = "2026-07-16T15:13:45.2Z" }, + { url = "https://files.pythonhosted.org/packages/18/80/c843a5176cddbceb0b7e8dd41cf9993490796c1c469348d384f5a5c13c56/ruff-0.15.22-py3-none-manylinux_2_31_riscv64.whl", hash = "sha256:fabfd168afdf29fee5be98b831efa9683c94d7c5a3b58b9ce5a2e38444589a74", size = 11381683, upload-time = "2026-07-16T15:13:48.46Z" }, + { url = "https://files.pythonhosted.org/packages/d4/00/8485de0ae92239438a36cfc51350db9b9e85c9ebdfaea91b18e422706662/ruff-0.15.22-py3-none-musllinux_1_2_aarch64.whl", hash = "sha256:225dbf095a87f1d9f90f5fd7924d2613ee452a75a4308c63a8f50f761787aa7c", size = 10850295, upload-time = "2026-07-16T15:13:51.655Z" }, + { url = "https://files.pythonhosted.org/packages/fa/91/24977ec2ec72eaf15e4394ace2959fdff2dd1e14f03e005e838023407169/ruff-0.15.22-py3-none-musllinux_1_2_armv7l.whl", hash = "sha256:1877d63b9d24ed278744f1523fd11b85540566d54641f97c566d7d9dc5ca5296", size = 10579640, upload-time = "2026-07-16T15:13:54.79Z" }, + { url = "https://files.pythonhosted.org/packages/9c/47/9b51216951974df1f263ac19da550d34252e0ed7218c25f10c5ef9ed7517/ruff-0.15.22-py3-none-musllinux_1_2_i686.whl", hash = "sha256:a1606c510bd7215680d32efab38965f7cdec3ef69f5170a3f4791404ffdd5262", size = 11105077, upload-time = "2026-07-16T15:13:57.915Z" }, + { url = "https://files.pythonhosted.org/packages/c2/47/20e9d4a3b8016778acea5fc32bb50d35d207500a17ddb529ffa6996feef8/ruff-0.15.22-py3-none-musllinux_1_2_x86_64.whl", hash = "sha256:630479b18625f5ffc373f77603a22a9f8ac0acd7ff0501178b5db28ec71e9c64", size = 11490980, upload-time = "2026-07-16T15:14:01.032Z" }, + { url = "https://files.pythonhosted.org/packages/4d/76/3f72d8fc38c1cb77b38c56a70da9d0c17700cc1cc50f9649c9d3c8f5ba71/ruff-0.15.22-py3-none-win32.whl", hash = "sha256:e5ba0e4a13fd14abbed2a77b517a3911290c6c6c59ef67784328d1668fab76cf", size = 10789165, upload-time = "2026-07-16T15:14:04.16Z" }, + { url = "https://files.pythonhosted.org/packages/cb/46/4965251734c2b6fcdca1b1b187d20bcac3af0ee5b083b89c910bb961ce3a/ruff-0.15.22-py3-none-win_amd64.whl", hash = "sha256:9be63ba1eb936acd2d1342fb8337c356353706fce233b2a15a09a97037e6acde", size = 11938297, upload-time = "2026-07-16T15:14:07.316Z" }, + { url = "https://files.pythonhosted.org/packages/57/c9/e69b1ff4c8b69093ef08b8919ab767af0569666865b39c30a8795d88d3c6/ruff-0.15.22-py3-none-win_arm64.whl", hash = "sha256:e1168075b72158510839f250027659cdd78476f40507dd517892304c41318661", size = 11298172, upload-time = "2026-07-16T15:14:10.51Z" }, ] [[package]]