Remove rx.is_directed_acyclic_graph() from DAGCircuit.depth() (#5505)
Remove rx.is_directed_acyclic_graph() from DAGCircuit.depth() (#5505)

This commits removes the rx.is_directed_acyclic_graph() call from the
DAGCircuit.depth() method. This call was unnecessary as the
rx.dag_longest_path_length() method will internally raise an exception
if the input graph has a cycle. Additionally, for very large circuits
the rx.is_directed_acyclic_graph() can segfault. To reduce the overhead
of the depth() method and to avoid the potential bug this unnecessary
call is removed.

Fixes #5502
QISKit/qiskit-sdk-py,QISKit/qiskit-sdk-py,QISKit/qiskit-sdk-py