Adding back sleep, debug flag