1 Return-Path: <wking@tremily.us>
\r
2 X-Original-To: notmuch@notmuchmail.org
\r
3 Delivered-To: notmuch@notmuchmail.org
\r
4 Received: from localhost (localhost [127.0.0.1])
\r
5 by olra.theworths.org (Postfix) with ESMTP id 0B87C431FBC
\r
6 for <notmuch@notmuchmail.org>; Fri, 31 Oct 2014 10:52:28 -0700 (PDT)
\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org
\r
11 X-Spam-Status: No, score=-0.1 tagged_above=-999 required=5
\r
12 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,
\r
13 RCVD_IN_DNSWL_NONE=-0.0001] autolearn=disabled
\r
14 Received: from olra.theworths.org ([127.0.0.1])
\r
15 by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)
\r
16 with ESMTP id koG9-Oa921tT for <notmuch@notmuchmail.org>;
\r
17 Fri, 31 Oct 2014 10:52:20 -0700 (PDT)
\r
18 Received: from resqmta-po-12v.sys.comcast.net (resqmta-po-12v.sys.comcast.net
\r
20 (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits))
\r
21 (No client certificate requested)
\r
22 by olra.theworths.org (Postfix) with ESMTPS id 2D14D431FAF
\r
23 for <notmuch@notmuchmail.org>; Fri, 31 Oct 2014 10:52:20 -0700 (PDT)
\r
24 Received: from resomta-po-02v.sys.comcast.net ([96.114.154.226])
\r
25 by resqmta-po-12v.sys.comcast.net with comcast
\r
26 id 9tqZ1p0024tLnxL01tsJle; Fri, 31 Oct 2014 17:52:18 +0000
\r
27 Received: from odin.tremily.us ([24.18.63.50])
\r
28 by resomta-po-02v.sys.comcast.net with comcast
\r
29 id 9thv1p00Q152l3L01ti3Xl; Fri, 31 Oct 2014 17:42:12 +0000
\r
30 Received: by odin.tremily.us (Postfix, from userid 1000)
\r
31 id 3CD211440A7F; Fri, 31 Oct 2014 10:41:54 -0700 (PDT)
\r
32 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tremily.us; s=odin;
\r
33 t=1414777314; bh=Lutqs67YYHlAbTVAM2EYRXM3FafEluZlR2k48xZ1Q1U=;
\r
34 h=Date:From:To:Cc:Subject:References:In-Reply-To;
\r
35 b=DrisrplZj20MsSXDXeBr13AsOIe/ayIhIEY1saJRyuUQY15e/L+soFz3ERLQKAUy3
\r
36 88wk4kGKjQRWhm1zWhQXW6wgBfFLCpti/QOBOimHfoVWHDfHlBmN89AeKXbPQj4Msr
\r
37 HN5ekoEf4Q2a/uqPOlep+gKSzAn81wBYcmeINgwo=
\r
38 Date: Fri, 31 Oct 2014 10:41:54 -0700
\r
39 From: "W. Trevor King" <wking@tremily.us>
\r
40 To: Jesse Rosenthal <jrosenthal@jhu.edu>
\r
41 Subject: Re: [PATCH] test: Make gen-threads work with python3
\r
42 Message-ID: <20141031174153.GQ15443@odin.tremily.us>
\r
43 References: <1414776805-30000-1-git-send-email-jrosenthal@jhu.edu>
\r
45 Content-Type: multipart/signed; micalg=pgp-sha1;
\r
46 protocol="application/pgp-signature"; boundary="1ysCV03AuJYXZqZy"
\r
47 Content-Disposition: inline
\r
48 In-Reply-To: <1414776805-30000-1-git-send-email-jrosenthal@jhu.edu>
\r
49 OpenPGP: id=39A2F3FA2AB17E5D8764F388FC29BDCDF15F5BE8;
\r
50 url=http://tremily.us/pubkey.txt
\r
51 User-Agent: Mutt/1.5.23 (2014-03-12)
\r
52 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=comcast.net;
\r
53 s=q20140121; t=1414777938;
\r
54 bh=4sWcCrYS40AKzwEe2xDTg9efvrUgPgVc8ZBUWnfqLi4=;
\r
55 h=Received:Received:Received:Date:From:To:Subject:Message-ID:
\r
56 MIME-Version:Content-Type;
\r
57 b=XYc565AnV+Vcl0EKK4zPuJVvDo7f2pm+q43iSCfnf32UkT01W1SclqhTCNiaS2+bb
\r
58 sIUOI5gVIOXPxOntN7Uf21XGf28jS+njThqm9KwX+/AchqQmU8m3OHy9kfcI20NmuK
\r
59 dDwUwgbI4G5R0xtf/lkSNFJABXJYCU9yMNwIdujR1xiExNNqKcQxm8imC3Te6C8ZEx
\r
60 +FUxw/JJ1vwjYXcQO2njjuu7r70r5x3BHLygDLRJR4o/OAfbCDnGoRJRc65xzoBO4E
\r
61 YXkaUvjiqDPw/mpAa6KdTJSAA18rElnTrelCGkKwg4H8Z/lWj4o05RwEmvm+CUfzEa
\r
63 Cc: notmuch@notmuchmail.org
\r
64 X-BeenThere: notmuch@notmuchmail.org
\r
65 X-Mailman-Version: 2.1.13
\r
67 List-Id: "Use and development of the notmuch mail system."
\r
68 <notmuch.notmuchmail.org>
\r
69 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
70 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
71 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
72 List-Post: <mailto:notmuch@notmuchmail.org>
\r
73 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
74 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
75 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
76 X-List-Received-Date: Fri, 31 Oct 2014 17:52:28 -0000
\r
80 Content-Type: text/plain; charset=utf-8
\r
81 Content-Disposition: inline
\r
82 Content-Transfer-Encoding: quoted-printable
\r
84 On Fri, Oct 31, 2014 at 01:33:25PM -0400, Jesse Rosenthal wrote:
\r
85 > We instead initalize the dictionary using the dict comprehension and
\r
86 > then update it with the values from the tree. This will work with
\r
87 > both python2 and python3.
\r
89 Dict comprehensions are new in 2.7 [1,2], so this drops support for
\r
90 systems where =E2=80=98python=E2=80=99 means =E2=80=98python2.6=E2=80=99. =
\r
91 Personally, I'm fine with
\r
92 that, but I thought I'd point it out in case 2.6 users wanted to push
\r
95 > diff --git a/test/gen-threads.py b/test/gen-threads.py
\r
96 > index 9fbb847..70fb1f6 100644
\r
97 > --- a/test/gen-threads.py
\r
98 > +++ b/test/gen-threads.py
\r
100 > # argv[1]. Each output line is a thread structure, where the n'th
\r
101 > # field is either a number giving the parent of message n or "None"
\r
106 Why remove this blank line?
\r
108 > from itertools import chain, combinations
\r
110 > @@ -28,6 +27,7 @@ while queue:
\r
112 > # Expand node to_expand[0] with each possible set of children
\r
113 > for children in subsets(free):
\r
114 > - ntree =3D dict(tree, **{child: to_expand[0] for child in chi=
\r
116 > + ntree =3D {child: to_expand[0] for child in children}
\r
117 > + ntree.update(tree)
\r
119 This looks good to me.
\r
124 [1]: https://docs.python.org/3/whatsnew/2.7.html#other-language-changes
\r
125 [2]: http://legacy.python.org/dev/peps/pep-0274/
\r
128 This email may be signed or encrypted with GnuPG (http://www.gnupg.org).
\r
129 For more information, see http://en.wikipedia.org/wiki/Pretty_Good_Privacy
\r
132 Content-Type: application/pgp-signature; name="signature.asc"
\r
133 Content-Description: OpenPGP digital signature
\r
135 -----BEGIN PGP SIGNATURE-----
\r
138 iQIcBAEBAgAGBQJUU8nZAAoJEG8/JgBt8ol84FEQAOIXlvnkl0mReM3hkg6W4hvJ
\r
139 AOCdUjUtfE/UGV7SlYFZEuFBLDN4F73DcNvxilF37QaSFf+xoK9FRfMQ5lyPmQW2
\r
140 LV51axuXnAqCpHdgWAkurn8VB6KnzQE6nC97iv21ROYXewk3TFPHp9+ZM3+3JAz4
\r
141 PjFzcy7hGEKK9AOcS8X7C+SmaF6vZg+Bj+e9qJj1FAAsF9gWoHYOPzYWSdoOAJrG
\r
142 QI2Pm3vVm6wVRBZOgVshQKl5ZmuK/u2nQZ+8Kf57ttSmZ3D5J+mf1Ufj0sf3DkGo
\r
143 1umP4EuMcKiJLS8/iAY0wfwj+4qd+Nm5bCxxaRo3DYxWdHeIrvgE1lMnWRD36YzA
\r
144 0Xa4ZmL+B7L3zAuqorcRk87SXNQ6sgPEK7Q6azG9CSmbC7PBRFLaUtc6ANhc14Lf
\r
145 FEBusHfYAcACWOE8qfX85AxtshJuf3Y6f7DbXic2sJzVE3t/bkor5IuOy0xenq2/
\r
146 eNjenxGgfutE8fCB8abnX0iWha2BYzCqKg8qwlxmGRGk7XwIFqy9CWzAaBR5clHN
\r
147 FCCZ2aNZlz+F4xDgwbKXh7vlCfzCT3sQ2ZAGoRagbzql2vOOyl9qY0/GKZC2Vvn/
\r
148 ka7/y8kRvVl5V0zK7Pgjc75pHm00dqLYIp5McflD2eSaAHDnIATn+y9HHLvJMIAn
\r
149 K1ln76S+clh2Kb2L/82A
\r
151 -----END PGP SIGNATURE-----
\r
153 --1ysCV03AuJYXZqZy--
\r