[issue30701] Exception parsing certain invalid email address headers

2019-09-12 Thread Tim Bell
Tim Bell added the comment: This appears to be the same issue as subsequently reported in #34155. -- ___ Python tracker <https://bugs.python.org/issue30

[issue30681] email.utils.parsedate_to_datetime() should return None when date cannot be parsed

2017-06-15 Thread Tim Bell
New submission from Tim Bell: Python 3.6 documentation for email.utils.parsedate_to_datetime() says "Performs the same function as parsedate(), but on success returns a datetime." The docs for parsedate() say "If it succeeds in parsing the date...; otherwise None will b

[issue30681] email.utils.parsedate_to_datetime() should return None when date cannot be parsed

2017-06-15 Thread Tim Bell
Changes by Tim Bell : -- pull_requests: +2274 ___ Python tracker <http://bugs.python.org/issue30681> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue30681] email.utils.parsedate_to_datetime() should return None when date cannot be parsed

2017-06-15 Thread Tim Bell
Tim Bell added the comment: My proposed solution (in https://github.com/python/cpython/pull/2229) is two-part: 1. change parsedate_to_datetime() to return None rather than raising an exception; and 2. change headerregistry.DateHeader.parse() to check for None being returned from

[issue30681] email.utils.parsedate_to_datetime() should return None when date cannot be parsed

2017-06-16 Thread Tim Bell
Changes by Tim Bell : -- pull_requests: +2304 ___ Python tracker <http://bugs.python.org/issue30681> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue30681] email.utils.parsedate_to_datetime() should return None when date cannot be parsed

2017-06-16 Thread Tim Bell
Tim Bell added the comment: Thanks for the feedback. I've made a new pull request which addresses the points raised. -- ___ Python tracker <http://bugs.python.org/is

[issue30681] email.utils.parsedate_to_datetime() should return None when date cannot be parsed

2017-06-17 Thread Tim Bell
Tim Bell added the comment: I've updated the pull request to incorporate Barry's suggestion of a new defect for this situation, InvalidDateDefect. -- ___ Python tracker <http://bugs.python.o

[issue30701] Exception parsing certain invalid email address headers

2017-06-19 Thread Tim Bell
New submission from Tim Bell: According to RFC 5322, an email address like this isn't valid: u...@example.com (The display-name "u...@example.com" contains "@", which isn't in the set of atext characters used to form an atom.) How it's handled by

[issue30701] Exception parsing certain invalid email address headers

2017-06-19 Thread Tim Bell
Tim Bell added the comment: I'm using the email package to ingest a firehose of spam; spammers aren't known for following norms or standards, so it's not surprising that I'm discovering lots of edge cases. I'll supply fixes for what I find whe

[issue30988] Exception parsing invalid email address headers starting or ending with dot

2017-07-21 Thread Tim Bell
New submission from Tim Bell: Email addresses with a display name starting with a dot ("."), or ending with a dot without whitespace before the angle bracket trigger exceptions when accessing the header, after creating the message object with the "default" policy. For

[issue30988] Exception parsing invalid email address headers starting or ending with dot

2017-07-21 Thread Tim Bell
Changes by Tim Bell : -- pull_requests: +2862 ___ Python tracker <http://bugs.python.org/issue30988> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue30681] email.utils.parsedate_to_datetime() should return None when date cannot be parsed

2018-11-28 Thread Tim Bell
Change by Tim Bell : -- keywords: +patch pull_requests: +10025 stage: -> patch review ___ Python tracker <https://bugs.python.org/issue30681> ___ ___ Python-

[issue30681] email.utils.parsedate_to_datetime() should return None when date cannot be parsed

2018-11-28 Thread Tim Bell
Tim Bell added the comment: I've addressed the points in the last few comments and created a new PR (10783). -- ___ Python tracker <https://bugs.python.org/is