Re: Cannot Start Notmuch (invalid-read-syntax "#")

2021-09-13 Thread Tomi Ollila
On Mon, Sep 13 2021, Charles-André Roy wrote: > Hello David, > > I have removed and purged the notmuch-emacs package. > > elpa-notmuch/stable,now 0.31.4-2 was already installed. > > On the notmuchmail.org Web site, I looked at the pages "Notmuch Emacs > Interface" and "Tips and Tricks". The only

Re: [PATCH] lib: use 'localhost' rather than fqdn for default mail address.

2021-09-09 Thread Tomi Ollila
On Thu, Sep 09 2021, David Bremner wrote: > As discussed in the thread starting at [1], the fully qualified domain > name is a bit tricky to get reproducibly, might reveal information > people prefer to keep private, and somewhat unlikely to provide > reliable mail routing. > > The new approach

Re: Is default email address in notmuch setup / lib useful?

2021-09-07 Thread Tomi Ollila
On Mon, Sep 06 2021, David Bremner wrote: > Tomi Ollila writes: > >> >> Agreed. I tried to look whether we could get rid of user.name and >> user.primary_email config values (and then emacs/other email clients >> would need to resolve that information elsewhere). I

[PATCH] NEWS: typo fix; some trailing periods

2021-09-06 Thread Tomi Ollila
The trailing periods to smaller diff between devel/news2wiki.pl output and what has been pushed to notmuch-wiki. --- NEWS | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/NEWS b/NEWS index 2ce632f0..c6a372e7 100644 --- a/NEWS +++ b/NEWS @@ -4,7 +4,7 @@ Notmuch 0.33

Re: Is default email address in notmuch setup / lib useful?

2021-09-06 Thread Tomi Ollila
On Mon, Sep 06 2021, Alexander Adolf wrote: > David Bremner writes: > >> Currently notmuch tries to make a guess for a default email address >> based on the "fully qualified hostname" of the host it is running >> on. This is roughly equivalent to running "hostname -f". I have observed >> two

Re: [PATCH] CLI: define and use format version 5

2021-08-22 Thread Tomi Ollila
On Sat, Aug 21 2021, David Bremner wrote: > This is a bit of a cheat, since the format does not actually > change. On the other hand it is fairly common to do something like > this to shared libary SONAMEs when the ABI changes in some subtle way. > It does rely on the format-version argument

Re: [PATCH 1/3] emacs/rstdoc: escape '*'

2021-08-22 Thread Tomi Ollila
series LGTM. Tomi On Sat, Aug 21 2021, David Bremner wrote: > This is just a regular character in docstrings (as it is fairly often > used in lisp identifiers and buffer names) but is the start of > emphasis in rst. This change is needed to quell a noisy warning when > including

Re: [PATCH 4/7] test/path-config: use test_expect_equal_file_nonempty

2021-08-21 Thread Tomi Ollila
On Wed, Aug 04 2021, David Bremner wrote: > This is more robust against crashes when the expected output is also > generated by notmuch. In the case where the expected output is > explicit, it seems like overkill. 1,2,3 and 4 in this series look good to me Tomi (on mobile device) > --- >

Re: [PATCH] emacs: honour notmuch-show-text/html-blocked-images in w3m messages

2021-08-19 Thread Tomi Ollila
On Tue, Aug 17 2021, David Edmondson wrote: > On Tuesday, 2021-08-17 at 09:07:53 -07, Jonathan Wilner wrote: > >> Apologies in advance for thread-jacking this patch ! >> >> No matter what I try to do, I can't configure notmuch/emacs to show >> any inline images. That's using any of the renderer

Re: dealing with a lot of emails in single dir

2021-08-17 Thread Tomi Ollila
On Tue, Aug 17 2021, Aurélien Aptel wrote: > Hi, > > How do you deal with a maildir with a billion file in it? I'm on ext4 > which should handle it but I can already feel some programs struggle > with a dir with that many entries (noticeable slow down). That reminded me:

[RFC WIP PATCH] test: use GNU make instead of parallel(1) to run tests in parallel

2021-08-17 Thread Tomi Ollila
quick try -- more to follow if there is interest :D moreutils parallel and gnu parallel are fine tools, but if tests can be run in parallel with gnu make (which is required anyway) those are not needed to be installed -- not in linux nor in any other system where such tools may be harder to

Re: BUG: Backward compatibility breakage by --sort argument

2021-08-17 Thread Tomi Ollila
On Sun, Aug 15 2021, David Bremner wrote: > YUE Daian writes: > >>> >> Maybe check version compatibility when notmuch is invoked from Emacs? >> >> So the user (like me) immediately know that it is time to upgrade my >> system... > > Yes, that would be fine if someone wants to implement it. Who

Re: notmuch-tag failing on trailing space

2021-08-16 Thread Tomi Ollila
On Mon, Aug 16 2021, David Edmondson wrote: > On Monday, 2021-08-16 at 08:17:56 -07, David Bremner wrote: > >> Alan Schmitt writes: >> >>> >>> #+begin_src emacs-lisp >>> (defun trim-tag-changes (args) >>> (list (car args) (mapcar #'s-trim-right (cadr args >>> (advice-add 'notmuch-tag

