CQCL / tket2

Version 2 of the TKET quantum compiler

Home Page:http://crates.io/crates/tket2

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Slow python tests cause spurious errors

aborgna-q opened this issue · comments

test_depth_hyp runs depth optimisation on a set of circuits, with a 30ms deadline.

The test may take longer in some cases, which causes CI to fail.
See https://github.com/CQCL/tket2/actions/runs/9189665381/job/25272188461
We could reduce the circuit the generated circuit depth/n_qubits range to prevent this.

While we're looking at this, we may want to optimise test_simple_badger_pass_no_opt too, as it also slows down the tests quite a bit. This is the output of pytest --durations=0 on my machine (CI will be slower):

=============================== slowest durations ======================
6.71s call     tket2-py/test/test_pass.py::test_simple_badger_pass_no_opt
0.97s call     tket2-py/test/test_pass.py::test_depth_hyp
0.03s call     tket2-py/test/test_portmatching.py::test_larger_matching
0.01s setup    tket2-py/test/test_pauli_prop.py::test_simple_z_prop