Logging ...

#1

Hi, very minor issue I can’t seem to get my head around … by default autobahn seems to issue ‘trace’ type logging which drowns the logging system very quickly.

If I start with this in the code, it seems to behave nicely;

txaio.use_twisted()
txaio.start_logging(level=‘info’)

``

However, when I run via “twistd”, I end up with the following in the logs;

Warning: primary log target selected twice at </usr/local/lib/python2.7/dist-packages/twisted/python/log.py:210> - previously selected at </usr/local/lib/python2.7/dist-packages/txaio/tx.py:272>. Remove one of the calls to beginLoggingTo.

``

Can anyone tell me how to disable log.py:210 without hacking twisted code, or alternatively, tell me what I’m doing wrong?

tia

Gareth.

0 Likes