Skip to content

gh-105285: Use UTF-8 on email content when CTE is '8bit'#105306

Closed
michaelfm1211 wants to merge 4 commits into
python:mainfrom
michaelfm1211:use-utf8-for-cte-8bit
Closed

gh-105285: Use UTF-8 on email content when CTE is '8bit'#105306
michaelfm1211 wants to merge 4 commits into
python:mainfrom
michaelfm1211:use-utf8-for-cte-8bit

Conversation

@michaelfm1211

@michaelfm1211 michaelfm1211 commented Jun 5, 2023

Copy link
Copy Markdown

When getting the payload of an email using
email.message.Message.get_payload() and passing decode=True, attempt to use UTF-8 if the Content-Transfer-Encoding header is '8bit'.

When getting the payload of an email using
email.message.Message.get_payload() and passing decode=True, attempt to
use UTF-8 if the Content-Transfer-Encoding header is '8bit'.
@ghost

ghost commented Jun 5, 2023

Copy link
Copy Markdown

All commit authors signed the Contributor License Agreement.
CLA signed

@michaelfm1211

Copy link
Copy Markdown
Author

Just came back to check on this, and it seems the documentation preview check hasn't passed even though there is no documentation to be built. I don't believe this change would require any documentation changes, as it's a bug fix.

@serhiy-storchaka serhiy-storchaka left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

UTF-8 is not always the right encoding. It should be self.get_param('charset', 'ascii').

@maimorag

maimorag commented Aug 6, 2024

Copy link
Copy Markdown

hey @michaelfm1211 @serhiy-storchaka,
what is the estimated time for the fix to be released?

@lorenzomorandini

Copy link
Copy Markdown

Hi, news on this? I'm currently facing the same problem and the fix seems to work.

@michaelfm1211

Copy link
Copy Markdown
Author

@lorenzomorandini Sorry, I kind of just forgot about this PR a few months ago when I was busy with work. I'll try to address the review today.

@python-cla-bot

Copy link
Copy Markdown

The following commit authors need to sign the Contributor License Agreement:

CLA signed

@github-actions

Copy link
Copy Markdown

This PR is stale because it has been open for 30 days with no activity.

@github-actions github-actions Bot added the stale Stale PR or inactive for long period of time. label Apr 13, 2026
@michaelfm1211 michaelfm1211 closed this by deleting the head repository May 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting review stale Stale PR or inactive for long period of time.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants