The test for "Edge cannot begin and end with the same node" should not be there. Loop is not an error and with dropping dispersers between nodes, it yields non-trivial results.
if (node_1_id == node_2_id) {
throw std::runtime_error(
std::string("Edge cannot begin and end with the same node: ")
+ node_1_text + " " + node_2_text);
}
The test for "Edge cannot begin and end with the same node" should not be there. Loop is not an error and with dropping dispersers between nodes, it yields non-trivial results.