Avoid async-related problems in the stats tasks