Roy Smith wrote:
I will commonly put something like:import logging logger = logging.getLogger("logger-name-for-my-module")
But that's not really a global variable, it's a global constant. There's nothing wrong with those, we use them all the time -- classes, functions, etc. If you were to rebind logger to a different one from time to time in your code, *then* it would be a global variable, subject to the usual cautions. -- Greg -- https://mail.python.org/mailman/listinfo/python-list