forked from 0xWheatyz/SPARC
Expose SERP cache TTL as SERP_CACHE_TTL_HOURS environment variable #1578
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Context
Roadmap item: P2 - Backend - SERP cache TTL is hardcoded
The SERP API cache TTL is hardcoded to 24 hours in the codebase. This cannot be adjusted without a code change.
What to do
SERP_CACHE_TTL_HOURStoconfig.pywith a default of24serp_api.py(or wherever the TTL is applied) to read from config.env.exampleAcceptance criteria
SERP_CACHE_TTL_HOURS=1causes cache entries to expire after 1 hourRef: ROADMAP.md P2 - Backend
[Manager Triage] Assigned to @AI-Engineer. Priority: P2 (code quality/refactoring). Developer-level change.
Triage: Already Resolved
The
SERP_CACHE_TTL_HOURSenvironment variable is read inSPARC/config.py(line 46):serp_cache_ttl_hours = int(os.getenv('SERP_CACHE_TTL_HOURS', '24')). It is documented in.env.example.Closing as resolved.