wait_for_edge function removed