Message113298
Patch updated.
All docstrings now have a one-line summary.
All multiline docstrings now have a newline character before the closing """.
No method docstrings now include any additional newlines between them and the
code. Most of them were okay, a couple were edited for consistency.
All read_* methods now have a source= attribute. read_file defaults to <???>,
read_string to <string>, read_dict to <dict>. Didn't provide any additional
introspection because it's not trivial and I want this patch to be committed at
last. This might be an additional advantage because a generic <string> or <dict>
name may motivate programmers to specify a more context-specific source name of
their own.
As for Duplicate*Error, I've added source= and lineno= to both. Didn't add line=
because it's useless, the error is very specific on what is wrong. Reading from
a dictionary does not pass the lineno for obvious reasons. Reading from files
and strings does.
The `filename' attribute and __init__ argument in ParsingError were
PendingDeprecated and a `source' attribute was introduced for consistency.
`allow_no_value` was moved to the 3rd place in the argument list for backwards
compatibility with Python 2.7. I didn't notice your change made to Python
2.7 as well, all other new arguments were added by me. This ensures there's no
backwards compatibility involved in their case. That's why I left all of the
new arguments as keyword only.
Documentation and unit tests updated.
BTW, if `allow_no_value` made it to 2.7 this means it has a bug in
SafeConfigParser.set. Try to set a valueless option, line 694 will raise an
exception. Should I provide you with a separate patch only to fix this for
2.7.1?
PS. I made Vim show me too long lines with a delicate red background. Way better
than the violent alternative ;) Plus, I only set it for the Python filetype. |
|
Date |
User |
Action |
Args |
2010-08-08 19:02:52 | lukasz.langa | set | recipients:
+ lukasz.langa, fdrake, ezio.melotti, eric.araujo, brian.curtin |
2010-08-08 19:02:52 | lukasz.langa | set | messageid: <1281294172.27.0.908017468918.issue9452@psf.upfronthosting.co.za> |
2010-08-08 19:02:50 | lukasz.langa | link | issue9452 messages |
2010-08-08 19:02:50 | lukasz.langa | create | |
|