Could be replaced with a wait_for?