This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Parsing different styles of email address in a header line. | |
| # Some are invalid and may throw an exception. See: | |
| # https://github.com/python/cpython/issues/75171 | |
| from email.parser import Parser | |
| from email.policy import default | |
| headers = [ | |
| 'From: me<me@example.net>', | |
| 'From: me<me@example.>', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 🎷 This is not a pipe. | |
| It is a gist. |