From 351ee4b09d37dbeeff05968f4bce8217318cd24e Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Wed, 13 Jan 2016 11:13:50 +1600 Subject: [PATCH] Binding access to ~/.notmuch-config (was: Crash with Python bindings) --- 30/ef65e9fe61e2527aca7d60b41eb6de80d514ed | 127 ++++++++++++++++++++++ 1 file changed, 127 insertions(+) create mode 100644 30/ef65e9fe61e2527aca7d60b41eb6de80d514ed diff --git a/30/ef65e9fe61e2527aca7d60b41eb6de80d514ed b/30/ef65e9fe61e2527aca7d60b41eb6de80d514ed new file mode 100644 index 000000000..ce23438a0 --- /dev/null +++ b/30/ef65e9fe61e2527aca7d60b41eb6de80d514ed @@ -0,0 +1,127 @@ +Return-Path: +X-Original-To: notmuch@notmuchmail.org +Delivered-To: notmuch@notmuchmail.org +Received: from localhost (localhost [127.0.0.1]) + by arlo.cworth.org (Postfix) with ESMTP id 6A1B76DE176B + for ; Tue, 12 Jan 2016 11:15:56 -0800 (PST) +X-Virus-Scanned: Debian amavisd-new at cworth.org +X-Spam-Flag: NO +X-Spam-Score: 0.009 +X-Spam-Level: +X-Spam-Status: No, score=0.009 tagged_above=-999 required=5 tests=[AWL=0.110, + DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, + RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001] autolearn=disabled +Received: from arlo.cworth.org ([127.0.0.1]) + by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024) + with ESMTP id uiSKYhzw2pKX for ; + Tue, 12 Jan 2016 11:15:54 -0800 (PST) +Received: from resqmta-po-04v.sys.comcast.net (resqmta-po-04v.sys.comcast.net + [96.114.154.163]) + by arlo.cworth.org (Postfix) with ESMTPS id BEF756DE0FB1 + for ; Tue, 12 Jan 2016 11:15:52 -0800 (PST) +Received: from resomta-po-07v.sys.comcast.net ([96.114.154.231]) + by resqmta-po-04v.sys.comcast.net with comcast + id 57FS1s0044zp9eg017Fswh; Tue, 12 Jan 2016 19:15:52 +0000 +Received: from mail.tremily.us ([73.221.72.168]) + by resomta-po-07v.sys.comcast.net with comcast + id 57Dr1s0093dr3C9017DrD3; Tue, 12 Jan 2016 19:13:52 +0000 +Received: by mail.tremily.us (Postfix, from userid 1000) + id 08B4D1B46BB3; Tue, 12 Jan 2016 11:13:50 -0800 (PST) +DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tremily.us; s=odin; + t=1452626031; bh=SrSTLBG2SZCHMCik+x5KOMRRhpwXCjhQ2tSWrDjHswI=; + h=Date:From:To:Cc:Subject:References:In-Reply-To; + b=oQCsmadpS8TkW6jlyOwuzlAXpj0pcGJDNcZQ4EXiv/YS9vm76C0M3fEeY0ga+R8pb + 5RatoBfLS0qwv6hFLyzDUyX+xqvHKGGvyOO1PoGbc9E9cGPAyjq0vbR2gguNmLsg8A + 2SLAyIpO9qhZT28fOM/hZIqc8aHgFnFdHB/8kccI= +Date: Tue, 12 Jan 2016 11:13:50 -0800 +From: "W. Trevor King" +To: David Bremner +Cc: notmuch@notmuchmail.org +Subject: Binding access to ~/.notmuch-config (was: Crash with Python bindings) +Message-ID: <20160112191350.GE372@odin.tremily.us> +References: <5694CA65.8010400@fastmail.net> <87bn8r54dz.fsf@zancas.localnet> + <8737u26cpg.fsf@zancas.localnet> + <8760yy4o3w.fsf@tesseract.cs.unb.ca> +MIME-Version: 1.0 +Content-Type: multipart/signed; micalg=pgp-sha1; + protocol="application/pgp-signature"; boundary="2LWaEC9akcLlisSC" +Content-Disposition: inline +In-Reply-To: <8760yy4o3w.fsf@tesseract.cs.unb.ca> +OpenPGP: id=39A2F3FA2AB17E5D8764F388FC29BDCDF15F5BE8; + url=http://tremily.us/pubkey.txt +User-Agent: Mutt/1.5.23 (2014-03-12) +DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=comcast.net; + s=q20140121; t=1452626152; + bh=nGukQSQsKUId8wf6k531PBD5UaYNmwBJyw2SOIWDlbY=; + h=Received:Received:Received:Date:From:To:Subject:Message-ID: + MIME-Version:Content-Type; + b=ZD8r8ai1L87rvACvRfCigLy4mszpcMN0wcyU5HNuGPmhdcHGUtVVyic54Vm7Fcm2p + +a6n/GNDsUT+VhB8Ndvqi0yotbcbcF/UJStuEBjdD0YboEjQwGAXm3qCjLTIJYNTGm + r08TwmBYAk1t1ej4uMqowXv5Bad7csmvQkBbfA3+nUd/D/hsLUsqSyYJXJBA5QlETZ + 1AQoS8snPCzA9x0zuLYNFz/OvtgVmUZsGNZu/5BSG953UfXULlRdFjdoxHq+SNP60u + THlWspcSSgtiFDkpF22a4IiOrTWWYW6ye29IRScH9y5Yn9Jja4UoQuiOtzQ9/39RsD + cOONviJnaonJA== +X-BeenThere: notmuch@notmuchmail.org +X-Mailman-Version: 2.1.20 +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: Tue, 12 Jan 2016 19:15:56 -0000 + + +--2LWaEC9akcLlisSC +Content-Type: text/plain; charset=utf-8 +Content-Disposition: inline +Content-Transfer-Encoding: quoted-printable + +On Tue, Jan 12, 2016 at 03:03:15PM -0400, David Bremner wrote: +> Nothing to do with Konrad's crash, but I consider the fact that the +> python bindings read ~/.notmuch-config to be a kind of layering +> violation, since that file belongs to the CLI, while the bindings +> are supposed to provide access to libnotmuch. + +I think of ~/.notmuch-config as being shared between all client code, +and in that view it makes sense to have both the CLI and Python +bindings (and other bindings) access it to figure out how to configure +their library access calls. Having a separate config file for each +client to point at the default database path seems like more trouble +than it's worth, as does adding a library function for =E2=80=9Creach into +some local config and return the default database path=E2=80=9D. + +Cheers, +Trevor + +--=20 +This email may be signed or encrypted with GnuPG (http://www.gnupg.org). +For more information, see http://en.wikipedia.org/wiki/Pretty_Good_Privacy + +--2LWaEC9akcLlisSC +Content-Type: application/pgp-signature; name="signature.asc" +Content-Description: OpenPGP digital signature + +-----BEGIN PGP SIGNATURE----- +Version: GnuPG v2 + +iQIcBAEBAgAGBQJWlVBtAAoJEAPqygegUbGsyYoP/0Bak9MknN/I6ZeusBKuwFmF +d92q2aGtEuWyXETfhhtgoweGIj5w5FGJwgMFTEWkoFcft3ORRHI4DiM7nJAsbfQx +g8f0Tqjr2UBN8qijZ1KemPdDY16tG7+4BASAkfSQFRlEUTPcea5+hMAU1q1RLOji +9vnuyBzkvWdjAbx+3FGGEdfc2equ/o5PyA5WDZtvOHCQfWoItRwbYPfeh7Xd206Q +JZosZqX/LwAMcNRXR3I1m2sYrYQ+Mz5f3H30koy32Ar2NEoagMJYMW5FRRn2DrCF +IdS7UTgxjjnEiTgvb86E1ojq8xguGwsPXzkQow1aTlBmI2JB+ZYVlxTv/+W8DnWB +Nbt4hQwRPG4dfvJ6W3h9UJDTWSa7+t07fUG0U/q0cNZ4vqVEc2t8iwXLPI/s9RrE +re1iba1N3Fy/yNc9K4rLWvSLq9dbZA0dO2nfqu8+xj+jQrkpCGIGAYDM9cf/eop1 +4FG9gsfK7AxKqRBRisTPcwVSsF/GK77nv4c6mx3CTflmm4Y47F/O2lJjFx9yn81k +Iey2EYqKpFgC660UDju0+YuYoErU0vgkfSyqBfZF3SIqi10VWPZeaMZ2BV1NEkw+ +OqTnPiCkUuYU8CQDvmn0dFacNGSrAyJm2VbH32iFyIUX5i9f/ZU2/FeLdWHKooi8 +Eb5JWae1eB0VHXJX3Zlb +=awB4 +-----END PGP SIGNATURE----- + +--2LWaEC9akcLlisSC-- -- 2.26.2