ConfigParser shootout, preliminary entry
Stephen Waterbury
golux at comcast.net
Sat Oct 23 14:34:18 EDT 2004
Carlos Ribeiro wrote:
> On Sat, 23 Oct 2004 10:46:24 -0400, Peter Hansen <peter at engcorp.com> wrote:
>>David Wilson wrote:
>>
>>>NAME
>>> ConfigParser - Configuration file parser.
>>>
>>>The 'config' object you refer to does not appear to be implemented by
>>>the ConfigParser module.
>>
>>Ah, there's the conflict. [explanation of conflict elided]
>
> I agree with Peter -- that's the whole point of this discussion. The
> question can be re-stated as, "do we need a configuration object or a
> configuration parser object"? The former is able to read/write itself
> from a text file (using INI, or other suitable format); the latter
> only reads a INI file and parses it.
As David Wilson's own description implies, ConfigParser
has an implicit -- but apparently essential -- constraint
to avoid
"incompatibility with how Microsoft did it ... in .INI land ..."
It seems a shame (to put it mildly) that a Python standard
module with no explicit reference to Microsoft should be
constrained by a Microsoft syntax. If this is indeed that case,
I would suggest that the name of the ConfigParser module should
be changed to something more transparent, such as
"MS_INI_ConfigParser" or some such, thereby leaving the
namespace open for a more general ConfigParser module which
could have more capabilities and fewer constraints. IMO it
is a *bad* idea to give a specifically targeted module a
name that implies a scope larger than the module actually has.
Steve
More information about the Python-list
mailing list