def METHOD_NAME():
    circuits = rqcg.generate_library_of_2q_circuits(
        n_library_circuits=5, two_qubit_gate=cirq.ISWAP**0.5, max_cycle_depth=10
    )
    cycle_depths = [10]
    graph = _gridqubits_to_graph_device(cirq.GridQubit.rect(3, 2))
    combs = rqcg.get_random_combinations_for_device(
        n_library_circuits=len(circuits) + 100,  # !!! should cause invlaid input
        n_combinations=5,
        device_graph=graph,
        random_state=10,
    )
    with pytest.raises(ValueError, match='.*invalid indices.*'):
        _ = sample_2q_xeb_circuits(
            sampler=cirq.Simulator(),
            circuits=circuits,
            cycle_depths=cycle_depths,
            combinations_by_layer=combs,
        )