Use waitUntil conditions to avoid aleatory behavior