Aspen uses the Python logging library. You can configure logging with
a __/etc/logging.conf file, which is processed by the logging library's
fileConfig routine. If there is no logging.conf file, then Aspen
logs all messages to sys.stderr. Note that you are responsible to create
any directories needed to store log files that you specify in
logging.conf; Aspen does not create those directories for you, and will
not work if they do not exist.
Below is an example logging configuration file that logs all messages to a file at /var/log/aspen.log, rotating every night at midnight, keeping old logs for six days. See more examples in the Python logging documentation.
[loggers]
keys=root,aspen
[handlers]
keys=handler
[formatters]
keys=formatter
[logger_root]
level=NOTSET
handlers=handler
[logger_aspen]
level=NOTSET
handlers=handler
propagate=0
qualname=aspen
[handler_handler]
class=handlers.TimedRotatingFileHandler
level=NOTSET
formatter=formatter
args=('/var/log/aspen.log', 'midnight', -1, 6)
#filename, when, interval [ignored], backupCount
[formatter_formatter]
format=%(asctime)s %(name)s %(levelname)s %(message)s
datefmt=
class=logging.Formatter
Aspen is copyright © 2006-2007 by Chad Whitacre and contributors, and is offered under the MIT license.