From: Mike Bayer Date: Mon, 23 Oct 2006 18:10:10 +0000 (+0000) Subject: set global 'sqlalchemy' log level to ERROR so it is insulated from other logging... X-Git-Tag: rel_0_3_1~45 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=32d872ddd8e8f96e72c5c30540e5a4e6d7de11ba;p=thirdparty%2Fsqlalchemy%2Fsqlalchemy.git set global 'sqlalchemy' log level to ERROR so it is insulated from other logging configs [ticket:353] --- diff --git a/lib/sqlalchemy/logging.py b/lib/sqlalchemy/logging.py index 876785b0d9..b3960ba861 100644 --- a/lib/sqlalchemy/logging.py +++ b/lib/sqlalchemy/logging.py @@ -29,6 +29,9 @@ import sys # py2.5 absolute imports will fix.... logging = __import__('logging') +# turn off logging at the root sqlalchemy level +logging.getLogger('sqlalchemy').setLevel(logging.ERROR) + default_enabled = False def default_logging(name): global default_enabled @@ -37,7 +40,6 @@ def default_logging(name): if not default_enabled: default_enabled = True rootlogger = logging.getLogger('sqlalchemy') - rootlogger.setLevel(logging.NOTSET) handler = logging.StreamHandler(sys.stdout) handler.setFormatter(logging.Formatter('%(asctime)s %(levelname)s %(name)s %(message)s')) rootlogger.addHandler(handler)