Re: Why some characters are not displayed correctly when setting mm-text-html-renderer to links

2021-08-09 Thread Tomi Ollila
On Fri, Aug 06 2021, David Bremner wrote: > Wenlong Dai writes: > >> >> After some research, I found that setting mm-text-html-renderer to links >> would reduce the load time from >> to around 2 seconds or less. But one small issue with this is some >> characters are not displayed correctly,

Re: should notmuch handle or generate message responses (RFC 9078) (or, "why can't i  an e-mail message?")

2021-08-09 Thread Tomi Ollila
On Thu, Aug 05 2021, Daniel Kahn Gillmor wrote: > Hi notmuch folks-- > > RFC 9078 is an experimental draft "Reaction: Indicating Summary Reaction > to a Message": > > https://www.rfc-editor.org/rfc/rfc9078.html > > In short form, this lets you "thumbs up" an e-mail message without > sending a

Re: [PATCH] perf-test: fix for verbose

2021-08-09 Thread Tomi Ollila
On Thu, Aug 05 2021, David Bremner wrote: > Felipe Contreras writes: > >> Signed-off-by: Felipe Contreras > > applied to master. > > shout out to Tomi for the review. I guess I was the one who dropped the needs-review... Tomi ___ notmuch mailing

Re: [PATCH] emacs: Refine scope of notmuch-jump-key face

2021-08-09 Thread Tomi Ollila
On Thu, Aug 05 2021, David Bremner wrote: > Protesilaos Stavrou writes: > >> The intent of the 'notmuch-jump-key' face is to allow users/themes to >> differentiate the text of the minibuffer prompt from the keys that are >> associated with jump actions. Commit 5cc106b0 correctly introduced the

Re: [PATCH] test: use --minversion to detect GNU Parallel.

2021-08-03 Thread Tomi Ollila
On Mon, Aug 02 2021, David Bremner wrote: > Based on a suggestion of Ole Tange [1]. > > [1]: id:CA+4vN7x6jp4HCiEybZ=5g+2X6Pa7etBFX3Bbd=uyty37gr6...@mail.gmail.com > --- > test/notmuch-test | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/test/notmuch-test

Re: notmuch-tag failing on trailing space

