--
Ticket URL: <https://code.djangoproject.com/ticket/30512>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
* has_patch: 0 => 1
--
Ticket URL: <https://code.djangoproject.com/ticket/30512#comment:1>
* stage: Unreviewed => Accepted
--
Ticket URL: <https://code.djangoproject.com/ticket/30512#comment:2>
Comment (by Mariusz Felisiak <felisiak.mariusz@…>):
In [changeset:"f841a776feb2b0522c7a919f7355002b8762731a" f841a77]:
{{{
#!CommitTicketReference repository=""
revision="f841a776feb2b0522c7a919f7355002b8762731a"
Refs #30512 -- Used subTest() in MailTests.test_sanitize_address.
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/30512#comment:3>
Comment (by Mariusz Felisiak <felisiak.mariusz@…>):
In [changeset:"8ba20d9071e9e1b8f2c81d4df977db4278342085" 8ba20d90]:
{{{
#!CommitTicketReference repository=""
revision="8ba20d9071e9e1b8f2c81d4df977db4278342085"
Refs #30512 -- Added tests for sanitizing email addresses with display
name and two @ signs.
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/30512#comment:4>
* needs_tests: 0 => 1
--
Ticket URL: <https://code.djangoproject.com/ticket/30512#comment:5>
* needs_tests: 1 => 0
--
Ticket URL: <https://code.djangoproject.com/ticket/30512#comment:6>
* stage: Accepted => Ready for checkin
--
Ticket URL: <https://code.djangoproject.com/ticket/30512#comment:7>
* status: assigned => closed
* resolution: => fixed
Comment:
In [changeset:"2628ea95151feb68f43a2a740e6fb0799a94b14b" 2628ea95]:
{{{
#!CommitTicketReference repository=""
revision="2628ea95151feb68f43a2a740e6fb0799a94b14b"
Fixed #30512 -- Used email.headerregistry.parser for parsing emails in
sanitize_address().
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/30512#comment:8>
Comment (by Carlton Gibson <carlton@…>):
In [changeset:"1564e42ad397021093585147875a21dae1a3b3fc" 1564e42a]:
{{{
#!CommitTicketReference repository=""
revision="1564e42ad397021093585147875a21dae1a3b3fc"
Refs #30512, #15042 -- Added local-only address to sanitize_email() tests
cases.
email.headerregistry.parser.get_mailbox() returns a token with a
`token_type` attribute.
If `token_type` is `’invalid-mailbox’` then RFC violations have been
detected. Emails with only the local part, and no domain, are correctly
parsed but are marked as `’invalid-mailbox’`.
As per #15042, local-only are supported, to enable sending to addresses on
localhost.
sanitize_email() does not currently check `token_type`. This test is added
to avoid a regression in case this is revisited in the future.
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/30512#comment:9>