Display update bug in notmuch new

classic Classic list List threaded Threaded
1 message Options
Thomas Schneider Thomas Schneider
Reply | Threaded
Open this post in threaded view

Display update bug in notmuch new


I discovered an issue in notmuch new: when deleting a large amount of
messages (so that it takes long and displays “$time remaining”), it does
not clean the line afterwards:

$ pwd
$ tar xf /tmp/mails.tar
$ notmuch new
Processed 9001 total files in 4s (2113 files/sec.).
Added 9001 new messages to the database.
$ rm new/*
$ notmuch new
No new mail. Removed 9001 messages.lmost no time remaining).

Version information: notmuch 0.27, on GNU/Linux

Steps to reproduce:

cat << EOF > /tmp/test.py
ADDRESS = "[hidden email]"

import mailbox
import email.message
import email.utils
from datetime import datetime

mb = mailbox.Maildir('./test') # will create if not existing

for i in range(1, 9002): # OVER NINE THOUSAND
    m = email.message.EmailMessage()
    m["From"] = ADDRESS
    m["To"] = ADDRESS
    m["Date"] = email.utils.localtime(datetime.now())
    m["Subject"] = "test {}".format(i)
    m["Message-Id"] = email.utils.make_msgid(idstring = "test.{}".format(i))
    m.set_content("test {}".format(i))
python3.6 /tmp/test.py
notmuch new
rm -r test
notmuch new


notmuch mailing list
[hidden email]

signature.asc (847 bytes) Download Attachment