<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><div>Wiadomość napisana przez Éric Araujo w dniu 2010-12-03, o godz. 19:35:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div>Hello,<br><br><blockquote type="cite">Author: lukasz.langa<br></blockquote><blockquote type="cite">New Revision: 86976<br></blockquote><blockquote type="cite">Log: Issue 10499: Modular interpolation in configparser<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Modified: python/branches/py3k/Doc/library/configparser.rst<br></blockquote>Is the module still backward compatible with the 3.1 version, modulo<br>fixed bugs? &nbsp;I haven’t been able to follow closely all the great<br>improvements you’ve been making, and there has been a lot of movement in<br>the code, so I’m not sure.<br></div></blockquote><div><br></div><div>There have been minor incompatibilities, all have been thoroughly discussed with Fred and other developers. No changes should cause silent breakage, though.</div><div><br></div><blockquote type="cite"><div>Thanks for taking up configparser. &nbsp;Maybe it will become so useful and<br>extensible that you’ll have to release it on PyPI for older Pythons :)<br></div></blockquote><div><br></div><div>Sure. Why not? :)</div><br><blockquote type="cite"><div><blockquote type="cite">Modified: python/branches/py3k/Doc/library/fileformats.rst<br></blockquote>This looks like unrelated changes that slipped in the commit.&nbsp;<br></div></blockquote><div><br></div><div>As we discussed this on IRC, this is an unfortunate slip caused by me trying to wrap up documentation updates in one go. Will remember to do that separately now. Thanks!</div><br><blockquote type="cite"><div><blockquote type="cite">Modified: python/branches/py3k/Lib/configparser.py<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Raise DuplicateSectionError if a section by the specified name<br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;already exists. Raise ValueError if name is DEFAULT.<br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;"""<br></blockquote><blockquote type="cite">- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if section == self._default_section:<br></blockquote><blockquote type="cite">+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if section == self.default_section:<br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;raise ValueError('Invalid section name: %s' % section)<br></blockquote>I think it’s the only error message using %s instead of %r. &nbsp;The quotes<br>added by %r typically help spot names with spaces (embedded or trailing)<br>and the like.<br></div></blockquote><div><br></div><div>Corrected in rev 86999, thanks.</div><br><blockquote type="cite"><div><blockquote type="cite">+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;options = list(d.keys())<br></blockquote><blockquote type="cite">+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if raw:<br></blockquote><blockquote type="cite">+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return [(option, d[option])<br></blockquote><blockquote type="cite">+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;for option in options]<br></blockquote><blockquote type="cite">+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;else:<br></blockquote><blockquote type="cite">+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return [(option, self._interpolation.before_get(self, section,<br></blockquote><blockquote type="cite">+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;option, d[option],<br></blockquote><blockquote type="cite">+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;d))<br></blockquote><blockquote type="cite">+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;for option in options]<br></blockquote>The list call seems unneeded. &nbsp;Minor style point: I avoid such dangling<br>arguments that don’t read great, I prefer to go to a newline after the<br>opening paren:<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return [(option, self._interpolation.before_get(<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;self, section, option, d[option], d)) for<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;option in options]<br></div></blockquote><div><br></div><div>You're right that my formatting looks ugly but yours is not that much better either ;) How about:</div><div><br></div><div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;value_getter = lambda option: self._interpolation.before_get(self,</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;section, option, d[option], d)</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;if raw:</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;value_getter = lambda option: d[option]</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;return [(option, value_getter(option))</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;for option in d.keys()]</div></div></div><br><div>
<div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Verdana; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Verdana; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Verdana; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Verdana; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><font class="Apple-style-span" face="Helvetica" size="3"><span class="Apple-style-span" style="font-size: 12px; ">--&nbsp;</span></font></div><div><font class="Apple-style-span" face="Helvetica" size="3"><span class="Apple-style-span" style="font-size: 12px; ">Best regards,</span></font></div><div><font class="Apple-style-span" face="Helvetica" size="3"><span class="Apple-style-span" style="font-size: 12px; ">Łukasz Langa</span></font></div><div><font class="Apple-style-span" face="Helvetica" size="3"><span class="Apple-style-span" style="font-size: 12px; ">tel. +48 791 080 144</span></font></div><div><font class="Apple-style-span" face="Helvetica" size="3"><span class="Apple-style-span" style="font-size: 12px; ">WWW <a href="http://lukasz.langa.pl/">http://lukasz.langa.pl/</a></span></font></div></div></span></div></span></div></span></div></span></div>
</div>
<br></body></html>