This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author eric.snow
Recipients Arfrever, Jim.Jewett, alex, asvetlov, benjamin.peterson, eric.araujo, eric.smith, eric.snow, ezio.melotti, flox, gregory.p.smith, introom, josh.r, mrabarnett, ned.deily, pitrou, refi64, rhettinger, scoder, serhiy.storchaka, tonn81, westurner, yselivanov
Date 2015-05-22.23:38:31
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1432337911.26.0.269184613892.issue16991@psf.upfronthosting.co.za>
In-reply-to
Content
If I still the following at Lib/test/test_configparser.py:328:

  print(len(cf._proxies), len(list(cf._proxies)), list(cf._proxies))
  print(len(cf._sections), len(list(cf._sections)), list(cf._sections))

I get unexpected results that are a clear indication of a problem:

  9 8 ['DEFAULT', 'Foo Bar', 'Spacey Bar', 'Spacey Bar From The Beginning', 'Commented Bar', 'Long Line', 'Section\\with$weird%characters[\t', 'Internationalized Stuff']
  8 7 ['Foo Bar', 'Spacey Bar', 'Spacey Bar From The Beginning', 'Commented Bar', 'Long Line', 'Section\\with$weird%characters[\t', 'Internationalized Stuff']

Note that OrderedDict.__len__ is just dict.__len__, so the first number (the actual length) should be the same as the second number (the number of keys).  Also note that OrderedDict.keys() is working (even if not exactly correct).  Between the two observations, this implies that for this one test the keys are not only off, but at least one of the keys in the linked list is not in the underlying dict.

I'm sure this is consequence of resizing.  At the last point that we resize this is the state of the cf._proxies and cf._sections (ignore the trailing <NULL> (?)):

  OrderedDict([('DEFAULT', <Section: DEFAULT>), ('Foo Bar', <Section: Foo Bar>), ('Spacey Bar', <Section: Spacey Bar>), ('Spacey Bar From The Beginning', <Section: Spacey Bar From The Beginning>), ('Commented Bar', <Section: Commented Bar>), <NULL>])

  OrderedDict([('Foo Bar', OrderedDict([('foo', ['bar1'])])), ('Spacey Bar', OrderedDict([('foo', ['bar2'])])), ('Spacey Bar From The Beginning', OrderedDict([('foo', ['bar3']), ('baz', ['qwe'])])), ('Commented Bar', OrderedDict([('foo', ['bar4']), ('baz', ['qwe'])])), ('Long Line', OrderedDict([('foo', ['this line is much, much longer than my editor', 'likes it.'])])), <NULL>])

I haven't had time to analyze this but I'll be taking a closer look in later tonight.  I'm not giving up on 3.5. :)
History
Date User Action Args
2015-05-22 23:38:31eric.snowsetrecipients: + eric.snow, rhettinger, gregory.p.smith, pitrou, scoder, eric.smith, benjamin.peterson, ned.deily, ezio.melotti, eric.araujo, mrabarnett, Arfrever, alex, asvetlov, flox, Jim.Jewett, serhiy.storchaka, yselivanov, westurner, refi64, josh.r, tonn81, introom
2015-05-22 23:38:31eric.snowsetmessageid: <1432337911.26.0.269184613892.issue16991@psf.upfronthosting.co.za>
2015-05-22 23:38:31eric.snowlinkissue16991 messages
2015-05-22 23:38:31eric.snowcreate