Wait for logging enhanced to find bug

Wait for logging enhanced to find bug