Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Encoding of "=" by quopri.py module #33259

Closed
gillou mannequin opened this issue Oct 3, 2000 · 2 comments
Closed

Encoding of "=" by quopri.py module #33259

gillou mannequin opened this issue Oct 3, 2000 · 2 comments
Labels
stdlib Python modules in the Lib dir

Comments

@gillou
Copy link
Mannequin

gillou mannequin commented Oct 3, 2000

BPO 215907

Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

Show more details

GitHub fields:

assignee = None
closed_at = <Date 2000-10-05.17:24:51.000>
created_at = <Date 2000-10-03.12:47:04.000>
labels = ['library']
title = 'Encoding of "=" by quopri.py module'
updated_at = <Date 2000-10-05.17:24:51.000>
user = 'https://bugs.python.org/gillou'

bugs.python.org fields:

activity = <Date 2000-10-05.17:24:51.000>
actor = 'jhylton'
assignee = 'jhylton'
closed = True
closed_date = None
closer = None
components = ['Library (Lib)']
creation = <Date 2000-10-03.12:47:04.000>
creator = 'gillou'
dependencies = []
files = []
hgrepos = []
issue_num = 215907
keywords = []
message_count = 2.0
messages = ['1785', '1786']
nosy_count = 2.0
nosy_names = ['jhylton', 'gillou']
pr_nums = []
priority = 'normal'
resolution = 'fixed'
stage = None
status = 'closed'
superseder = None
type = None
url = 'https://bugs.python.org/issue215907'
versions = []

@gillou
Copy link
Mannequin Author

gillou mannequin commented Oct 3, 2000

While making an automated mail sending engine, I used the quopri.encode(...) for my multipart mails.
quopri.encode(...) converts "=" into "==" while the mail clients expect "=3D". Thus I got some problems reading such mails with Outlook Express 5 , Netscape Messenger (Linux) and StarOffice Mail (Linux). Especially when the HTML part of the mail contains hyperkinks <a href=...>...</a> that crash Outlook express. The others make a 404 HTTP error.
I run Python 1.5.2, but this bug/feature remains perhaps with Python 1.6 and Python 2.0bx cause I didn't notice any change log to the quopri module.
I found a workaround (fix ?) by changing the "quote" function of "quopri.py" to this:
==== quopri.py ====
...
def quote(c):
## if c == ESCAPE:
## return ESCAPE * 2
## else:
i = ord(c)
return ESCAPE + HEX[i/16] + HEX[i%16]
...
==== end quopri.py ====
Now, the 3 above mentioned mail clients read correctly the raw text and html parts of my mails - including hyperlinks.
Is it a bug, a feature, or did I misuse "quopri" ?

@gillou gillou mannequin closed this as completed Oct 3, 2000
@gillou gillou mannequin assigned jhylton Oct 3, 2000
@gillou gillou mannequin added the stdlib Python modules in the Lib dir label Oct 3, 2000
@gillou gillou mannequin closed this as completed Oct 3, 2000
@gillou gillou mannequin assigned jhylton Oct 3, 2000
@gillou gillou mannequin added the stdlib Python modules in the Lib dir label Oct 3, 2000
@jhylton
Copy link
Mannequin

jhylton mannequin commented Oct 5, 2000

fixed in revision 1.7 of quopri

@ezio-melotti ezio-melotti transferred this issue from another repository Apr 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stdlib Python modules in the Lib dir
Projects
None yet
Development

No branches or pull requests

0 participants