G
G
Grigory Tretyakov2012-03-09 22:27:27
Python
Grigory Tretyakov, 2012-03-09 22:27:27

Python logging && uwsgi?

Hello.
I have an ngnix+uwsgi server (uwsgi version is 0.9.7.1). On this server, the pylons application is running, which is launched with an ini-config.
At the same time, logging from python via logging does not work.
The config is something like this:
[DEFAULT]
debug = false
[server:main]
use = egg:Paste#http
host = 127.0.0.1
port = 5454
scriptName = ""
[app:main]
use = egg:myporject
full_stack = true
static_files = true
permanent_store = %(here)s/myporject/public
cache_dir = %(here)s/data
beaker.session.key = myporject
beaker.session.secret = somesecret
# Logging configuration
[loggers]
keys = root, routes, myporject
[handlers]
keys = accesslog
[formatters]
keys = generic
[logger_root]
level = WARN
handlers = accesslog
[logger_routes]
level = WARN
handlers = accesslog
qualname = routes.middleware
[logger_myporject]
level = WARN
handlers = accesslog
qualname = myporject
[handler_accesslog]
class = FileHandler
args = ('access.log','a')
level = INFO
formatter = generic
[formatter_generic]
format = %(asctime)s,%(msecs)03d %(levelname)- 5.5s [%(name)s] [%(threadName)s] %(message)s
datefmt = %H:%M:%S
I run uwsgi like this:
/path/uwsgi/uwsgi -H /path/env -p 4 --paste config:/path/site/myproject.ini --socket :3993 > /dev/null 2>&1 &

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
mikevmk, 2012-03-19
@mikevmk

Unfortunately, I don’t know what to advise in essence, but the first thing to do is to upgrade to the current stable release of uWSGI (1.1)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question