Brandon Rhodes added the comment:

I agree that is_attachment supports the most common use-case of people who need 
to inspect the content disposition!

But people implementing heavyweight tools and email clients might additionally 
need to distinguish between a MIME part whose disposition is explicitly 
"inline" and a MIME part whose disposition is simply unspecified — since the 
RFC seems to allow clients quite a bit of freedom in the case where it is 
entirely unspecified:

"Content-Disposition is an optional header field. In its absence, the MUA may 
use whatever presentation method it deems suitable." — RFC 2183

And a three-possibility 'inline'|'attachment'|None return value from 
get_content_disposition() would perfectly reflect the three possibilities 
envisioned in the standard.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue21079>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to