From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: "Jose A. Ortega Ruiz" Newsgroups: gmane.emacs.bugs Subject: bug#44509: 28.0.50; Error querying with new gnus-search and notmuch Date: Sun, 08 Nov 2020 07:09:52 +0000 Message-ID: <87blg8729u.fsf@gnus.jao.io> References: <87imag7kkh.fsf@gnus.jao.io> <87361kd1sg.fsf@ericabrahamsen.net> <87v9eg7ec3.fsf@gnus.jao.io> <874km0bgat.fsf@ericabrahamsen.net> Reply-To: "Jose A. Ortega Ruiz" Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="33645"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 44509@debbugs.gnu.org To: Eric Abrahamsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Nov 08 08:11:12 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kber0-0008dv-HZ for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 08 Nov 2020 08:11:10 +0100 Original-Received: from localhost ([::1]:54980 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kbeqz-00084q-3A for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 08 Nov 2020 02:11:09 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:54898) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kbeqs-00084V-2O for bug-gnu-emacs@gnu.org; Sun, 08 Nov 2020 02:11:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:48092) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kbeqr-0007bZ-Oe for bug-gnu-emacs@gnu.org; Sun, 08 Nov 2020 02:11:01 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kbeqr-0006hS-IU for bug-gnu-emacs@gnu.org; Sun, 08 Nov 2020 02:11:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: "Jose A. Ortega Ruiz" Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 08 Nov 2020 07:11:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44509 X-GNU-PR-Package: emacs Original-Received: via spool by 44509-submit@debbugs.gnu.org id=B44509.160481940825690 (code B ref 44509); Sun, 08 Nov 2020 07:11:01 +0000 Original-Received: (at 44509) by debbugs.gnu.org; 8 Nov 2020 07:10:08 +0000 Original-Received: from localhost ([127.0.0.1]:59638 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kbepz-0006gH-MP for submit@debbugs.gnu.org; Sun, 08 Nov 2020 02:10:08 -0500 Original-Received: from mail-40134.protonmail.ch ([185.70.40.134]:39985) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kbepv-0006fb-NN for 44509@debbugs.gnu.org; Sun, 08 Nov 2020 02:10:06 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jao.io; s=protonmail2; t=1604819395; bh=6dywPTaze5ERtWhMS1VZCBidw1O4Hgx/8dBf3tPeWBo=; h=Date:To:From:Cc:Reply-To:Subject:In-Reply-To:References:From; b=auCvoLLRHCEHzmfzyFoQyT2be/KCPTDB78TINSJQb2L9wDsLakCeejzT2qw7ufO+k VJw+gxsyeyhfQ1W5Jcy4YpO7Cz1UT/icBMkdpdQLEjp/YsF2k2Ol3fcnpacmUw8SVw t9aYoxt14/zJE0GNv3ZDigRDv+wwHkfpOR2xdmopLMxKYG3lMJjMIoHnY+/EXEws/O oLct2RJbqkBTi3D8MEzVRJfCIOXzETXj3suB0NaJPXNSoytOh2Cichakf5px9jvV3r 3Nej81RUR94Wi0lQTwjMyE7J5FfPkOmXX1f8qVAS0rsVtbTuLcIk67oGoUj6Z9qyph 0bKMV7Lyvd0eA== In-Reply-To: <874km0bgat.fsf@ericabrahamsen.net> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:192866 Archived-At: On Sat, Nov 07 2020, Eric Abrahamsen wrote: > It's something that's come up on gnus.general several times over the > years, but I think no one's ever sat down and tried to figure out > exactly how/if it's supposed to work. Thinking about it logically, I > just don't see how it could. On my filesystem (in the maildir maintained > by Dovecot), your message has the filename: > > 1604808232.M340024P65055.slip,S=3D3293,W=3D3369:2,a > > And that's how notmuch will return it. If I search for the same message > via Dovecot's internal search, the UUID is 1116. Is there anything to go > from one to the other? Not to my knowledge. What you say makes sense and i must be misremembering... i have a helper function that knows how to find in gnus a message shown by notmuch, and i use that sometimes to search using notmuch (counsel-notmuch, actually) while keeping gnus as my main interface. > In a few days I can try to set this up and see if there's a way to make > it work. That'd be really great. I'm unfortunately not familiar with nnir/search, or i'd would have dived a bit into it by now, but i'd be happy to try and test whatever you come up with. That said, it's possible to tell notmuch to return message ids instead of filenames. For instance, one of the results of the query notmuch search --format=3Dsexp messages from:Eric to:jao looks like: ((:thread "000000000002e056" :timestamp 1604811194 :date_relative "Today 04:53" :matched 2 :total 5 :authors "Eric Abrahamsen| Jose A. Ortega Ruiz, help-debbugs@gnu.org" :subject "bug#44509: 28.0.50; Error querying with new gnus-search and notmuch" :query ("id:87361kd1sg.fsf@ericabrahamsen.net id:874km0bgat.fsf@ericabrahamsen.net" "id:87imag7kkh.fsf@gnus.jao.io id:handler.44509.B.160479992727359.ack@debbugs.gnu.org id:87v9eg7ec3.fsf@gnus.jao.io") :tags ("inbox" "replied" "unread")) and those values for :query seem to be the ids of this thread. notmuch-search.el has actually a function notmuch-query-get-message-ids that directly returns them, and also this one: (defun notmuch-query-get-threads (search-terms) "Return a list of threads of messages matching SEARCH-TERMS. where possibly that list contains info from both the path and message id. > (BTW have you turned on full text search in your local Dovecot? That > makes imap searches "fast enough" for me, though I doubt they're as > fast as notmuch.) No... i once read that the fastest way was via xapian (if i'm recalling correctly), but then i saw it's a java thing and lost steam :) Another reason is that notmuch knows how to index usenet messages just fine, and i use leafnode to fetch my news to a local server, so i can play the trick of for instance symlinking leafnode's gwene/gmane message folders in my ~/var/mail and have a single index for all my mail and news. The same function that brings me from notmuch message buffers to gnus nnimap groups nows how to bring me to nntp groups to. Cheers, jao -- I don't necessarily agree with everything I say. -Marshall McLuhan (1911-1980)