From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from out-25.smtp.github.com (out-25.smtp.github.com [192.30.252.208]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by bl2.djc.id.au (Postfix) with ESMTPS id D66BA1B565B for ; Sun, 05 Apr 2026 20:48:32 +1000 (AEST) Received: from github.com (hubbernetes-node-91b1bea.ash1-iad.github.net [10.56.172.37]) by smtp.github.com (Postfix) with ESMTPA id 1133214042E; Sun, 5 Apr 2026 03:48:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=github.com; s=pf2023; t=1775386111; bh=xkjh1JBT+TrULCqeIx7dY0Ov8MQtjkOH/21QyKwZftk=; h=Date:From:To:Subject:List-Unsubscribe:From; b=XvTdKEU7NK29ZuZ1T0knQvIdxlbLIFZm8loZblsERIfWtWMtXyCBjttT7dIha62Wz dxr0fEBhHVUdcdseEu30CW3G9WYhEntVOCuVJ9LIB3cAo7+t3/eW0A8HFQkQZHVwuj 7wWGlTzn5A3wDQvIrVlzjFjneRryfpOPn4OFJjaw= Date: Sun, 05 Apr 2026 03:48:31 -0700 From: Dan Callaghan To: djc@djc.id.au, sup-commits@supmua.dev Message-ID: Subject: [sup-heliotrope/sup] d0b8f0: tests: add coverage for lazy loading behaviour in ... Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit List-Unsubscribe: X-GitHub-Recipient-Address: djc@djc.id.au,sup-commits@supmua.dev X-Auto-Response-Suppress: All X-Rspamd-Queue-Id: D66BA1B565B List-Id: Branch: refs/heads/develop Home: https://github.com/sup-heliotrope/sup Commit: d0b8f05c221e4005a61602481395fba1d424525e https://github.com/sup-heliotrope/sup/commit/d0b8f05c221e4005a61602481395fba1d424525e Author: Dan Callaghan Date: 2026-04-05 (Sun, 05 Apr 2026) Changed paths: M Manifest.txt A test/dummy_buffer.rb A test/unit/test_line_cursor_mode.rb Log Message: ----------- tests: add coverage for lazy loading behaviour in LineCursorMode Commit: 55c9afceac1eda9f2a66023983ec05a55cd073a4 https://github.com/sup-heliotrope/sup/commit/55c9afceac1eda9f2a66023983ec05a55cd073a4 Author: Dan Callaghan Date: 2026-04-05 (Sun, 05 Apr 2026) Changed paths: M lib/sup/modes/line_cursor_mode.rb M test/unit/test_line_cursor_mode.rb Log Message: ----------- configurable hysteresis delay for loading more threads Mainly this is for the tests, to avoid needing to sprinkle a bunch of sleep 0.5 throughout them. Commit: a3d6ea4087e8493d71b2e5154a04b1fc5a85827d https://github.com/sup-heliotrope/sup/commit/a3d6ea4087e8493d71b2e5154a04b1fc5a85827d Author: Dan Callaghan Date: 2026-04-05 (Sun, 05 Apr 2026) Changed paths: M bin/sup M lib/sup/buffer.rb M lib/sup/mode.rb M lib/sup/modes/contact_list_mode.rb M lib/sup/modes/label_search_results_mode.rb M lib/sup/modes/line_cursor_mode.rb M lib/sup/modes/search_results_mode.rb M lib/sup/modes/thread_view_mode.rb M test/unit/test_line_cursor_mode.rb Log Message: ----------- refactor LineCursorMode to handle initial load Rather than having every calling site explicitly load the initial set of threads whenever one of the subclasses of LineCursorMode is spawned, make LineCursorMode itself handle the initial load. This way, the logic for deciding how many threads to load at what time is consolidated into LineCursorMode. Commit: 4dc5f0c1fa330375b2287c1d64667a539f27b625 https://github.com/sup-heliotrope/sup/commit/4dc5f0c1fa330375b2287c1d64667a539f27b625 Author: Dan Callaghan Date: 2026-04-05 (Sun, 05 Apr 2026) Changed paths: M lib/sup/modes/line_cursor_mode.rb M test/unit/test_line_cursor_mode.rb Log Message: ----------- simplify and fix thread loading behaviour for page-down The expected behaviour for page-down is that it scrolls the complete buffer content height, with no overlapping lines. But this would not behave correctly if you pressed page-down after spawning a thread listing, because it was initially populated with exactly the buffer content height. It meant there would never be a next page to scroll to. Change the initial load size to be the buffer content height plus 1, so that if there is more than one page of threads, pressing page-down can always scroll to the next page. Delete the different special cases trying to guess whether there are more pages of threads to load. There are many edge cases where this logic would fall over (different combinations of scroll-down and page-down) and the logic is not necessary. ThreadIndexMode already has logic to return early from its load_more callback when all threads have been loaded. Always invoke load_more callbacks when the bottom is visible. Commit: dc62829249629046dee28d2df521894346be1130 https://github.com/sup-heliotrope/sup/commit/dc62829249629046dee28d2df521894346be1130 Author: Dan Callaghan Date: 2026-04-05 (Sun, 05 Apr 2026) Changed paths: M lib/sup/modes/line_cursor_mode.rb M test/unit/test_line_cursor_mode.rb Log Message: ----------- load more threads when jumping to the end Commit: 8044d63cdefd47b1b900c0be54038ea1e06f9665 https://github.com/sup-heliotrope/sup/commit/8044d63cdefd47b1b900c0be54038ea1e06f9665 Author: Dan Callaghan Date: 2026-04-05 (Sun, 05 Apr 2026) Changed paths: M lib/sup/modes/line_cursor_mode.rb M test/unit/test_line_cursor_mode.rb Log Message: ----------- fix cursor position handling for half-page-{up,down} Commit: e95a132c6adc9dcf2220c2e09920b0830ba789b7 https://github.com/sup-heliotrope/sup/commit/e95a132c6adc9dcf2220c2e09920b0830ba789b7 Author: Dan Callaghan Date: 2026-04-05 (Sun, 05 Apr 2026) Changed paths: M lib/sup/modes/line_cursor_mode.rb M test/unit/test_line_cursor_mode.rb Log Message: ----------- load more threads on half-page-down Similar to the page-down behaviour, if it is nearing the bottom it should try to load more threads. Commit: b49dcfe7dd25100feb88ed8aefe629fd91423a26 https://github.com/sup-heliotrope/sup/commit/b49dcfe7dd25100feb88ed8aefe629fd91423a26 Author: Dan Callaghan Date: 2026-04-05 (Sun, 05 Apr 2026) Changed paths: M Manifest.txt A test/unit/test_index.rb Log Message: ----------- tests: add coverage for date query parsing Commit: 6bced04a5d2f68bec16d72b0ac6e5720ceb072cf https://github.com/sup-heliotrope/sup/commit/6bced04a5d2f68bec16d72b0ac6e5720ceb072cf Author: Dan Callaghan Date: 2026-04-05 (Sun, 05 Apr 2026) Changed paths: M lib/sup/index.rb Log Message: ----------- use Xapian::NumberRangeProcessor when available It was added in Xapian 1.3. Xapian::NumberValueRangeProcessor is deprecated and removed in Xapian 2.0. Relates to #627. Commit: 41afb3f131171fd680b6249d9f33313dce59a27e https://github.com/sup-heliotrope/sup/commit/41afb3f131171fd680b6249d9f33313dce59a27e Author: Dan Callaghan Date: 2026-04-05 (Sun, 05 Apr 2026) Changed paths: M test/integration/test_draft.rb M test/integration/test_maildir.rb M test/integration/test_mbox.rb Log Message: ----------- tests: try to avoid index writing race on teardown In one run through the tests, TestMbox#teardown failed with ENOTEMPTY from rmdir. It didn't reproduce. My best guess is that Xapian was not finished writing its index updates to disk when the teardown ran. Call Index.save_index in all tests that write an index to disk, to try and avoid the race. This also requires removing the $stderr logging sink in these tests to avoid having the info message from Index.save_index mingled in with the test output. Compare: https://github.com/sup-heliotrope/sup/compare/beff97f84382...41afb3f13117 To unsubscribe from these emails, change your notification settings at https://github.com/sup-heliotrope/sup/settings/notifications