2012-02-29 74 views
0

我有這樣一個標準的日誌記錄配置:金字塔忽略我的日誌配置

[loggers] 
keys = root, quoting, sqlalchemy 

[handlers] 
keys = console 

[formatters] 
keys = generic 

[logger_root] 
level = INFO 
handlers = console 

[logger_quoting] 
level = INFO 
handlers = 
qualname = quoting 

[logger_sqlalchemy] 
level = WARN 
handlers = 
qualname = sqlalchemy.engine 
# "level = INFO" logs SQL queries. 
# "level = DEBUG" logs SQL queries and results. 
# "level = WARN" logs neither. (Recommended for production systems.) 

[handler_console] 
class = StreamHandler 
args = (sys.stderr,) 
level = NOTSET 
formatter = generic 

[formatter_generic] 
format = %(asctime)s %(levelname)-5.5s [%(name)s][%(threadName)s] %(message)s 

而金字塔似乎忽略它,用pserve --reload development.ini運行時,給我在stdout一切。

http://pastebin.com/1Q3Vt9xM

樣品日誌輸出日誌代表一個頁面加載。我試圖過濾掉具體的SQLAlchemy的東西,但想知道我出錯的地方

回答

1

我認爲在SQLAlchemy引擎配置上的echo=True將轉儲到stdout並忽略日誌記錄配置。這可能是你所看到的。