[issue11476] StreamHandler code broken by change of parameter name
New submission from follower : The following change broke pre-existing code that used "strm" as the parameter name (as documented http://docs.python.org/release/2.6.6/library/logging.html#streamhandler): http://hg.python.org/cpython/diff/7391436d8a74/Lib/logging/__init__.py The parameter name was changed with no documentation note that it had changed in 2.7: http://docs.python.org/library/logging.html#stream-handler This breaks existing code with the error: TypeError: __init__() got an unexpected keyword argument 'strm' I encountered it in pyres but it broke Ubuntu bug reporting too: https://bugs.launchpad.net/ubuntu/+source/launchpad-integration/+bug/702455 -- assignee: docs@python components: Documentation, Library (Lib) messages: 130691 nosy: docs@python, follower priority: normal severity: normal status: open title: StreamHandler code broken by change of parameter name type: behavior versions: Python 2.7 ___ Python tracker <http://bugs.python.org/issue11476> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11476] StreamHandler code broken by change of parameter name
follower added the comment: I don't think it would be unreasonable to add the old name back in temporarily and use whichever parameter is supplied--this change has obviously broken code in the process. But for future situations I think changes like this shouldn't happen without a deprecation process. -- ___ Python tracker <http://bugs.python.org/issue11476> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19902] logging docs don't document integer constants
New submission from follower: The logging module documentation <http://docs.python.org/3.4/library/logging.html> makes reference to the levels DEBUG, INFO etc (e.g. in <http://docs.python.org/3.4/library/logging.html#logging.Logger.setLevel>) but AFAICT these constants are not documented in the module itself. e.g I would expect a section like this Level Constants logging.DEBUG 10 logging.INFO 20 etc etc (Although the actual values may not be listed depending on what your policy is for documenting "magic numbers".) -- assignee: docs@python components: Documentation messages: 205334 nosy: docs@python, follower priority: normal severity: normal status: open title: logging docs don't document integer constants type: enhancement versions: Python 2.7, Python 3.5 ___ Python tracker <http://bugs.python.org/issue19902> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19902] logging docs don't document integer constants
follower added the comment: Thanks for pointing out that link. It's good to know the information is documented somewhere. However, given that <http://docs.python.org/2/library/logging.html> is described as "the API reference" and seems to be the canonical logging library reference (rather than a tutorial) it would be appropriate to--and I would expect it to--include the constants information in it. Thus I would request you reconsider the "invalid" resolution on this basis. Thanks. -- status: pending -> open ___ Python tracker <http://bugs.python.org/issue19902> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
