Author terry.reedy
Recipients gvanrossum, kernc, lukasz.langa, martin.panter, paul.moore, terry.reedy, tshepang
Date 2014-09-09.04:29:41
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1410236982.38.0.669278662648.issue22253@psf.upfronthosting.co.za>
In-reply-to
Content
The MS function GetPrivateProfileString appears to require sections.
http://msdn.microsoft.com/en-us/library/ms724353.aspx
On the other hand, it does not appear to do interpolation, so we have already not restricted ourselves to the MS function.

In looking through the .ini files in my game directory, which includes some old games, I found a couple with no section header.  So such files do exist in the wild.  I am dubious that there are any with a mixture of both sections and additional option lines at the top without a section.

Anyone writing an app and planning to parse a .ini file can add [Start] or [Setup] at the top.  So there is only an issue for 3rd party software parsing a file without.

I think a more useful new configparser feature would be to keep comment lines and write them back out after a configuration is changed.
History
Date User Action Args
2014-09-09 04:29:42terry.reedysetrecipients: + terry.reedy, gvanrossum, paul.moore, lukasz.langa, tshepang, martin.panter, kernc
2014-09-09 04:29:42terry.reedysetmessageid: <1410236982.38.0.669278662648.issue22253@psf.upfronthosting.co.za>
2014-09-09 04:29:42terry.reedylinkissue22253 messages
2014-09-09 04:29:41terry.reedycreate