|
|
@@ -9,11 +9,14 @@ _real_stderr = sys.stderr |
|
|
|
_sql_verbose = False |
|
|
|
|
|
|
|
if False: |
|
|
|
lvl = logging.DEBUG |
|
|
|
lvl = logging.INFO |
|
|
|
_handler = logging.StreamHandler(_real_stderr) |
|
|
|
_handler.setLevel(logging.DEBUG) |
|
|
|
_handler.setLevel(lvl) |
|
|
|
_handler.setFormatter(logging.Formatter('%(asctime)s: %(message)s')) |
|
|
|
import sqlalchemy |
|
|
|
logging.getLogger('sqlalchemy').addHandler(_handler) |
|
|
|
logging.getLogger('sqlalchemy.engine').setLevel(logging.DEBUG) |
|
|
|
logging.getLogger('sqlalchemy.engine').setLevel(lvl) |
|
|
|
|
|
|
|
def _debprint(*args): # pragma: no cover |
|
|
|
import traceback, sys, os.path |
|
|
|