Issue 27630: Generator._encoded_EMTPY misspelling in email package (original) (raw)
Issue27630
This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.
This issue has been migrated to GitHub: https://github.com/python/cpython/issues/71817
classification
Title: | Generator._encoded_EMTPY misspelling in email package | ||
---|---|---|---|
Type: | Stage: | resolved | |
Components: | Versions: | Python 3.6, Python 3.5 |
process
Status: | closed | Resolution: | fixed |
---|---|---|---|
Dependencies: | Superseder: | ||
Assigned To: | r.david.murray | Nosy List: | barry, martin.panter, python-dev, r.david.murray |
Priority: | normal | Keywords: |
Created on 2016-07-27 01:07 by martin.panter, last changed 2022-04-11 14:58 by admin. This issue is now closed.
Messages (5) | ||
---|---|---|
msg271424 - (view) | Author: Martin Panter (martin.panter) * ![]() |
Date: 2016-07-27 01:07 |
In the Generator.flatten() (Lib/email/generator.py), the code sets, among others, the instance attributes _EMPTY (correct spelling) and _encoded_EMTPY (misspelling). Further down in that class, _encoded_EMPTY (correct spelling) is set as a class attribute, and this correctly-spelt version appears to be used in the _handle_message_delivery_status() method. The BytesGenerator class inherits Generator and overrides the correctly-spelt _encoded_EMPTY class attribute. It seems that both _EMPTY and the misspelt _encoded_EMTPY instance attributes are not used. Perhaps they should be removed. Or perhaps they are not doing the job they were intended for and there is a real bug. | ||
msg271451 - (view) | Author: R. David Murray (r.david.murray) * ![]() |
Date: 2016-07-27 14:02 |
The former is kept (IIRC) for backward compatibility, the latter should be investigated. Since I wrote that code I'll have to add this to my todo list. | ||
msg273998 - (view) | Author: Martin Panter (martin.panter) * ![]() |
Date: 2016-08-31 04:17 |
FYI in 3.6 the spelling has been changed to _EMPTY (Issue 27895) | ||
msg275235 - (view) | Author: Roundup Robot (python-dev) ![]() |
Date: 2016-09-09 02:28 |
New changeset 468961cea562 by R David Murray in branch '3.5': #27630: Be consistent in how _XXX/_encoded_XXX vars are initialized. https://hg.python.org/cpython/rev/468961cea562 New changeset ddb1cf7b7eb1 by R David Murray in branch 'default': Merge: #27630: Be consistent in how _XXX/_encoded_XXX vars are initialized. https://hg.python.org/cpython/rev/ddb1cf7b7eb1 | ||
msg275236 - (view) | Author: R. David Murray (r.david.murray) * ![]() |
Date: 2016-09-09 02:30 |
Cleaned up the code. It was basically working by accident with the misspelling. |
History | |||
---|---|---|---|
Date | User | Action | Args |
2022-04-11 14:58:34 | admin | set | github: 71817 |
2016-09-09 02:30:10 | r.david.murray | set | status: open -> closedresolution: fixedmessages: + stage: resolved |
2016-09-09 02:28:36 | python-dev | set | nosy: + python-devmessages: + |
2016-09-01 04:57:53 | rhettinger | set | assignee: r.david.murray |
2016-08-31 04:17:28 | martin.panter | set | messages: + |
2016-07-27 14:02:00 | r.david.murray | set | messages: + |
2016-07-27 01:07:13 | martin.panter | create |