Commit Graph
1140 Commits
Author SHA1 Message Date
Brent Simmons 73f7b374ad Prefer images from HTML to provided thumbnails in large mode, since provided thumbnails are often too small for the large thumbnail space. 2026-11-01 21:43:38 -08:00
Brent Simmons 2fd7f1b3cb Allow more rectangular thumbnails without going so far as to allow banners (which are probably ads). 2026-11-01 21:34:53 -08:00
Brent Simmons 2915cb44e7 Parse HTML thumbnails off the main thread at fetch time. Remove batching. 2026-11-01 21:27:18 -08:00
Brent Simmons 8b93089bfc Update comments with performance notes. 2026-11-01 20:57:02 -08:00
Brent Simmons a204df0d22 Remove articleThumbnailURLs. Cache thumbnail URLs in memory. Parsing is super-fast. 2026-11-01 20:55:18 -08:00
Brent Simmons 24ab32aa80 Parse HTML thumbnails for first 1,000 articles before rows load, so we have thumbnail state for layout. 2026-11-01 20:45:26 -08:00
Brent Simmons 3515b4a445 Prune downloaded images cache only on launch. 2026-11-01 11:55:23 -08:00
Brent Simmons becbe58793 Simplify image retries. 2026-11-01 11:53:36 -08:00
Brent Simmons 4f6ff7d505 Make ThumbnailTaskQueue newest-first. Remove priorities, which are no needed. 2026-11-01 11:34:12 -08:00
Brent Simmons 35ae2068c1 Remove prefetching. 2026-11-01 11:30:10 -08:00
Brent Simmons e0096cd2a4 Remove middleVisibleRow from RSCore, which is no longer used. 2026-10-31 15:46:19 -07:00
Brent Simmons 1e822155b7 Fix comment. 2026-10-31 15:43:28 -07:00
Brent Simmons 43f885e5a0 Return URL strings from HTMLImageParser and delete HTMLImage, which was unused outside tests. 2026-10-31 15:36:24 -07:00
Brent Simmons e7a353b374 Run image removal passes less often. 2026-10-31 15:31:46 -07:00
Brent Simmons 008f600ea1 Log only failed thumbnail downloads, so scrolling doesn’t push sync and refresh entries out of the activity log. 2026-10-31 14:43:50 -07:00
Brent Simmons d481a93bd9 Read and save the scaled copy for favicons, so they aren’t rescaled from the original each time. 2026-10-31 14:41:33 -07:00
Brent Simmons 41094a63bf Remove the scaled icon as soon as its image changes, before posting the change notification, so nothing reads the old copy. 2026-10-31 14:39:35 -07:00
Brent Simmons dc1f3ce86e Skip saving a scaled icon when it’s identical to the original, so small icons and SVGs aren’t stored twice. 2026-10-31 14:37:44 -07:00
Brent Simmons 158bcec9dd Treat a failed image write as a transient failure, so a full disk doesn’t record the image and download it again on each use. 2026-10-31 14:35:29 -07:00
Brent Simmons 4dbb2488e0 Skip deleting images when the image records can’t be read, so a failed database read doesn’t delete every image. 2026-10-31 14:33:49 -07:00
Brent Simmons 73ca3b4b44 Skip deleting images when images folder can’t have its files listed, so a failed listing doesn’t delete every record and file. 2026-10-31 14:32:20 -07:00
Brent Simmons 6acb373d2f Stop recording “no favicon” for five days after a transient failure. 2026-10-31 14:29:58 -07:00
Brent Simmons 0c7e630db7 Check provided thumbnail candidates one at a time, so attachments aren’t iterated when an earlier candidate is usable. 2026-10-31 12:03:30 -07:00
Brent Simmons 210474f6ac Parse, save, post HTML thumbnail URLs in batches of 100. 2026-10-31 11:56:03 -07:00
Brent Simmons b00dce516d Skip images hidden by hidden attribute or style none. Trying to avoid tracking pixels as thumbnails. 2026-10-31 11:53:30 -07:00
Brent Simmons 8955619c40 Stop rejecting photos with "track" or "open" in name since they could be legitimate. 2026-10-31 11:50:41 -07:00
Brent Simmons f70d5e0e38 Preserver waits from a Retry-After after network status changes. 2026-10-31 11:48:41 -07:00
Brent Simmons 0313bd5b5d Limit thumbnail downloads to two per host, so a slow host can’t block everything else. 2026-10-31 11:47:00 -07:00
Brent Simmons 15a43c3350 Fix srcset parser bug. 2026-10-31 11:42:12 -07:00
Brent Simmons fcd5d295bd Choose narrowest srcset candidate at least 1200 px wide instead of the largest candidate, to cut down on bandwidth use. 2026-10-31 11:39:53 -07:00
Brent Simmons 1b6b3b072f Skip icon update checks when network doesn’t allow downloads or retry wait is running. 2026-10-31 11:36:40 -07:00
Brent Simmons a7a1c43e7b Combine htmlThumbnailURLs and articleIDsWithNoHTMLThumbnail into single dictionary. Empty array means HTML has no thumbnail. 2026-10-31 11:10:26 -07:00
Brent Simmons 6f35025569 Remove code that has been replaced by findThumbnailURLs. 2026-10-31 11:08:47 -07:00
Brent Simmons 70b1eb70f0 Add findThumbnailURLs which loads thumbnail URLs and parses the reset. Simplifies things for callers. 2026-10-31 11:01:33 -07:00
Brent Simmons 880b3e213a Decode large thumbnails to displayed height, which makes them smaller, which means more can fit in the image cache. 2026-10-31 10:56:51 -07:00
Brent Simmons c9a3c32586 Skip image URLs that returned something other than an image. 2026-10-31 10:52:22 -07:00
Brent Simmons defd3db2b2 Fall back to home page icon when feed icon URL returns something other than an image. Fixes #5376. 2026-10-31 10:50:20 -07:00
Brent Simmons 3735f095fc Stop retrying image URLs that return something other than an image until network status changes, so a bad URL isn’t retried every session. 2026-10-31 10:47:35 -07:00
Brent Simmons 2aeb9e3d8b Empty chosen thumbnail URLs cache on low memory. 2026-10-31 10:40:19 -07:00
Brent Simmons eb22462a06 Store articles image fields rather than entire articles in ArticleThumbnailFinder. 2026-10-31 10:38:20 -07:00
Brent Simmons c655a0d659 Check retry waits and network status when queued image download’s turn is up, so those requests don’t go to a host that just asked for a wait. 2026-10-31 10:32:29 -07:00
Brent Simmons ec803f9f76 Start hosts’s retry wait for 429, 503, or no response, so that other failures don’t apply to the host. 2026-10-31 10:28:15 -07:00
Brent Simmons 103cfd2a08 Double image retry wait after previous wait ends, so a bunch of failures in a row doesn’t double it to the max in a few seconds. 2026-10-31 10:24:51 -07:00
Brent Simmons aa900631ae Find thumbnails in data-lazy-srcset, data-srcset, and data-original. 2026-10-30 22:30:13 -07:00
Brent Simmons 65962b8cf4 Move row to next thumbnail source when image URL returns something that isn’t an actual image. 2026-10-30 22:28:38 -07:00
Brent Simmons 6d6b3f3123 Test that the largest frame of an image file is decoded. 2026-10-30 22:09:53 -07:00
Brent Simmons 2c56df2373 Test that a failed provided image falls back to a thumbnail found in HTML. 2026-10-30 22:07:58 -07:00
Brent Simmons 521f00be18 Test that an image without validators waits longest between checks. 2026-10-30 22:05:49 -07:00
Brent Simmons 73983d1707 Add test for saving images and checking thumbnail suitability. 2026-10-30 22:04:00 -07:00
Brent Simmons 3a4bac109e Add test for counting HTTP status codes as transient. 2026-10-30 22:01:10 -07:00