ulysses/services
Kenny Van de Maele fafaf089c5
refactor(search): centralize the web-scraping User-Agent into one constant (#4325)
The outbound UA for web_fetch / web_search was inlined in four places with
two different values and nothing keeping them current: content.py pinned a
mid-2021 Chrome 91 build, and providers.py sent a bare Mozilla/5.0 in three
spots. Some sites serve a degraded or blocked page to a UA that old.

Add WEB_FETCH_USER_AGENT to src/constants.py (env-overridable, matching the
existing Copilot/Kimi UA-constant pattern) and import it in content.py and
providers.py. Default to a current, common desktop UA so pages return their
normal HTML: the market-leading desktop OS (Windows; NT 10.0 covers Windows
10 and 11) and browser (Chrome) on a current stable build. The version is now
bumped in one place.

Service-specific self-identifying agents (Copilot, Kimi, webhooks, cookbook)
are intentionally left separate. Adds a regression pinning the constant shape,
the env override, and a guard against a new inline Mozilla literal in the
search sources.

Closes #4324
2026-06-16 01:33:47 +00:00
..
docs refactor(constants): single source of truth for data dir (#3368) 2026-06-08 09:58:52 +02:00
faces Odysseus v1.0 2026-05-31 23:58:26 +09:00
hwfit fix(hwfit): add GB10 unified-memory bandwidth so speed scores are real (#4270) 2026-06-15 18:55:15 +02:00
memory fix(agent): skill-prescribed tools never reach the model's schema list (#4008) 2026-06-15 20:32:43 +09:00
research fix(research): track analyzed URLs separately (#3125) 2026-06-10 12:08:22 +01:00
search refactor(search): centralize the web-scraping User-Agent into one constant (#4325) 2026-06-16 01:33:47 +00:00
shell fix: use running loop for shell stream deadlines (#1694) 2026-06-03 13:37:46 +09:00
stt STT: clean temp audio files on transcription failure 2026-06-02 20:43:24 +09:00
tts refactor(constants): single source of truth for data dir (#3368) 2026-06-08 09:58:52 +02:00
youtube fix(youtube): consolidate duplicate handler 2026-06-15 15:03:41 +09:00
__init__.py Odysseus v1.0 2026-05-31 23:58:26 +09:00