Opened 6 years ago

Last modified 2 years ago

#24213 new New feature

RFC 2231 Section 4.1 is not implemented

Reported by: Raúl Cumplido Owned by: Raúl Cumplido
Component: HTTP handling Version: master
Severity: Normal Keywords:
Cc: raulcumplido@…, Herbert Fortes Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description (last modified by Anton Samarchyan)

Currently RFC 2231 Section 4 is implemented (there is a closed PR from me for a fix), but section 4.1 of the RFC is not implemented:
Section 4.1 is about being able to have parameter continuation when combining Character Set and language Language headers:

Content-Type: application/x-stuff
    title*2="isn't it!"

Change History (6)

comment:1 Changed 6 years ago by Raúl Cumplido

Cc: raulcumplido@… added
Needs tests: set
Type: UncategorizedNew feature

comment:2 Changed 6 years ago by Berker Peksag

If I understand you correctly, this is already implemented in the stdlib email module:

from email import message_from_string

s = """\
Content-Type: application/x-stuff;
\ttitle*2=\"isn't it!\"

m = message_from_string(s)

# output is
# ('us-ascii', 'en', "This is even more ***fun*** isn't it!")

See also for relevant tests.

comment:3 Changed 6 years ago by Raúl Cumplido

Yes, this is exactly what we should implement. The status is still new so I'll expect someone to Accept it or close it :)

comment:4 Changed 6 years ago by Claude Paroz

Component: UncategorizedHTTP handling
Needs tests: unset
Triage Stage: UnreviewedAccepted

Here you go :-)

comment:5 Changed 4 years ago by Anton Samarchyan

Description: modified (diff)

comment:6 Changed 2 years ago by Herbert Fortes

Cc: Herbert Fortes added
Note: See TracTickets for help on using tickets.
Back to Top