2008/9/3 Hendrik van Rooyen <[EMAIL PROTECTED]>: > > Steven D'Aprano <stev...bersource.com.au> wrote: > >>Is there a better way of doing this than the way I am going about it? > > Not sure if its "better", but I would keep the messages in a table or dict and > have different tables or dicts for different levels of verbosity, and write a > displayer that knows about the verbosity - This approach has the advantage > that > you can write in English and have different verbosities in different languages > too, if the displayer knows about the language.
One big downside with that approach is that it becomes much harder to grep for the log message. Usually when I go through logs, I don't care what exactly the message says, just that it is easily googleable (uses some kind of identifying text) and that it is unique so I can know exactly where it was emitted. -- mvh Björn -- http://mail.python.org/mailman/listinfo/python-list