From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id aBYMG6ysB2KxIAEAgWs5BA (envelope-from ) for ; Sat, 12 Feb 2022 13:48:44 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id eFucF6ysB2InbwEAauVa8A (envelope-from ) for ; Sat, 12 Feb 2022 13:48:44 +0100 Received: from mail.notmuchmail.org (yantan.tethera.net [135.181.149.255]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 04BEA31281 for ; Sat, 12 Feb 2022 13:48:44 +0100 (CET) Received: from yantan.tethera.net (localhost [127.0.0.1]) by mail.notmuchmail.org (Postfix) with ESMTP id 975585F702; Sat, 12 Feb 2022 12:48:41 +0000 (UTC) Received: from fethera.tethera.net (fethera.tethera.net [198.245.60.197]) by mail.notmuchmail.org (Postfix) with ESMTP id F2E605F6C3 for ; Sat, 12 Feb 2022 12:48:37 +0000 (UTC) Received: by fethera.tethera.net (Postfix, from userid 1001) id 49E6F5FBD2; Sat, 12 Feb 2022 07:48:37 -0500 (EST) Received: (nullmailer pid 1760264 invoked by uid 1000); Sat, 12 Feb 2022 12:48:24 -0000 From: David Bremner To: mbw+nm@mailbox.org, notmuch@notmuchmail.org Subject: Re: Questions regarding headers that may occur multiple times In-Reply-To: <20220211081619.wfpduunaoe2fnfub@legion.localdomain> References: <20220211081619.wfpduunaoe2fnfub@legion.localdomain> Date: Sat, 12 Feb 2022 08:48:24 -0400 Message-ID: <87czjsxnc7.fsf@tethera.net> MIME-Version: 1.0 Message-ID-Hash: KJYSS3PX5IEXC5B457NT2R5UJCNGF2IM X-Message-ID-Hash: KJYSS3PX5IEXC5B457NT2R5UJCNGF2IM X-MailFrom: david@tethera.net X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-notmuch.notmuchmail.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.3 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Migadu-Flow: FLOW_IN X-Migadu-Country: DE ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1644670124; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-owner:list-unsubscribe:list-subscribe:list-post; bh=v5ok5ZqabFI4m2CQ7GyIyRp8RvaCQU16r96R+S3SOMg=; b=QNcy98cav4yuMTeSoXPTjqh+6U16hoLkcvfQ3TjNu2F9tqlEVlhGl1fRWWlikrXQXZvEFa Mv9gs8hRuGaDXb8MxeTgthtL4PCR8T16NqESWhcGfsvllxDu+CTn77Amrx+ZEgUIxK4s1P qX7SQBQux1T5TtiP2agckYflNThqeQT6eVtLxF3Rnb/eXJUP4pKQmnFmPdeE3lYPgiqEEF 6fi93QMAGlnyg12tttRIavY9HPVUX7tLFeKsQ5Nn88/lg2qDdyw9pnBoSwYLv6nk0SKxEw uTj1k/2YA1HpiGDcTrYufVCIOD6ZfduOu5Q475GaZpcOhx3a3rfts0dg6D14MA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1644670124; a=rsa-sha256; cv=none; b=kFo4iZXjBQAUVgGIb5tcvEk181QjEEPT43ihcIFdOkvuhOXNXjzp4h5m0eY4wLZu13bbm7 LKcspu4rAnYHqQ85zVzLWFhj4laiLLw6YVjaCvwZFS/VAoMic2E4vXUn3274M+I1SPp67Q 0d+8omGOavOSREUYx4AlpVoMqeUbH0AtlcudKXPWKPt6HnBemzl9JODlWIUYy553TcbUZ7 kvb3mgkDxtxoIKjCk9LxtmQ3EGclCqPZ3mdvpiNuxqRtfxzCmMFkX5kK93Els67iBFYdaB hGQ/Oqa7i50L2xtx1HBoYgsDrgSqp9uxsOf/vvzUR7hBUhxehxVsnuhIt9BdTQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 135.181.149.255 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Spam-Score: -2.84 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 135.181.149.255 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Queue-Id: 04BEA31281 X-Spam-Score: -2.84 X-Migadu-Scanner: scn0.migadu.com X-TUID: fj9lauyHrV7t mbw+nm@mailbox.org writes: TL;DR: yes, the things you think are not supported are not supported. > > it appears that only the first occurrence of these header values are > taken into account? Yes, we use g_mime_object_get_header, which "Gets the value of the first header with the specified name.". > What I would like to do is to somehow access the second (or maybe all) > occurrences of these header values. Is that possible? Not with the current indexing implementation. In principle it would be possible to change the indexer to scan all of the headers for each user defined header to be indexed. I don't know how bad the performance impact would be; it would mean moving from a hash table lookup to a linear scan of the headers, but perhaps that time is small relative to the work of actually updating the database. > It also appears that (with notmuch 0.35), the `extra_headers` only show > up with `--format.json`, by the way. Also for s-expression output (and raw, fwiw), but yes the text format is missing quite a few features. The problem is that it does not use the same "structured output" code as the other formats, it's essentially double the code/bugs to support new features in the text format. For that reason the format has been more or less frozen since the emacs front-end (and vim front end iirc) stopped using it.