fix(favicon): raise max icon size to 256 KB for hi-res PNGs

DuckDuckGo serves hi-res PNG favicons that legitimately exceed the old
100 KB cap, causing them to be rejected and negatively cached.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
Julien Herr
2026-05-25 23:22:05 +02:00
parent fd3ff8c40a
commit a353de1342
2 changed files with 13 additions and 2 deletions
+6
View File
@@ -21,6 +21,12 @@ verbatim as the GitHub Release notes — so what you write here is what ships.
### Fixed
- Per-feed favicons no longer fail for senders whose DuckDuckGo icon is a
hi-res PNG: the maximum accepted favicon size is raised from 100 KB to 256 KB,
so legitimate large icons (~107 KB and up) are cached instead of rejected.
A domain that was already negatively cached only re-fetches once that entry's
TTL expires (and something — a new email or a favicon request — retriggers
the fetch); delete its `icon:<domain>` KV key to force an immediate refresh.
- Admin dashboard table view: long feed titles no longer overflow into the Feed
ID column — the title/description cell now shrinks so its text ellipsises.
- RSS and Atom feeds now advertise the WebSub hub inside the feed body
+7 -2
View File
@@ -38,8 +38,13 @@ export const ICON_TTL_SECONDS = 7 * 24 * 60 * 60; // 1 week
*/
export const ICON_NEGATIVE_TTL_SECONDS = 6 * 60 * 60; // 6 hours
/** Maximum accepted favicon size (bytes); larger responses are rejected. */
export const MAX_ICON_BYTES = 100 * 1024; // 100 KB
/**
* Maximum accepted favicon size (bytes); larger responses are rejected.
* DuckDuckGo serves hi-res (often 144×144) PNG favicons that legitimately
* exceed 100 KB, so the cap is generous; KV's value limit (25 MB) is the only
* hard constraint, even after base64 inflation.
*/
export const MAX_ICON_BYTES = 256 * 1024; // 256 KB
/** Timeout for an outbound favicon fetch (milliseconds). */
export const ICON_FETCH_TIMEOUT_MS = 5000;