New submission from Daniel Watkins:

A grep through the codebase shows that RawConfigParser.items() is the only 
.items() method in the stdlib which accepts arguments.

This is annoying as a stdlib user because when I see the arguments being passed 
to RawConfigParser.items(), I have _no idea_ what they do.  Instinctively, I do 
not expect .items() to take arguments, and I have to go and work out what it 
does each time.

I think it would be both easier to understand, and more consistent with general 
Pythonic practice, if the two codepaths in RawConfigParser.items() were split 
in to separate methods; one which takes no arguments (which will continue to 
behave as it does today when called that way) and one which is named in a way 
that makes it clearer what it does (and takes arguments).

----------
components: Library (Lib)
messages: 299821
nosy: odd_bloke
priority: normal
severity: normal
status: open
title: RawConfigParser.items() is unusual in taking arguments
versions: Python 3.7

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

Reply via email to