Re: [PATCH] test: Make gen-threads work with python3
authorJesse Rosenthal <jrosenthal@jhu.edu>
Fri, 31 Oct 2014 18:04:50 +0000 (14:04 +2000)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 18:05:59 +0000 (10:05 -0800)
55/cf0c181c2910b5642ee4fc59446df8105001a1 [new file with mode: 0644]

diff --git a/55/cf0c181c2910b5642ee4fc59446df8105001a1 b/55/cf0c181c2910b5642ee4fc59446df8105001a1
new file mode 100644 (file)
index 0000000..6e6c773
--- /dev/null
@@ -0,0 +1,79 @@
+Return-Path: <prvs=374b26013=jrosenthal@jhu.edu>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id 53675431FBC\r
+       for <notmuch@notmuchmail.org>; Fri, 31 Oct 2014 12:05:02 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: 0\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none]\r
+       autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+       by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+       with ESMTP id nUauVPg7SM9G for <notmuch@notmuchmail.org>;\r
+       Fri, 31 Oct 2014 12:04:54 -0700 (PDT)\r
+X-Greylist: delayed 3602 seconds by postgrey-1.32 at olra;\r
+       Fri, 31 Oct 2014 12:04:54 PDT\r
+Received: from smtpauth.johnshopkins.edu (smtpauth.johnshopkins.edu\r
+       [128.220.229.147]) (using TLSv1 with cipher RC4-SHA (128/128 bits))\r
+       (No client certificate requested)\r
+       by olra.theworths.org (Postfix) with ESMTPS id 91FCE431FAF\r
+       for <notmuch@notmuchmail.org>; Fri, 31 Oct 2014 12:04:54 -0700 (PDT)\r
+X-IronPort-AV: E=Sophos;i="5.07,295,1413259200"; d="scan'208";a="17204995"\r
+Received: from guppy.hwcampus.jhu.edu (HELO localhost) ([10.161.32.234])\r
+       by IPMTW1.johnshopkins.edu with ESMTP/TLS/AES128-SHA;\r
+       31 Oct 2014 14:04:51 -0400\r
+From: Jesse Rosenthal <jrosenthal@jhu.edu>\r
+To: "W. Trevor King" <wking@tremily.us>\r
+Subject: Re: [PATCH] test: Make gen-threads work with python3\r
+In-Reply-To: <20141031174153.GQ15443@odin.tremily.us>\r
+References: <1414776805-30000-1-git-send-email-jrosenthal@jhu.edu>\r
+       <20141031174153.GQ15443@odin.tremily.us>\r
+User-Agent: Notmuch/0.18.2+156~g1f413d7 (http://notmuchmail.org) Emacs/24.4.1\r
+       (i686-pc-linux-gnu)\r
+Date: Fri, 31 Oct 2014 14:04:50 -0400\r
+Message-ID: <87bnosdsjh.fsf@jhu.edu>\r
+MIME-Version: 1.0\r
+Content-Type: text/plain; charset=utf-8\r
+Content-Transfer-Encoding: quoted-printable\r
+Cc: notmuch@notmuchmail.org\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+       <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Fri, 31 Oct 2014 19:05:02 -0000\r
+\r
+"W. Trevor King" <wking@tremily.us> writes:\r
+\r
+> On Fri, Oct 31, 2014 at 01:33:25PM -0400, Jesse Rosenthal wrote:\r
+>> We instead initalize the dictionary using the dict comprehension and\r
+>> then update it with the values from the tree. This will work with\r
+>> both python2 and python3.\r
+>\r
+> Dict comprehensions are new in 2.7 [1,2], so this drops support for\r
+> systems where =E2=80=98python=E2=80=99 means =E2=80=98python2.6=E2=80=99.=\r
+  Personally, I'm fine with\r
+> that, but I thought I'd point it out in case 2.6 users wanted to push\r
+> back ;).\r
+\r
+The comprehension was already in the previous version, so I figured that\r
+people were already cool with 2.7+.\r
+\r
+>> -\r
+>>  import sys\r
+>\r
+> Why remove this blank line?\r
+\r
+Oops -- I had put in a print_function import from __future__ for\r
+testing. Must have lost the line when I took it back out. Is it worth\r
+resubmitting to fix that?\r