Reduce the number of call to hashes by caching debug_level