Improve readability of formataddr docstring#20963
Conversation
modified: Lib/email/utils.py
| returned unmodified. | ||
|
|
||
| Optional charset if given is the character set that is used to encode | ||
| Optional charset, if given, is the character set that is used to encode |
There was a problem hiding this comment.
I agree to this change. IMHO for no natives is more natural read this, but I don't know if this change is normal for a native English speaker.
But, I think that we should remove the if given sentences, because, when the docstring say "Optional charset" that reference that charset could be given or not. Optional params.
There was a problem hiding this comment.
Thanks for your reply. I am happy about any change which makes the docstring more readable.
And indeed, the sentence is much nicer without the if given clause.
I applied your suggestion with a follow up commit.
I noticed this if given pattern is used more often in this module. Should the other places also be updated?
This makes the docstring easier to comprehend. modified: Lib/email/utils.py
|
Sorry, I can't merge this PR. Reason: |
|
@jugmac00: Status check is done, and it's a success ✅ . |
1 similar comment
|
@jugmac00: Status check is done, and it's a success ✅ . |
|
Sorry, I can't merge this PR. Reason: |
1 similar comment
|
Sorry, I can't merge this PR. Reason: |
|
Thanks @jugmac00 for the PR 🌮🎉.. I'm working now to backport this PR to: 3.8, 3.9. |
|
Sorry @jugmac00, I had trouble checking out the |
|
GH-20977 is a backport of this pull request to the 3.8 branch. |
|
Thanks @jugmac00 for the PR 🌮🎉.. I'm working now to backport this PR to: 3.9. |
|
GH-20978 is a backport of this pull request to the 3.9 branch. |
For me as a non native English speaker, the sentence with its embedded clause was very hard to understand. modified: Lib/email/utils.py Automerge-Triggered-By: @csabella
For me as a non native English speaker, the sentence with its embedded clause was very hard to understand.
modified: Lib/email/utils.py
Automerge-Triggered-By: @csabella