Issue Description
Email/query with a text filter cannot find messages containing inflected (conjugated/plural)
word forms. The stored PostgreSQL tsvector index is built with the language detected per message
(Dutch for Dutch text), but the search query is executed with a hardcoded English stemming config for
subject/body/attachment fields. Whenever the English and Dutch stems differ, the query lexeme does not
exist in the index and the message is unfindable; even when it literally contains the searched word.
Expected Behavior
Fietsen and fiets should be similiar. Fietsen stem should result in Fiets.
subj @@ to_tsquery(‘dutch’, ‘fietsen’)
Actual Behavior
Fietsen and Fiets results in searching Fiet.
Reproduction Steps
- Send two messages to a mailbox:
message A with subject/body containing the Dutch word fiets
message B with subject/body containing the Dutch word fietsen - Run a JMAP Email/query with filter: { text: “fiets” }.
→ Finds message A only. - Run a JMAP Email/query with filter: { text: “fietsen” }.
→ Returns 0 results, even though message B literally contains the word fietsen.
Stalwart Version
v0.16.x
Installation Method
Docker
Database Backend
PostgreSQL
Blob Storage
S3-compatible
Search Engine
PostgreSQL
Directory Backend
SQL
I have reviewed the documentation and FAQ and confirm that my issue is NOT addressed there.
on
I have searched this support forum (open and closed topics) and confirm this is not a duplicate.
on
I understand that topics in this category are triaged by a bot first but a human reply will follow up. If I’d prefer a human-only reply, I’ll add the no-ai tag to my topic.
on