Does debug() actually want to log 100% of the time?  Would it make more sense to have a DEBUG var set to either true or false that the logging is conditionalized on?