David Bremner [Wed, 29 May 2024 10:15:25 +0000 (07:15 -0300)]
test/emacs: add tests for rendering text/calendar parts
The first test is just a general regression test, while the second
duplicates the problem discussed in the thread starting at [1].
[1]: id:m2leo2u0uo.fsf@gmail.com
David Bremner [Wed, 29 May 2024 10:15:24 +0000 (07:15 -0300)]
test/emacs: add regression test for display of calendar parts.
This will hopefully catch breakage due to either changes in
Emacs (especially Gnus) or changes to the notmuch-show code.
David Bremner [Wed, 29 May 2024 10:15:23 +0000 (07:15 -0300)]
test/corpora: add example with text/calendar attachment
Initially for testing rendering in Emacs.
Mohsin Kaleem [Fri, 19 Apr 2024 18:25:06 +0000 (19:25 +0100)]
emacs: Allow customizing :excluded in notmuch-saved-searches
Provide customize support for the new feature introduced in
cd89065d.
Commit message expanded by: db
David Bremner [Mon, 20 May 2024 11:58:55 +0000 (08:58 -0300)]
test: re-enable duplicate UI tests in T460-emacs-tree
These were disabled (accidentally?) in
f63d14a8c12a.
Mohsin Kaleem [Sun, 10 Mar 2024 18:57:41 +0000 (18:57 +0000)]
emacs: Add new option notmuch-search-hide-excluded
The new notmuch-search-hide-excluded option allows users to configure whether
to show or hide excluded messages (as determined by search.exclude_tags
in the local notmuch config file). It defaults to true for now to maintain
backwards-compatibility with how notmuch-{search,tree} already worked.
New commands notmuch-search-toggle-hide-excluded and
notmuch-tree-toggle-exclude have also been added. They toggle the value
of notmuch-search-hide-excluded for the search in the current search or
tree buffer. It's bound to "i" in the respective keymaps for these
modes.
Lastly I've amended some calls to notmuch-tree and notmuch-unthreaded
which didn't pass through the buffer local value of
notmuch-search-oldest-first (and now notmuch-search-exclude).
Examples of where I've done this include:
+ notmuch-jump-search
+ notmuch-tree-from-search-current-query
+ notmuch-unthreaded-from-search-current-query
+ notmuch-tree-from-search-thread
A new test file for Emacs has been added which covers the usage of the
new `notmuch-search-hide-excluded' option and interactively hiding or
showing mail with excluded tags. These test cover the basic usage of
the `notmuch-search-toggle-hide-excluded' command in notmuch-search,
notmuch-tree and notmuch-unthreaded searches. These tests also cover
the persistence of the current value of the hide-excluded mail option
as a user switches from between these different search commands.
[1]: id:87ilxlxsng.fsf@kisara.moe
Amended-by: db, fix indentation in T461-emacs-search-exclude.sh
David Bremner [Sat, 30 Sep 2023 11:40:50 +0000 (08:40 -0300)]
perf-test/tag: add maildir sync tests
Today someone asked me the (reasonable) question of how much
performance impact there is from synching tags to maildir flags. It
turns out it is noticeable, about a 50% overhead compared to
non-synched tags (according to these tests). In practice I don't know
if it's a big problem for users, since I don't know what fraction of
tagging operations involve "special" tags.
Jelle Licht [Tue, 19 Mar 2024 21:31:00 +0000 (22:31 +0100)]
emacs: Autoload notmuch-user-agent related functions
With this change, users with mail-user-agent set to
'notmuch-user-agent can start composing emails without having to
require 'notmuch-mua first.
Dmitry Bogatov [Tue, 26 Mar 2024 23:47:22 +0000 (19:47 -0400)]
emacs: Mark "notmuch-tree" command for autoloading
Some people (e.g: me) prefer to read their email with threaded
representation by default.
Without this commit, I have to run "notmuch-search" (autoloaded)
first to get "notmuch-tree" loaded.
Tomi Ollila [Tue, 12 Mar 2024 08:25:19 +0000 (10:25 +0200)]
NEWS: aspell(1)d few words
Executed aspell -l en -c NEWS
and replaced few obvious cases.
David Bremner [Mon, 11 Mar 2024 11:17:40 +0000 (08:17 -0300)]
Merge tag 'debian/0.38.3-1'
notmuch release 0.38.3-1 for unstable (sid) [dgit]
[dgit distro=debian no-split --quilt=linear]
David Bremner [Sun, 10 Mar 2024 03:13:32 +0000 (23:13 -0400)]
debian: update changelog date
It is a bit weird to have debian changelog before upstream release date.
David Bremner [Sun, 10 Mar 2024 03:07:21 +0000 (23:07 -0400)]
Merge from sid [dgit]
David Bremner [Sun, 10 Mar 2024 03:01:43 +0000 (23:01 -0400)]
Revert "debian: start changelog for 0.38.3-1"
This reverts commit
522b279e46c84e4d2d52ccdf082d05fc111dc7b5.
Remove duplicate changelog stanza
David Bremner [Sun, 10 Mar 2024 02:51:06 +0000 (22:51 -0400)]
version: bump to 0.38.3
David Bremner [Sun, 10 Mar 2024 02:49:50 +0000 (22:49 -0400)]
debian: start changelog for 0.38.3-1
David Bremner [Sun, 10 Mar 2024 02:47:37 +0000 (22:47 -0400)]
doc: update copyright years to include 2024
David Bremner [Sun, 10 Mar 2024 02:42:08 +0000 (22:42 -0400)]
NEWS: update for 0.38.3
Benjamin Drung [Wed, 28 Feb 2024 23:56:48 +0000 (23:56 +0000)]
Record notmuch (0.38.2-1.1) in archive suite sid
Benjamin Drung [Wed, 28 Feb 2024 23:56:48 +0000 (23:56 +0000)]
notmuch (0.38.2-1.1) unstable; urgency=medium
* Non-maintainer upload.
* Rename libraries for 64-bit time_t transition. Closes: #
1063205
[dgit import unpatched notmuch 0.38.2-1.1]
Benjamin Drung [Wed, 28 Feb 2024 23:56:48 +0000 (23:56 +0000)]
Import notmuch_0.38.2-1.1.debian.tar.xz
[dgit import tarball notmuch 0.38.2-1.1 notmuch_0.38.2-1.1.debian.tar.xz]
David Bremner [Sat, 17 Feb 2024 13:04:32 +0000 (09:04 -0400)]
debian: recommend gpg-agent instead of gnupg agent
Jakub Wilk [Fri, 12 Jan 2024 16:27:50 +0000 (17:27 +0100)]
CLI/git: remove no-op format() call
Jakub Wilk [Fri, 12 Jan 2024 16:27:49 +0000 (17:27 +0100)]
CLI/git: fix name error
Jakub Wilk [Fri, 12 Jan 2024 16:27:48 +0000 (17:27 +0100)]
CLI/git: remove unused import
shutil was used only for the tempfile.TemporaryDirectory backport,
which was removed in commit
b7c31f658121a0cf ("CLI/git: drop support for
python < 3.2").
David Bremner [Wed, 6 Dec 2023 11:39:24 +0000 (07:39 -0400)]
Merge branch 'release'
David Bremner [Sun, 3 Dec 2023 18:56:44 +0000 (14:56 -0400)]
lib: clear error message on success in _choose_database_path
Previously we both found a database and returned a message saying that
the database could not be found (along with a success code). This
change should prevent spurious error output.
David Bremner [Sun, 3 Dec 2023 15:41:11 +0000 (11:41 -0400)]
test: add known broken test for incorrect error message
Duplicate bug reported in id:87wmtvcor5.fsf@alyssa.is
The error message is nonsense, because notmuch config list actually
includes the database in those two cases.
David Bremner [Fri, 1 Dec 2023 12:11:39 +0000 (08:11 -0400)]
Merge branch 'release'
David Bremner [Fri, 1 Dec 2023 11:51:31 +0000 (07:51 -0400)]
debian: changelog for 0.38.2-1
David Bremner [Fri, 1 Dec 2023 11:51:09 +0000 (07:51 -0400)]
Import notmuch_0.38.2.orig.tar.xz
[dgit import orig notmuch_0.38.2.orig.tar.xz]
David Bremner [Fri, 1 Dec 2023 11:50:27 +0000 (07:50 -0400)]
NEWS for 0.38.2
David Bremner [Fri, 1 Dec 2023 11:38:55 +0000 (07:38 -0400)]
version: bump to 0.38.2
Jani Nikula [Thu, 30 Nov 2023 16:13:19 +0000 (18:13 +0200)]
notmuch-emacs-mua: avoid extra separators at the end of the line
Currently the --to/--cc/--bcc options add "user@example.com, " to the
message headers, with the the unnecessary ", " separator after the
last address, regardless of how many addresses are being added.
This used to be fine, but with recent emacs mm, trying to send the
email with the trailing commas leads to prompt:
Email address looks invalid; send anyway? (y or n)
Fix this by only adding the commas between addresses, avoiding the
trailing commas.
David Bremner [Tue, 28 Nov 2023 13:21:11 +0000 (09:21 -0400)]
Merge branch 'release'
David Bremner [Sat, 25 Nov 2023 12:33:52 +0000 (08:33 -0400)]
lib/string_map: simulate stable sorting
qsort(3) does not promise stability, and recent versions of glibc have
been showing more unstable behaviour [2]. Michael Gruber observed [1] test
breakage due to changing output order for message properties.
We provide a sorting order of (key,value) pairs that _looks_ stable by
breaking ties based on value if keys are equal. Internally there may
be some instability in the case of duplicate (key,value) pairs, but it
should not be observable via the iterator API.
[1]: id:CAA19uiSHjVFmwH0pMC7WwDYCOSzu3yqNbuYhu3ZMeNNRh313eA@mail.gmail.com
[2]: id:87msv3i44u.fsf@oldenburg.str.redhat.com
David Bremner [Thu, 26 Oct 2023 23:34:31 +0000 (20:34 -0300)]
Merge tag '0.38.1'
notmuch 0.38.1 release
David Bremner [Thu, 26 Oct 2023 23:02:05 +0000 (20:02 -0300)]
debian: update changelog for 0.38.1-1
David Bremner [Thu, 26 Oct 2023 22:52:27 +0000 (19:52 -0300)]
NEWS: News for 0.38.1
Just note the 3 bug fixes.
David Bremner [Thu, 26 Oct 2023 22:45:04 +0000 (19:45 -0300)]
version: bump to 0.38.1
No changes from 0.38.1~rc1
David Bremner [Thu, 12 Oct 2023 22:58:05 +0000 (19:58 -0300)]
Merge tag '0.38.1_rc1'
notmuch 0.38.1~rc1 release
David Bremner [Thu, 12 Oct 2023 22:54:07 +0000 (19:54 -0300)]
changelog for 0.38.1~rc1-1
David Bremner [Thu, 12 Oct 2023 22:52:42 +0000 (19:52 -0300)]
version: update to 0.38.1~rc1
Paul Wise [Thu, 12 Oct 2023 08:14:44 +0000 (16:14 +0800)]
notmuch-mutt: fix Perl syntax of hash index lookups
Fixes: commit 239fdbbbf0cbd6cd6ebafb87e88cdb3cded75364
David Bremner [Fri, 6 Oct 2023 23:08:17 +0000 (20:08 -0300)]
emacs/mua: change name of ignored parameter
Suppress compiler warning.
David Bremner [Fri, 6 Oct 2023 23:01:09 +0000 (20:01 -0300)]
emacs/address: rewrite docstring for n-a-selection-function
The previous version essentially repeated the source code, and
generated a compiler warning.
David Bremner [Fri, 6 Oct 2023 22:56:17 +0000 (19:56 -0300)]
emacs: wrap docstrings
Suppress byte-compiler warnings about >80 character docstrings.
David Bremner [Sun, 1 Oct 2023 11:43:11 +0000 (08:43 -0300)]
emacs: update quoting in docstrings
The complicated looking escapes are needed to avoid compile time
warnings. (info "(elisp) Text Quoting Style") for details.
David Bremner [Sun, 1 Oct 2023 11:26:17 +0000 (08:26 -0300)]
Merge tag 'debian/0.38.1_pre0-1'
notmuch release 0.38.1~pre0-1 for experimental (rc-buggy) [dgit]
[dgit distro=debian no-split --quilt=linear]
David Bremner [Sun, 1 Oct 2023 11:16:48 +0000 (08:16 -0300)]
debian: finalize changelog for 0.38.1~pre0-1
Bonus typo fix.
David Bremner [Sun, 1 Oct 2023 11:12:36 +0000 (08:12 -0300)]
Merge tag '0.38.1_pre0'
notmuch 0.38.1~pre0 release
David Bremner [Sun, 24 Sep 2023 09:51:52 +0000 (06:51 -0300)]
emacs/show: special case toggling display of images
According to emacs upstream [1], we can't expect overlay invisibility
and images to get along. This commit uses the previously stashed
undisplayer functions to actually remove the images from the buffer.
When the image is toggled, it is essentially redisplayed from scratch,
using the previously stashed redisplay data.
[1]: https://lists.gnu.org/archive/html/emacs-devel/2023-08/msg00593.html
David Bremner [Sun, 24 Sep 2023 09:51:51 +0000 (06:51 -0300)]
emacs: save image redisplay data during non-lazy display
This data will eventually be used to redisplay hidden images. A
certain amount of refactoring is done here to avoid code
duplication.
David Bremner [Sun, 24 Sep 2023 09:51:50 +0000 (06:51 -0300)]
emacs/show: save redisplay redisplay data when showing lazy part.
This data will be used to redisplay an image that is hidden by
deleting it from the buffer. We cannot easily delay until the image
is hidden, as we won't have the original data at that point.
David Bremner [Sun, 24 Sep 2023 09:51:49 +0000 (06:51 -0300)]
emacs: save undisplayer function for MIME parts
For some kinds of MIME parts (at least images), our trickery with
overlays will not work, so save the more drastic function created by
Gnus that actually deletes the part from the buffer. In an ideal world
we would return this function as (part of) a value, but here the call
stack is too complicated for anything that simple, so we stash it in
the part plist and rely on that being preserved (unlike the mm handle,
which is transient).
David Bremner [Sat, 23 Sep 2023 11:43:44 +0000 (08:43 -0300)]
Merge branch 'release'
David Bremner [Fri, 15 Sep 2023 12:50:04 +0000 (09:50 -0300)]
Pass error message from GLib ini parser to CLI
The function _notmuch_config_load_from_file is only called in two
places in open.cc. Update internal API to match the idiom in open.cc.
Adding a newline is needed for consistency with other status strings.
Based in part on a patch [1] from Eric Blake.
[1]: id:
20230906153402.101471-1-eblake@redhat.com
David Bremner [Fri, 15 Sep 2023 12:50:03 +0000 (09:50 -0300)]
test: add known broken subtest for the bad config error message
This is a bit fragile w.r.t. glib changing their error message, but it
already helped me find one formatting bug, so for now I think it's
worth it, instead of just grepping for "UTF-8".
David Bremner [Fri, 15 Sep 2023 12:50:02 +0000 (09:50 -0300)]
CLI: exit with error when load_config returns an error.
For now print a generic error message and exit with error on any
non-success code. Previously the code exited, but with exit code zero,
leading users / scripts to think the command had succeeded.
David Bremner [Fri, 15 Sep 2023 12:50:01 +0000 (09:50 -0300)]
test: add known broken test for bad utf8 in config
We should ideally print an informative error message, but at the very
least we should not exit with success.
David Bremner [Sat, 23 Sep 2023 11:16:20 +0000 (08:16 -0300)]
debian: start changelog for 0.38.1~pre0-1
David Bremner [Sat, 23 Sep 2023 11:14:21 +0000 (08:14 -0300)]
NEWS: add header for 0.38.1
Actual news items to be filled in after they are applied.
David Bremner [Sat, 23 Sep 2023 11:12:06 +0000 (08:12 -0300)]
version: update to 0.38.1~pre0
Start preparations for point release
Eric Blake [Wed, 6 Sep 2023 15:26:08 +0000 (10:26 -0500)]
.gitignore: ignore __pycache__
Python likes to leave behind cache files; noticeable when doing an
in-tree build.
David Bremner [Sat, 16 Sep 2023 14:15:46 +0000 (11:15 -0300)]
devel/nmweb: read mail files in binary mode.
"ju" reported on IRC that browsing
https://nmbug.notmuchmail.org/nmweb/show/
20160719094205.qmf5sjnja6crt5t3%40gotlib
crashed. The underlying issue is that python3 defaults to utf8
decoding files unless they are opened in binary mode. The file in
question (in the nmbug archive; it depends a bit on the routing the
message took) has
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 8bit
and some of it is not valid utf8.
David Bremner [Wed, 13 Sep 2023 23:28:42 +0000 (20:28 -0300)]
Merge branch 'release'
David Bremner [Wed, 13 Sep 2023 22:58:39 +0000 (19:58 -0300)]
debian: upload 0.38-2: disable most autopkgtests
David Bremner [Tue, 12 Sep 2023 11:56:22 +0000 (08:56 -0300)]
Merge branch 'release'
David Bremner [Sun, 10 Sep 2023 23:13:13 +0000 (20:13 -0300)]
bindings/python-cffi: clean up notmuch2.egg-info
This is created (at least) by the Debian build, but there seems no
harm in cleaning it for everyone.
David Bremner [Tue, 12 Sep 2023 11:33:35 +0000 (08:33 -0300)]
debian: note introduction of autopkgtests
Having autopkgtests changes Debian package migration (for better and
worse), so make a note when they were introduced to unstable.
David Bremner [Sun, 10 Sep 2023 23:13:13 +0000 (20:13 -0300)]
NEWS: quote function name
This avoids spurious underline/italics when exporting to markdown.
David Bremner [Sun, 10 Sep 2023 23:13:13 +0000 (20:13 -0300)]
NEWS: set release date for 0.38
David Bremner [Sun, 10 Sep 2023 23:13:13 +0000 (20:13 -0300)]
build: clean up __pycache__ directories
These are generated indirectly by certain uses of python in the build.
David Bremner [Sun, 10 Sep 2023 23:13:13 +0000 (20:13 -0300)]
debian: rely on main notmuch (dist)clean.
The python setuputils clean relys on including _notmuch_config.py,
which is cleaned up. Rather than relying on careful ordering, just do
all the cleaning from the GNU Make based build system.
David Bremner [Sun, 10 Sep 2023 23:13:13 +0000 (20:13 -0300)]
bindings/python-cffi: clean up _notmuch_config.py
_notmuch_config.py is generated by configure, and cannot be cleaned up
by the current python build system, since it is imported as a module
by that same build system.
Use DISTCLEAN rather than CLEAN for consistency with other configure
related things.
David Bremner [Mon, 11 Sep 2023 23:19:25 +0000 (20:19 -0300)]
debian: changelog for 0.38-1
David Bremner [Mon, 11 Sep 2023 22:56:21 +0000 (19:56 -0300)]
version: bump to 0.38
David Bremner [Sat, 9 Sep 2023 13:59:20 +0000 (10:59 -0300)]
NEWS: NEWS for 0.38
David Bremner [Sun, 3 Sep 2023 13:20:40 +0000 (10:20 -0300)]
Merge branch 'release'
David Bremner [Sun, 3 Sep 2023 12:11:53 +0000 (09:11 -0300)]
debian: changelog for 0.38~rc2-1
David Bremner [Sun, 3 Sep 2023 12:09:22 +0000 (09:09 -0300)]
version: bump to 0.31~rc2
Kevin Boulain [Wed, 30 Aug 2023 12:52:55 +0000 (14:52 +0200)]
test: suppress all interceptors in glib
On ppc64el, races are detected by TSan:
WARNING: ThreadSanitizer: data race (pid=4520)
Read of size 8 at 0x7ffff20016c0 by thread T1:
#0 strlen ../../../../src/libsanitizer/sanitizer_common/sanitizer_common_interceptors.inc:386 (libtsan.so.2+0x77c0c)
#1 strlen ../../../../src/libsanitizer/sanitizer_common/sanitizer_common_interceptors.inc:378 (libtsan.so.2+0x77c0c)
#2 g_strdup ../../../glib/gstrfuncs.c:362 (libglib-2.0.so.0+0xa4ac4)
Previous write of size 8 at 0x7ffff20016c0 by thread T2:
#0 malloc ../../../../src/libsanitizer/tsan/tsan_interceptors_posix.cpp:647 (libtsan.so.2+0x471f0)
#1 g_malloc ../../../glib/gmem.c:130 (libglib-2.0.so.0+0x7bb68)
Location is heap block of size 20 at 0x7ffff20016c0 allocated by thread T2:
#0 malloc ../../../../src/libsanitizer/tsan/tsan_interceptors_posix.cpp:647 (libtsan.so.2+0x471f0)
#1 g_malloc ../../../glib/gmem.c:130 (libglib-2.0.so.0+0x7bb68)
This appears to be a false positive in GLib, as explained at
https://gitlab.gnome.org/GNOME/glib/-/issues/1672#note_1831968
In short, a call to fstat fails under TSan and GLib's g_sterror will
intern the error message, which will be reused by other threads.
Since upstream appears to be aware that GLib doesn't play nicely with
TSan, suppress everything coming from the library instead of
maintaining a fine grained list.
Reported at
https://buildd.debian.org/status/fetch.php?pkg=notmuch&arch=ppc64el&ver=0.38%7Erc0-1&stamp=
1692959868&raw=0
Michael J Gruber [Sat, 26 Aug 2023 14:53:12 +0000 (16:53 +0200)]
compat: probe for strcasestr more thoroughly
Depending on compiler (gcc, g++, clang) and standard options (c99, c11),
string.h may or may not include strings.h, leading to possibly missing
or conflicting declarations of strcasestr.
Include both so that both detection and compilation phases use the same
(possibly optimised) implementations.
Suggested-by: Thomas Schneider <qsx@chaotikum.eu>
Suggested-by: Florian Weimer <fweimer@redhat.com>
Suggested-by: Tomi Ollila <tomi.ollila@iki.fi>
David Bremner [Sat, 26 Aug 2023 11:31:49 +0000 (08:31 -0300)]
debian: changelog for 0.38~rc1-1
David Bremner [Sat, 26 Aug 2023 11:29:45 +0000 (08:29 -0300)]
version: bump to 0.38~rc1
David Bremner [Sat, 26 Aug 2023 11:28:33 +0000 (08:28 -0300)]
debian: skip T810-tsan on ppc64el
Hopefully just a temporary measure.
David Bremner [Sat, 26 Aug 2023 11:22:33 +0000 (08:22 -0300)]
debian: use architecture.mk
I plan to add further architecture dependent checks, which makes this
preferable to directly calling dpkg-architecture.
David Bremner [Sat, 26 Aug 2023 10:45:36 +0000 (07:45 -0300)]
test: minimize impact of native compilation.
Native compilation is kindof useless in the test suite because we
throw away the cache after every subtest. The test suite could in
principle share an eln cache within a given test file; for now try to
minimize the amount of native-compilation. There is an intermittent
bug where emacs loses track of its default-directory; I suspect (but
have no proof) that bug is related to native compilation and/or race
conditions. This patch seems to prevent that bug (or at least reduce
its frequency).
David Bremner [Thu, 24 Aug 2023 13:56:33 +0000 (10:56 -0300)]
debian: set suite to experimental
David Bremner [Thu, 24 Aug 2023 11:03:46 +0000 (08:03 -0300)]
doc: update copyright date
David Bremner [Thu, 24 Aug 2023 11:00:29 +0000 (08:00 -0300)]
debian: changelog for 0.38~rc0-1
David Bremner [Thu, 24 Aug 2023 10:58:51 +0000 (07:58 -0300)]
NEWS: start NEWS for 0.38
David Bremner [Thu, 24 Aug 2023 10:58:19 +0000 (07:58 -0300)]
version: set up 0.38~rc0
David Bremner [Sun, 20 Aug 2023 15:23:19 +0000 (12:23 -0300)]
test/setup: ignore blank lines in generated config
The presense of the blank lines between sections depends on the
version of glib. Strip them before comparison.
David Bremner [Sun, 20 Aug 2023 15:10:56 +0000 (12:10 -0300)]
CLI/config: simulate top level comments when creating config
According to discussion on
https://gitlab.gnome.org/GNOME/glib/-/issues/3078
it looks like upstream will stop supporting top of file comments.
It is questionable whether we really need this feature, but for now
update notmuch-config to simulate it.
David Bremner [Sun, 20 Aug 2023 17:32:02 +0000 (14:32 -0300)]
test/emacs: adapt to breaking change in Gnus defaults
As of Emacs 29.1, In-Reply-To is in the default value for
message-hidden-headers. We actually want to see that in the test
suite, so remove it again. To future proof the tests, fix a default
value for message-hidden-headers specifically for the test suite.
David Bremner [Thu, 20 Jul 2023 12:08:01 +0000 (09:08 -0300)]
lib/n_d_remove_message: do not remove unique filename
It is wasteful to remove a filename term when the whole message
document is about to be removed from the database. Profiling with perf
shows this takes a significant portion of the time when cleaning up
removed files in the database.
The logic of n_d_remove_message becomes a bit more convoluted here in
order to make the change minimal.
It is possible that this function can be further optimized, since the
expansion of filename terms into filenames is probably not needed
here.
David Bremner [Thu, 20 Jul 2023 12:08:00 +0000 (09:08 -0300)]
lib/message: check message type before deleting document
It isn't really clear how this worked before. Traversing the terms of
a document after deleting it from the database seems likely to be
undefined behaviour at best
David Bremner [Sun, 9 Apr 2023 14:26:27 +0000 (11:26 -0300)]
debian: add autopkgtests
We generate output to stderr for BROKEN tests, which are not failures,
so tell the test runner not to fail because of output on stderr.
David Bremner [Sun, 9 Apr 2023 14:26:26 +0000 (11:26 -0300)]
test: support testing notmuch as installed
We put some effort into testing the built copy rather than some
installed copy. On the other hand for people like packagers, testing
the installed copy is also of interest.
When NOTMUCH_TEST_INSTALLED is set to a nonempty value, tests do not
require a built notmuch tree or running configure.
Some of the tests marked as broken when running against installed
notmuch are probably fixable.