New submission from Antoine Pitrou:

Often an application (or e.g. a library's test suite), in its early 
development, will start making print() calls, and later will want to switch to 
the logging module. However the logging module doesn't offer any facility for 
this: you can't print() to a logger object, and loggers don't have a method 
that reflects print()'s signature.

(note print() only uses the .write() and .flush() methods on its stream 
argument, so a simple wrapper may make the trick)

----------
components: Library (Lib)
messages: 225302
nosy: pitrou, vinay.sajip
priority: normal
severity: normal
status: open
title: Make it easy to replace print() calls with logging calls
type: enhancement
versions: Python 3.5

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue22195>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to