-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wrong output location for RecCeiver #8
Comments
I though I remembered that twistd was redirecting stdout? Well I guess not. I'll look into it. |
Some output is redirected, and some is not. I suppose that it's because in Transaction, output is handled with |
Can you try replacing def show(self, fp=sys.stdout): with def show(self, fp=None):
fp = fp or sys.stdout |
Never mind my previous request. I shouldn't be using 'print' and stdout here anyway. Should be addressed by 2afcf12 |
Seems to be working better now, though there are two "inconveniences":
Logging prefix impedes output readability. |
As the standard logging module is used now, would config w/ https://docs.python.org/2.7/library/logging.config.html give you sufficient control? If so, do you have a preference for json and |
As far as I get it, control over the logging module output can be already obtained by setting the appropriate option. I just put that in
it goes in application.py and voila. However, it only gives control over the second part of the output string. Everything before the %(levelname) comes from somewhere else. Anyways, given that globally squelching the output is not a solution, I don't think any logging format reconfiguration will help here. I'd suggest it's up to the "show" plugin to consolidate output and write it into the log at once instead of printing every line as a separate log message. |
When twistd --logfile is used, client information output generated by Transaction is shown on stdout instead of going into a log file specified for twistd. Consequently, if twistd is run as a daemon, all valuable information is muffled and does not appear in the log.
The text was updated successfully, but these errors were encountered: