Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Unify all smtplib commands to be uppercase #136191

Open
Labels
stdlibPython modules in the Lib dirtopic-emailtype-featureA feature request or enhancement
@MrExcitingDigits

Description

@MrExcitingDigits

Hello,

I know there was aprevious issue made years ago about smtplib being inconsistent with uppercase and lowercase commands, however the succeeding fix made the commands lowercase. I think these should be switched to uppercase and here's why:

RFC 5321 states"A few SMTP servers, in violation of this specification (andRFC 821) require that command verbs be encoded by clients in upper case. Implementations MAY wish to employ this encoding to accommodate those servers."

Servers such as Postfix and many others have resolved to simply making all SMTP commands and options uppercase as depicted (though not required) in all the RFC documents. Though it is not strictly necessary, it will have better support (even if marginally) and is a quick fix.

Also, smtplib seems to already send some of these commands and options like STARTTLS and SMTPUTF8 uppercase which technically leaves the inconsistency of the last issue unsolved.

Ultimately, I think it would be best for posterity to simply make all of these uppercase and it should be a quick fix.

I can make the proper edits and make a pull request if there isn't some obvious reason for this I'm missing.

Let me know your thoughts! 🙂

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    stdlibPython modules in the Lib dirtopic-emailtype-featureA feature request or enhancement

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp