Issue 1032960: Confusing description of strict option for email.Parser (original) (raw)
Issue1032960
Created on 2004-09-22 20:50 by spiv, last changed 2022-04-11 14:56 by admin. This issue is now closed.
Messages (3) | ||
---|---|---|
msg22522 - (view) | Author: Andrew Bennetts (spiv) | Date: 2004-09-22 20:50 |
The docs at http://www.python.org/dev/doc/devel/lib/node534.html say: "Normally, when things like MIME terminating boundaries are missing, or when messages contain other formatting problems, the Parser will raise a MessageParseError. However, when lax parsing is enabled, the Parser will attempt to work around such broken formatting ..." Which strongly suggests that the 'strict' flag defaults to True. However, it later says: "The strict flag defaults to False since lax parsing usually provides the most convenient behavior." I suggest the paragraph be reworded to avoid giving the impression that strict is True by default. Perhaps something like: "The optional strict flag specifies whether strict or lax parsing should be performed. When things like MIME terminating boundaries are missing, or when messages contain other formatting problems, the Parser will raise a MessageParseError if the strict flag is True. Otherwise, it uses lax parsing, and the Parser will attempt to work around such broken formatting to produce a usable message structure (this doesn't mean MessageParseErrors are never raised; some ill-formatted messages just can't be parsed). The strict flag defaults to False since lax parsing usually provides the most convenient behavior." | ||
msg22523 - (view) | Author: Barry A. Warsaw (barry) * ![]() |
Date: 2004-10-09 21:22 |
Logged In: YES user_id=12800 Changing group to Python 2.3, since the 'strict' argument is deprecated in Python 2.4. | ||
msg22524 - (view) | Author: Barry A. Warsaw (barry) * ![]() |
Date: 2004-10-09 21:29 |
Logged In: YES user_id=12800 I've improved the docs for the Python 2.3 version; it should show up in Python 2.3.5. |
History | |||
---|---|---|---|
Date | User | Action | Args |
2022-04-11 14:56:07 | admin | set | github: 40944 |
2004-09-22 20:50:46 | spiv | create |