From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 6BF6A429E27 for ; Fri, 18 Nov 2011 17:59:01 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -2.29 X-Spam-Level: X-Spam-Status: No, score=-2.29 tagged_above=-999 required=5 tests=[RCVD_IN_DNSWL_MED=-2.3, T_MIME_NO_TEXT=0.01] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Ujr--0lI+vTX for ; Fri, 18 Nov 2011 17:59:00 -0800 (PST) Received: from outgoing-mail.its.caltech.edu (outgoing-mail.its.caltech.edu [131.215.239.19]) by olra.theworths.org (Postfix) with ESMTP id C4E12431FD0 for ; Fri, 18 Nov 2011 17:59:00 -0800 (PST) Received: from earth-doxen.imss.caltech.edu (localhost [127.0.0.1]) by earth-doxen-postvirus (Postfix) with ESMTP id 4007666E01C2; Fri, 18 Nov 2011 17:58:58 -0800 (PST) X-Spam-Scanned: at Caltech-IMSS on earth-doxen by amavisd-new Received: from finestructure.net (DHCP-123-180.caltech.edu [131.215.123.180]) (Authenticated sender: jrollins) by earth-doxen-submit (Postfix) with ESMTP id 62F5666E0134; Fri, 18 Nov 2011 17:58:55 -0800 (PST) Received: by finestructure.net (Postfix, from userid 1000) id 43922ACC; Fri, 18 Nov 2011 17:58:55 -0800 (PST) From: Jameson Graef Rollins To: Dmitry Kurochkin , notmuch@notmuchmail.org Subject: Re: [PATCH] Output unmodified Content-Type header value for JSON format. In-Reply-To: <1321659905-24367-1-git-send-email-dmitry.kurochkin@gmail.com> References: <1321659905-24367-1-git-send-email-dmitry.kurochkin@gmail.com> User-Agent: Notmuch/0.9+81~gd8cf814 (http://notmuchmail.org) Emacs/23.3.1 (x86_64-pc-linux-gnu) Date: Fri, 18 Nov 2011 17:58:52 -0800 Message-ID: <87fwhkyisj.fsf@servo.finestructure.net> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 19 Nov 2011 01:59:01 -0000 --=-=-= On Sat, 19 Nov 2011 03:45:05 +0400, Dmitry Kurochkin wrote: > Before the change, notmuch used g_mime_content_type_to_string(3) > function to output Content-Type header value. Turns out it outputs > only "type/subtype" part and ignores all parameters. Also, if there > is no Content-Type header, default "text/plain" value is used. Hi, Dmitry. Can you explain under what circumstances you would need the extra content-type parameters? It just seems like a lot of extra noise in the output to me, but that's partially because I can't think of any reason why something that is receiving pre-parsed mime content would need it. Maybe there's a better way to handle what you're trying to get to. I think it would help a lot if you could submit some sort of test modification that demonstrates the issue. This is one of the reasons we keep emphasizing that it's good to first have tests in hand that demonstrate issues before patches that address them. > "content": [{"id": 2, > - "content-type": "text/plain", > "content": "This is a test signed message.\n"}, Without figuring out what's going on, I notice that some of the tests have been modified to remove the content-type fields on a bunch of parts. I think that is probably not right. jamie. --=-=-= Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) iQIcBAEBCAAGBQJOxw1cAAoJEO00zqvie6q8hDkP/Aum2noyxQn0lJPXu4tXfDPv FwQhuCLJOyuuSR3wtcQlZZPZ1uorY6f06J44QpjB9yAUEv5IUB9KfzbkLgpKLQJd 9Cs54Bh3aTCoQLpKXyWSb2y9JoQEI4/tK1Jm98RzIA4RZ4Bg6sop+MQsTLpM5ULn 3xKyCuIkKeVoO9B9unIZoWR4aBbmj8nig333MgxzT3aaXXesF0iON+WVi52rfXC5 0ebBJoyY1mOJxJoUUmLJBa+2AWnGLyf7XYbl0y4x/RUPbUSGJ+O8LU3O9uLKyxSi NlBtSr/Rj/xUyOFQwnz37P7CxotqSNWpbYqEHl9G+9R2LgsJdDITOOw3Car8lWhm //f1OxW0gyPVrDDrZhplWWOID7SGQ/SWMsSXkPayYxox8ExyxJu0mg/V6x3b4Nqf SSXThr0sSpYrYYlmpZO5vI1GEIC6MrvC5pisP8dOHHb3pNEL6YVQYmYP+CwUaZux ZCyhChiWXbpkBm6tGpAoYdNbDr7Z/uwkdGKvUo0Es7s4qetCes9LhfZLslGACIRy 5z7xHaQ+7C9t4XixuW1dAKBZGjImuaJFnRQRBNxZknD/oF65k7nANkpyG8EEVRZw +Ffmrb+Ltio3t29ecBSj7QvJIWqTfIX9vK40VVrJPQerEB7STlKIlhYXkq54HEoE yNIIAuJvEGpATBr66aFN =tZ5D -----END PGP SIGNATURE----- --=-=-=--