From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id 0KsaBQSUq2G38AAAgWs5BA (envelope-from ) for ; Sat, 04 Dec 2021 17:15:00 +0100 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id 0GSsAASUq2GjMwAAbx9fmQ (envelope-from ) for ; Sat, 04 Dec 2021 16:15:00 +0000 Received: from mail.notmuchmail.org (nmbug.tethera.net [144.217.243.247]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id C778C23127 for ; Sat, 4 Dec 2021 17:14:59 +0100 (CET) Received: from nmbug.tethera.net (localhost [127.0.0.1]) by mail.notmuchmail.org (Postfix) with ESMTP id 3CD5929096; Sat, 4 Dec 2021 11:14:55 -0500 (EST) Received: from fethera.tethera.net (fethera.tethera.net [IPv6:2607:5300:60:c5::1]) by mail.notmuchmail.org (Postfix) with ESMTP id C619E29073 for ; Sat, 4 Dec 2021 11:14:53 -0500 (EST) Received: by fethera.tethera.net (Postfix, from userid 1001) id B50E75FC42; Sat, 4 Dec 2021 11:14:53 -0500 (EST) Received: (nullmailer pid 107028 invoked by uid 1000); Sat, 04 Dec 2021 16:14:52 -0000 From: David Bremner To: Fabio Natali , notmuch@notmuchmail.org Subject: Re: [PATCH] emacs: run notmuch-search-hook lazily In-Reply-To: <20210913010350.2211117-1-david@tethera.net> References: <20210913010350.2211117-1-david@tethera.net> Date: Sat, 04 Dec 2021 12:14:52 -0400 Message-ID: <87pmqcs5xf.fsf@tethera.net> MIME-Version: 1.0 Message-ID-Hash: 35BEF44SRB6FSAG5NKDICTZZ5DTRV7O5 X-Message-ID-Hash: 35BEF44SRB6FSAG5NKDICTZZ5DTRV7O5 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: FR ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1638634499; 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=7lO0TiNIYrCkXca2SZ/z3kavE8FfaOXnaa8h9691vJ8=; b=GIvKNcGVnwXN7lqsoxiAEL32RMp8bgUNs9/IQOMRKHePKRMSWziLwpD3LADkY186D5cOmc 6erU80QqTMHrdjukX8u1WBX7FIPXFRS/m1WyGjqeb/vcGTqunB497kaTw5IYBaO/bBzLC7 1curTtViK604poCpwFV/YuGQVLO0e04epos6JUDHZFk30kak1gVQkwB8vRHdG6uL2M8a/C ciX+2oOTuUZOvDy+x5eQG1G0SOGGd74+l1ytlLetSW1w7x/bDh6roh3fuZYNdnHaOMkWII 4Id/FZ3SGy6rdg20U2bWVbwvh4MJye7+6NijTO5tIZQ/gJXh5QCy+yt5jDxoUw== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1638634499; a=rsa-sha256; cv=none; b=qP4JrVeyrcAtI6gyClnN8jQS3OhqL3TFyMR6oWpBk693WIGCWsp+eyfqYjj8GsOq5dV6Eo dIXcgHW3EHnphpJoGFt3sMZocVg7rxt9FsB9XGDnFTHCHRcBwu7CpNIJGXrRuOwJnkVtjq LzXZfP63g5+DiSxdMg3S3goIaQ+r0Wv7ocV0gj/djA1wYQvRzXEJA8nN9EUQFrnFu4sj/9 o2CQI1UUgT6sZCSWj92PVjrdzRYYiY22vlX34klj50dVGyqu7qffLpF++dVADzeNTBL0rY rh229bWVRdkxP+xkLZcmLTfCtGKyeHUdh4+Dl2I43+UIT4sAKCqNVe3dpoXBbQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 144.217.243.247 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Spam-Score: -1.24 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 144.217.243.247 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Queue-Id: C778C23127 X-Spam-Score: -1.24 X-Migadu-Scanner: scn0.migadu.com X-TUID: 9R2F5DNZpLiJ David Bremner writes: > In message id:YT3ueuZHKW931NW3@localhost, Fabio Natali isolated a > visual glitch caused by running notmuch-search-hook too early. This > change moves the running of that hook to > notmuch-search-process-filter, which ensures there is some output in > the buffer before running the hook. Since n-s-p-f can be called many > times for a given buffer, add a buffer local flag to make sure it is > only run once per buffer. applied to master d