2021-07-27 Thread Tomi Ollila
On Tue, Jul 27 2021, alan schmitt wrote: > Hello, > > I have an issue when using the vertico completion system to add tags to > messages that boils down to the following: the notmuch-tag function is > called like this: > notmuch-tag("id:CA+b3G33ad9PX5SuOwqaWS8TWBTtZcdguKtcQ3XmPvzSCsU..." ("+cwn

Re: [PATCH 1/1] python/notmuch2: provide binding for database_get_directory()

2021-07-26 Thread Tomi Ollila
On Sun, Jul 25 2021, Ludovic LANGE wrote: // stuff deleted // > Le 25/07/2021 à 22:18, Floris Bruynooghe a écrit : // stuff deleted ... // >> >> Anyway, I'm curious what other people think of this as well. > > Copy/paste (!!) of the previous bindings. As I don't know how people are > using

Re: configure checks for python3-notmuch2 module

2021-07-25 Thread Tomi Ollila
On Mon, Jul 12 2021, Michael J. Gruber wrote: > David Bremner venit, vidit, dixit 2021-07-11 23:29:57: >> >> It turns out we need pyconfig.h to build the (new) python bindings. I >> don't think this is adequately checked for by the configure script, >> since I had a Fedora user report a build

Re: [PATCH 0/5] Use closures and other emacs cleanup

2021-07-23 Thread Tomi Ollila
On Mon, Jul 19 2021, Jonas Bernoulli wrote: > Some assorted emacs cleanup and fixes. The big one is the switch to > using closures instead of backquoted lambdas. The other commits for > the most part just deal with things the compiler complained about. > > Jonas Bernoulli (5): > emacs: use

Re: [PATCH] devel: two scripts for checking proposed changes

2021-07-23 Thread Tomi Ollila
On Tue, Jun 29 2021, David Bremner wrote: > Tomi Ollila writes: > >>> + >>> +set -e >>> +make test >> >> This may fail miserably (or is painfully slow (doing configure and make...) >> > > At least for my use case, running the tests

Re: configure checks for python3-notmuch2 module

2021-07-15 Thread Tomi Ollila
On Sun, Jul 11 2021, David Bremner wrote: > It turns out we need pyconfig.h to build the (new) python bindings. I > don't think this is adequately checked for by the configure script, > since I had a Fedora user report a build failure (during make install, > which I found odd) missing pyconfig.h

Re: Repeat last tagging

2021-07-14 Thread Tomi Ollila
On Wed, Jul 14 2021, in...@sindominio.net wrote: > Hi, > > While using notmuch in emacs (which I love, thank you so much!!) I was > wondering if there's a way to repeat the last tagging operation for a > different message or thread. > > My usecase is that, in tree-mode, sometimes I need to tag

Re: [PATCH v2] cli/show: add --format=pretty

2021-07-04 Thread Tomi Ollila
On Fri, Jul 02 2021, Hannu Hartikainen wrote: > The rationale for this feature is twofold: > > 1. It is useful to be able to view messages in as human-friendly format >as possible. > 2. The same format should still be machine-readable, too. > > The email format is mostly human-readable as is.

Re: [PATCH 2/2] test: known broken test for emacs display of message/rfc822 parts

2021-07-04 Thread Tomi Ollila
On Sat, Jul 03 2021, David Bremner wrote: > There are at least 3 bugs present. > > 1) notmuch-show-insert-part-message/rfc822 assumes that message/rfc822 > parts will have a ":content" property, but that turns out not to be > the case. > > 2) something deep in gnus wants gnus-newsgroup-charset,

Re: [PATCH] devel: two scripts for checking proposed changes

2021-06-28 Thread Tomi Ollila
On Mon, Jun 28 2021, David Bremner wrote: > It took me a bit of effort to get the correct oneliner to reindent > elisp from the command line, so I saved the results as > 'reindent-elisp'. > > 'check-notmuch-commit' is an updated version of a script I have been > using (although not always as

Re: [PATCH] test/libconfig: make indexing more consistent

2021-06-20 Thread Tomi Ollila
On Sat, Jun 19 2021, David Bremner wrote: > The other tests have converted to two digit decimal, the commit does > the same to the remaining test that was printing out indices in hex. LGTM. Tomi > --- > test/T590-libconfig.sh | 24 > 1 file changed, 12 insertions(+),

Re: notmuch-emacs notmuch-tag configuration

2021-06-16 Thread Tomi Ollila
On Tue, Jun 15 2021, David Wen Riccardi-Zhu wrote: > I'm using notmuch 0.32.1, Emacs 27.2, and version 20210605.1839 of > notmuch-emacs. When I try to mark a message as read using a custom > keybinding, I'm getting the following error: > > notmuch-tag: Symbol’s function definition is void: query

Re: show a single message in a huge thread

2021-06-12 Thread Tomi Ollila
On Fri, Jun 11 2021, Jonathan Wilner wrote: > I definitely also have this problem with large threads - big time hangs > using Notmuch in Emacs. My simple tests indicate that it happens in Emacs, > not using Notmuch at the command line, though that can also take quite a > long time to return. > >

Re: [PATCH] emacs: remap send-message and send-message-and-exit

2021-06-07 Thread Tomi Ollila
On Fri, Jun 04 2021, e...@edef.eu wrote: >> > (defvar notmuch-message-mode-map >> >(let ((map (make-sparse-keymap))) >> > -(define-key map (kbd "C-c C-c") #'notmuch-mua-send-and-exit) >> > -(define-key map (kbd "C-c C-s") #'notmuch-mua-send) >> > +(define-key map [remap

Re: [PATCH] emacs: drop setting mail-user-agent, and document how to set it

2021-06-07 Thread Tomi Ollila
On Fri, Jun 04 2021, David Bremner wrote: > After some discussion [1], I decided it is better to make notmuch users > who rely on this behaviour customize mail-user-agent. This is > consistent with the behaviour of other emacs mail packages. LGTM. Tomi > > [1]:

Re: [PATCH] test: aggregate-results updates

2021-06-07 Thread Tomi Ollila
On Sat, Jun 05 2021, David Bremner wrote: > Tomi Ollila writes: >> >> testing all changed branches is somewhat hard; I did by adding >> sleep 20 and file what effective removed created results files; >> another change was to change 'total' to 'toxtal' in test_do

Re: [PATCH] emacs: PATCH [1/2] mail user agent

2021-06-03 Thread Tomi Ollila
On Thu, Jun 03 2021, Tory S. Anderson wrote: > Nice follow-upabout what other browsers do! > > David Bremner writes: > >> Tomi Ollila writes: >> >>> On Mon, May 31 2021, David Bremner wrote: >>> >>>> Tomi Ollila writes: >>>>>

Re: show a single message in a huge thread

2021-06-02 Thread Tomi Ollila
On Wed, Jun 02 2021, David Bremner wrote: > David Bremner writes: > >> Alan Schmitt writes: >> >>> Hello, >>> >>> On 2021-06-01 15:33, David Bremner writes: >>> > Is this a bug of notmuch-emacs? Is there a way to display a single > message independently of its context? >

Re: [PATCH] emacs: PATCH [1/2] mail user agent

2021-06-02 Thread Tomi Ollila
On Mon, May 31 2021, David Bremner wrote: > Tomi Ollila writes: >> >> I am for 'ripping the bandage off' and not configure mail-user-agent >> outside of notmuch use (and just require 'notmuch would not set anything...) >> >> Could we have some 'compose-mail' v

Re: [PATCH] emacs: remap send-message and send-message-and-exit

2021-06-02 Thread Tomi Ollila
On Tue, Jun 01 2021, e...@edef.eu wrote: > All three of C-c C-c, , > and are bound to message-send-and-exit by > message.el, but notmuch-mua.el only had an explicit override for the > keyboard binding. This mostly manifests as confusing Fcc behaviour for > GUI users. > > Patching the bindings

Re: [PATCH] NEWS/emacs: document changes in 0.32 that affect keybindings.

2021-05-28 Thread Tomi Ollila
On Thu, May 27 2021, Daniel Kahn Gillmor wrote: > On Thu 2021-05-27 20:11:13 +0300, Tomi Ollila wrote: >> On Thu, May 27 2021, Daniel Kahn Gillmor wrote: >>> +Keymaps are no longer fset, which means they need to be referred to in >>> +define-key directly (without quo

Re: [PATCH] NEWS/emacs: document changes in 0.32 that affect keybindings.

2021-05-27 Thread Tomi Ollila
On Thu, May 27 2021, Daniel Kahn Gillmor wrote: > See list discussion in thread starting with > id:87h7ip2baq@fifthhorseman.net for more details. > > Signed-off-by: Daniel Kahn Gillmor > --- > NEWS | 7 +++ > 1 file changed, 7 insertions(+) > > diff --git a/NEWS b/NEWS > index

Re: [PATCH] emacs: use new face for notmuch-jump and related

2021-05-25 Thread Tomi Ollila
On Fri, May 21 2021, Protesilaos Stavrou wrote: > The minibuffer-prompt face that was used before made it impossible to > differentiate between two distinct UI elements: (i) the prompt's text > which itself cannot be acted upon, (ii) the actionable keys used to > jump to searches/tags. > > The

Re: [PATCH 1/2] make _alloc_notmuch static

2021-05-24 Thread Tomi Ollila
On Sun, May 23 2021, David Bremner wrote: > It is not used outside this file, so being extern seems like an oversight > --- > lib/open.cc | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/lib/open.cc b/lib/open.cc > index 1ca69665..bf166e15 100644 > --- a/lib/open.cc > +++

Re: [PATCH] configure: $(CC) -o /dev/null when output not run

2021-05-23 Thread Tomi Ollila
On Sat, May 22 2021, David Bremner wrote: > Tomi Ollila writes: > >> When C compilation is used just to see whether compilation >> succeeds, there is no need to write any output file. >> >> Some compilations in configure already did this. >> >> Now a

[PATCH v2] test: source $NOTMUCH_SRCDIR/test/test-lib-emacs.sh

2021-05-23 Thread Tomi Ollila
Sourcing test-lib.sh will cd to TMP_DIRECTORY, so relative path in $0 will not work in previous version . $(dirname "$0")/test-lib-emacs.sh Now individual test scripts -- e.g. ./test/T310-emacs.sh will work. --- s/_BUILDD/_SRCD/ to id:20210522152741.27213-1-tomi.oll...@iki.fi now works with

Re: [PATCH] test: say_color() in one write(2)

2021-05-23 Thread Tomi Ollila
On Sat, May 22 2021, David Bremner wrote: > Tomi Ollila writes: > >> say_color() used to call (builtin) printf (and tput(1) to stdout) >> several times, which caused attempts to write messages with color >> to have partial content (e.g. escape sequences) often intermixed

Re: [PATCH] test: source $NOTMUCH_BUILDDIR/test/test-lib-emacs.sh

2021-05-22 Thread Tomi Ollila
On Sat, May 22 2021, Tomi Ollila wrote: > Sourcing test-lib.sh will cd to TMP_DIRECTORY, so > relative path in $0 will not work in previous version > . $(dirname "$0")/test-lib-emacs.sh > > Now individual test scripts -- e.g. ./test/T310-emacs.sh > will work

[PATCH] test: source $NOTMUCH_BUILDDIR/test/test-lib-emacs.sh

2021-05-22 Thread Tomi Ollila
Sourcing test-lib.sh will cd to TMP_DIRECTORY, so relative path in $0 will not work in previous version . $(dirname "$0")/test-lib-emacs.sh Now individual test scripts -- e.g. ./test/T310-emacs.sh will work. --- test/T160-json.sh | 2 +- test/T170-sexp.sh

[PATCH 1/2] test-lib-emacs: re-define test_emacs() after initialization

2021-05-22 Thread Tomi Ollila
After test_emacs() has started emacs, it re-defines itself as just calling the started emacs. First call to test_emacs() will execute to the end of it; next calls will just execute the 2 lines, first clearing OUTPUT, second and last executing TEST_EMACSCLIENT... This simplifies away one if

[PATCH v5] test: replace notmuch_passwd_sanitize() with _libconfig_sanitize()

2021-05-22 Thread Tomi Ollila
notmuch_passwd_sanitize() in test-lib.sh is too generic, it cannot work in many cases... The more specific version _libconfig_sanitize() replaces it in T590-libconfig.sh and the code that uses it is modified to output the keys (ascending numbers printed in hex) so the sanitizer knows what to

Re: [PATCH] emacs: PATCH [1/2] mail user agent

2021-05-22 Thread Tomi Ollila
On Sat, May 22 2021, David Bremner wrote: > web...@toryanderson.com (Tory S. Anderson) writes: > >> >> +(defcustom notmuch-mail-user-agent 'notmuch-user-agent >> + "The mail user-agent to use when creating mail after using Notmuch. For >> historical purposes, the default is

[PATCH] configure: $(CC) -o /dev/null when output not run

2021-05-21 Thread Tomi Ollila
When C compilation is used just to see whether compilation succeeds, there is no need to write any output file. Some compilations in configure already did this. Now also rm -f lines are used more consistently. While at it reformatted code that prints LIBNOTMUCH_{MAJOR,MINOR,MICRO}_VERSION). ---

Re: [PATCH v3] test: replace notmuch_passwd_sanitize() with _libconfig_sanitize()

2021-05-21 Thread Tomi Ollila
On Fri, May 21 2021, Felipe Contreras wrote: > On Thu, May 20, 2021 at 2:43 AM Tomi Ollila wrote: >> >> On Wed, May 19 2021, Felipe Contreras wrote: >> >> > On Wed, May 19, 2021 at 12:34 PM Tomi Ollila wrote: >> > >> >> Haha, as we do _libco

Re: Test failures with notmuch 0.32 and 0.32.1 on openSUSE

2021-05-20 Thread Tomi Ollila
On Thu, May 20 2021, Michael J. Gruber wrote: > David Bremner venit, vidit, dixit 2021-05-20 11:59:50: >> Dan Čermák writes: >> >> > >> > Right, I mistakenly thought this would grab the test database. Is that >> > one no longer necessary? >> > >> >> Ah, that's a different make target, which is

[PATCH v4] test: replace notmuch_passwd_sanitize() with _libconfig_sanitize()

2021-05-20 Thread Tomi Ollila
notmuch_passwd_sanitize() in test-lib.sh is too generic, it cannot work in many cases... The more specific version _libconfig_sanitize() replaces it in T590-libconfig.sh and the code that uses it is modified to output the keys (ascending numbers printed in hex) so the sanitizer knows what to

Re: [PATCH v3] test: replace notmuch_passwd_sanitize() with _libconfig_sanitize()

2021-05-20 Thread Tomi Ollila
On Wed, May 19 2021, Felipe Contreras wrote: > On Wed, May 19, 2021 at 12:34 PM Tomi Ollila wrote: > >> Haha, as we do _libconfig_sanitize < OUTPUT > OUTPUT.clean >> reading python script from stdin don't work (perl has __DATA__ ;). >> (bitten again, I d

Re: [PATCH v3] test: replace notmuch_passwd_sanitize() with _libconfig_sanitize()

2021-05-19 Thread Tomi Ollila
On Wed, May 19 2021, Tomi Ollila wrote: > On Wed, May 19 2021, Felipe Contreras wrote: > >> >> Why not use a heredoc? >> >> python <<-EOF >> .. >> EOF > > tldr: I'll post change to use heredoc. ... which did not work ... > Proba

Re: Emacs: prevent notmuch from tampering with message headers & settings

2021-05-19 Thread Tomi Ollila
On Wed, May 19 2021, Tory S. Anderson wrote: > I've made a branch with a change that should avoid ruining existing > behavior for anyone not trying to preserve their mail-user-agent. How can > I submit this thing? IIRC David already posted something on this mailing list. but anyway; FYI, and

Re: [PATCH v3] test: replace notmuch_passwd_sanitize() with _libconfig_sanitize()

2021-05-19 Thread Tomi Ollila
On Wed, May 19 2021, Felipe Contreras wrote: > On Tue, May 18, 2021 at 12:55 AM Tomi Ollila wrote: >> >> notmuch_passwd_sanitize() in test-lib.sh is too generic, it cannot >> work in many cases... >> >> The more specific version _libconfig_sanitize() re

[PATCH v3] test: replace notmuch_passwd_sanitize() with _libconfig_sanitize()

2021-05-17 Thread Tomi Ollila
notmuch_passwd_sanitize() in test-lib.sh is too generic, it cannot work in many cases... The more specific version _libconfig_sanitize() replaces it in T590-libconfig.sh and the code that uses it is modified to output the keys (ascending numbers printed in hex) so the sanitizer knows what to

Re: [PATCH v2] test: replace notmuch_passwd_sanitize() with _libconfig_sanitize()

2021-05-17 Thread Tomi Ollila
On Mon, May 17 2021, Felipe Contreras wrote: > On Mon, May 17, 2021 at 2:33 PM Tomi Ollila wrote: >> >> notmuch_passwd_sanitize() in test-lib.sh is too generic, it cannot >> work in many cases... >> >> The more specific version _libconfig_sanitize() re

[PATCH v2] test: replace notmuch_passwd_sanitize() with _libconfig_sanitize()

2021-05-17 Thread Tomi Ollila
notmuch_passwd_sanitize() in test-lib.sh is too generic, it cannot work in many cases... The more specific version _libconfig_sanitize() replaces it in T590-libconfig.sh and the code that uses it is modified to output the keys (ascending numbers printed in hex) so the sanitizer knows what to

[PATCH] test: aggregate-results updates

2021-05-17 Thread Tomi Ollila
notmuch-test will now call aggregate-results.sh with file list that it compiles based on the test ran, and aggregate-results will report failure is any of the test files are missing. With this notmuch-test no longer has to exit in non-parallel run if some test fail to write its report file -- so

Re: [PATCH] test: add known broken test for duplicate thread-id terms

2021-05-17 Thread Tomi Ollila
On Sat, May 15 2021, David Bremner wrote: > According to my bijection, this bug has been present since commit > 411675a6ce in 2017. It is apparently harmless for regular use, but > does make notmuch crash when compiled with -DDEBUG_DATABASE_SANITY. > --- > test/T670-duplicate-mid.sh | 17

Re: ruby: building with CFLAGS="something"

2021-05-16 Thread Tomi Ollila
On Sun, May 16 2021, Felipe Contreras wrote: > On Sun, May 16, 2021 at 7:28 AM David Bremner wrote: >> >> >> The rest of the (C and C++) codebase supports >> >> make CFLAGS="-g -O0" >> >> or >> >> CFLAGS="-g -O0" ./configure >> >> but the ruby bindings don't build: > > That's because

Re: [PATCH 1/4] bindings/ruby: unexport CFLAGS when building

2021-05-16 Thread Tomi Ollila
On Sun, May 16 2021, David Bremner wrote: > This prevents breaking the ruby build when passing CFLAGS to other > parts of the build. > --- > bindings/Makefile.local | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/bindings/Makefile.local b/bindings/Makefile.local > index

Re: [PATCH 6/7] CLI: make static message strings const

2021-05-14 Thread Tomi Ollila
On Fri, May 14 2021, David Bremner wrote: > Tomi Ollila writes: > >> >> In my projects I've been using the following macro: >> #define WriteCS(fd, str) write((fd), (str), sizeof(str) - 1) >> but I don't know if that behaved any better (if we cared)... >

Re: [PATCH] emacs: do not unconditionally set mail-user-agent

2021-05-14 Thread Tomi Ollila
On Thu, May 13 2021, David Bremner wrote: > A user that loads notmuch.el does not necessarily want to user > notmuch-message-mode to send mail. If this does not break anything, could be point release content, provided it did not ship yet (then to the next sailing ship...). > --- >

Re: [PATCH v2 00/10] ruby: object cleanups

2021-05-11 Thread Tomi Ollila
On Tue, May 11 2021, Felipe Contreras wrote: > On Tue, May 4, 2021 at 3:25 AM Felipe Contreras > wrote: >> >> On Tue, May 4, 2021 at 3:17 AM Felipe Contreras >> wrote: >> > >> > This superseeds my previous series [1] with much more cleanups. >> > >> > An important new change is the move towards

Re: [PATCH 5/9] test: test relative paths for database.hook_dir

2021-05-07 Thread Tomi Ollila
On Fri, May 07 2021, David Bremner wrote: > --- > test/T400-hooks.sh | 7 ++- > 1 file changed, 6 insertions(+), 1 deletion(-) > > diff --git a/test/T400-hooks.sh b/test/T400-hooks.sh > index 3a2df2f4..00c99337 100755 > --- a/test/T400-hooks.sh > +++ b/test/T400-hooks.sh > @@ -43,7 +43,7 @@

[PATCH] test: say_color() in one write(2)

2021-05-06 Thread Tomi Ollila
say_color() used to call (builtin) printf (and tput(1) to stdout) several times, which caused attempts to write messages with color to have partial content (e.g. escape sequences) often intermixed with other tests when parallel tests were run. Now, with all output collected, then written out

Re: [PATCH 1/9] test: move test_ruby() inside the only client

2021-05-02 Thread Tomi Ollila
On Sun, May 02 2021, David Bremner wrote: > Felipe Contreras writes: > >> Not much point in polluting the main library, and also will be useful to >> modify it in tandem with the tests. >> > > I can live with this change. I'd say strong LGTM :D Tomi > > d >

[PATCH] test: replace notmuch_passwd_sanitize() with _libconfig_sanitize()

2021-05-02 Thread Tomi Ollila
notmuch_passwd_sanitize() in test-lib.sh is too generic, it cannot work in many cases... The more specific version _libconfig_sanitize() replaces it in T590-libconfig.sh and the code that uses it is modified to output the keys (ascending numbers printed in hex) so the sanitizer knows what to

Re: [PATCH 00/13] test: several fixes and improvements

2021-05-01 Thread Tomi Ollila
On Sat, May 01 2021, David Bremner wrote: > Felipe Contreras writes: > >> The current tests fail on my machine due to my configuration, mainly because >> I didn't have dtach >> installed, but also other stuff. >> >> The following patches fix all the issues I found, and also do plenty of >>

Re: [PATCH 04/13] test: use correct fqdn in passwd_sanitize()

2021-05-01 Thread Tomi Ollila
On Sat, May 01 2021, Felipe Contreras wrote: > My fqdn is 'natae.localdomain', however, socket.getfqdn() returns > 'localhost'. > > To fetch the true fqdn we need socket.getaddrinfo(). > > For more information see: https://stackoverflow.com/a/11580042/10474 > > Signed-off-by: Felipe Contreras >

Re: [PATCH 03/13] test: remove USER_FULL_NAME when not present

2021-05-01 Thread Tomi Ollila
On Sat, May 01 2021, Felipe Contreras wrote: > If a full name is not configured, the output is empty. > This is possibly not portable, but it's a start. > > Signed-off-by: Felipe Contreras > --- > test/T590-libconfig.sh | 10 ++ > 1 file changed, 10 insertions(+) > > diff --git

Re: [PATCH 02/13] test: unset NAME environment variable

2021-05-01 Thread Tomi Ollila
On Sat, May 01 2021, Felipe Contreras wrote: > Otherwise the output from the tests would be different. > > Signed-off-by: Felipe Contreras > --- > test/test-lib.sh | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/test/test-lib.sh b/test/test-lib.sh > index e13797a7..ae653363 100644 >

Re: [PATCH 01/13] test: fix passwd_sanitize()

2021-05-01 Thread Tomi Ollila
On Sat, May 01 2021, Felipe Contreras wrote: > If any of the variables is empty the output is completely messed up, > because replace("", "FOO") puts "FOO" before every single character. > > I don't have my full name configured, and this is what I get: > >

Re: [PATCH] perf-test: add option to run perf

2021-04-25 Thread Tomi Ollila
On Sun, Apr 25 2021, David Bremner wrote: > Although the generation of perf data is not as slow as valgrind, it > seems simplest to re-use the machinery already there to save the logs > in a timestamped subdirectory. > --- > > I'm not sure about the use of --call-graph=lbr here. On the one hand,

Re: [PATCH] ruby: fix ruby 3.1 warnings

2021-04-19 Thread Tomi Ollila
On Mon, Apr 19 2021, David Bremner wrote: > Felipe Contreras writes: > >> Hello. >> >> On Sat, Apr 17, 2021 at 7:20 AM David Bremner wrote: >> >>> Thanks for the patch. I have a couple of questions / comments >>> >>> - It doesn't apply against current master (5248f55d5f1). Can you rebase >>>

Re: [PATCH] compat: expose canonicalize_file_name to C++

2021-04-18 Thread Tomi Ollila
On Sun, Apr 18 2021, Tomi Ollila wrote: > > not perl, but python3 -c 'import socket; print(socket.getfqdn())' notmuch_passwd_sanitize() { python3 -c ' import os, sys, pwd, socket pw = pwd.getpwuid(os.getuid()) user = pw.pw_name name = pw.pw_gecos.partition(",")[0] fqdn

Re: [PATCH] compat: expose canonicalize_file_name to C++

2021-04-18 Thread Tomi Ollila
On Sun, Apr 18 2021, David Bremner wrote: > Đoàn Trần Công Danh writes: > >> >> Anyway, I see some failure in the testsuite due to: >> - *My* hostname(1) (from coreutils) doesn't understand "-f" Interesting (neither of these use coreutils hostname) $ rpm -q -f =hostname

Re: v1 deletion patches

2021-04-18 Thread Tomi Ollila
On Fri, Apr 16 2021, David Bremner wrote: > This version has a better commit message for 2/2 and portability fixes > (thanks to Tomi) for 1/2. Looks safe enough to be pushed in. Tomi > > It obsoletes the WIP version [1] > > [1]: id:20210414021627.1236560-1-da...@tethera.net

Re: [PATCH] compat: expose canonicalize_file_name to C++

2021-04-18 Thread Tomi Ollila
On Sun, Apr 18 2021, Đoàn Trần Công Danh wrote: > On 2021-04-17 11:39:59-0300, David Bremner wrote: >> Đoàn Trần Công Danh writes: >> >> > >> > However, I see that lib/open.cc uses g_key_file_get_value from GLib >> > already, we may switch to g_canonicalize_file_name then? >> > >> >> Yes that

Re: [PATCH 1/2] WIP: add performance test for removing files.

2021-04-15 Thread Tomi Ollila
On Tue, Apr 13 2021, David Bremner wrote: > No doubt this is non-portable use of tar. portable alternative(s) (?) (we probably can trust no file names start with '-') > --- > performance-test/T00-new.sh | 10 ++ > 1 file changed, 10 insertions(+) > > diff --git

Re: Query emails sent to undisclosed-recipients

2021-03-23 Thread Tomi Ollila
On Tue, Mar 23 2021, David Bremner wrote: > Tomi Ollila writes: > >> On Tue, Mar 23 2021, Firmin Martin wrote: >> >>> Hi, >>> >>> I have emails whose the "To" field is undisclosed recipients. In JSON: >>> >>> ```

Re: Query emails sent to undisclosed-recipients

2021-03-23 Thread Tomi Ollila
On Tue, Mar 23 2021, Firmin Martin wrote: > Hi, > > I have emails whose the "To" field is undisclosed recipients. In JSON: > > ``` > "To": "undisclosed-recipients: ;" > ``` > > I would want to tag such email as spam, but I can't query them > using > > ``` > notmuch show --format=json

Re: [PATCH] test: add known broken test for long directory bug

2021-03-18 Thread Tomi Ollila
On Wed, Mar 17 2021, David Bremner wrote: > In [1] Gregor Zattler explained the results of his hard working > tracking down a bug in notmuch with long directories. This test > duplicates the bug. > > [1]: id:20210317194728.GB5561@no.workgroup > --- > test/T050-new.sh | 14 ++ > 1

Re: [PATCH] devel/uncrustify: add line length limits.

2021-03-08 Thread Tomi Ollila
On Sun, Mar 07 2021, David Bremner wrote: > A generous limit of 102 is chosen to moderate the amount of resulting > reformatting. LGTM Tomi > --- > devel/uncrustify.cfg | 6 ++ > 1 file changed, 6 insertions(+) > > diff --git a/devel/uncrustify.cfg b/devel/uncrustify.cfg > index

Re: List archive

2021-03-01 Thread Tomi Ollila
On Sun, Feb 28 2021, David Bremner wrote: > I have restarted the generation of a list archive at > > https://nmbug.notmuchmail.org/archive/notmuch-list.tar.xz > > As you can tell from the name, it's not an mbox anymore, but an archive > of a Maildir. > > I have updated the links I found in the

Re: parallel test failures

2021-02-27 Thread Tomi Ollila
On Fri, Feb 26 2021, David Bremner wrote: > David Bremner writes: > >> >> Thanks to both of you for your feedback / suggestions. I did read today >> that timeout exits with 124 when the time limit is reached. I haven't >> investigated further (nor do I know how the timelimit should be reached,

Re: [PATCH] emacs: notmuch-tree: mark the initial message at point as read

2021-02-25 Thread Tomi Ollila
On Tue, Feb 16 2021, Jonas Bernoulli wrote: > When moving between message in a tree or show buffer, the message at > point is marked as read. Likewise when creating such a buffer, then > the message that is initially at point is supposed to be marked as > read as well. > > The latter worked for

Re: parallel test failures

2021-02-25 Thread Tomi Ollila
On Fri, Feb 19 2021, David Bremner wrote: > I have intermittent failures when running the test suite on sufficiently > parallel machines. I have attached a log of such a failing build, > although it does not seem especially illuminating. > > It takes anywhere from 5 to 300 runs to get a failure

[RFC PATCH] python-cffi out-of-tree build

2021-02-17 Thread Tomi Ollila
setup.py and _build.py to refer some other files based on directory where setup.py is located (os.path.dirname(sys.argv[0]). Dropped bindings/python-cffi/version.txt and refer ../../version.txt instead -- _build.py already refers ../../lib so why have version.txt twice (with identical content).

Re: [PATCH] test: Fix race condition in T568-lib-thread.sh

2021-02-15 Thread Tomi Ollila
On Sun, Feb 14 2021, David Bremner wrote: > The assignment of thread-ids is (apparently) non-deterministic in a > way that mostly seems to show up on multicore machines. In my tests > the number is different from that previously assumed by this test > about 15% of the time on a 50 thread (25

Re: [PATCH 2/2] lib: use a stricter unused macro

2021-02-15 Thread Tomi Ollila
On Sun, Feb 14 2021, David Bremner wrote: > This would have caught bugs like the one corrected in the previous > commit. Series LGTM. Tomi > --- > lib/notmuch-private.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/lib/notmuch-private.h b/lib/notmuch-private.h >

Re: [PATCH] python: convert shebangs to python3

2021-02-13 Thread Tomi Ollila
On Fri, Feb 12 2021, Daniel Kahn Gillmor wrote: > This is the last bit of "python" left in the notmuch codebase. > > https://www.python.org/dev/peps/pep-0394/#recommendation encourages > "third-party distributors" to use more-specific shebang lines. I'm > not certain that the notmuch project

Re: [PATCH] fix FTBFS with glib

2021-02-12 Thread Tomi Ollila
On Thu, Feb 11 2021, Michael J. Gruber wrote: > With newer glib, notmuch FTBFS because of C linkage error. This is due If/when the alternative change is send (if it works), then it would be nice if this FTBFS were opened (i searched it but deliberately leave it still a mystery for some of us ;)

Re: [PATCH] emacs: When completing tags, offer each tag once

2021-02-02 Thread Tomi Ollila
On Tue, Feb 02 2021, David Bremner wrote: > > Maybe delete-dups (subr.el) would be useful here? It is destructive, but > even with a copy (if needed), it should still be faster. I looked the implementation of delete-dups. In case of >100 elements, it uses hash table for checking duplicates. less

Re: [PATCH] emacs: When completing tags, offer each tag once

2021-02-02 Thread Tomi Ollila
On Mon, Feb 01 2021, David Edmondson wrote: > On Monday, 2021-02-01 at 11:49:36 -04, David Bremner wrote: > >> David Edmondson writes: >>> >>> +(defun notmuch-search-uniq-tags (tags) >>> + (let (result) >>> +(mapc (lambda (tag) >>> + (unless (member tag result) >>> + (push

Re: [PATCH] notmuch-show: use correct format specifier for ssize_t

2021-02-02 Thread Tomi Ollila
On Mon, Feb 01 2021, David Bremner wrote: > Đoàn Trần Công Danh writes: > >> Signed-off-by: Đoàn Trần Công Danh >> --- >> >> I found this after inspecting one of my build today. >> I'm not sure what is acceptable action. >> I think using %zd is the right move. >> But I'm not sure if you

  1   2   3   4   5   6   7   8   9   10   >