板块缓存

This commit is contained in:
Sakurasan
2026-07-07 17:54:50 +08:00
parent c6cef8bb4c
commit e29e3d32fb
+1 -3
View File
@@ -366,9 +366,7 @@ async def fetch_sector_list(sector_type: str) -> list[dict]:
data = await _fetch_akshare(sector_type)
if data:
_sector_cache[sector_type] = (data, now)
ttl = _sector_ttl_hours()
if ttl > 0:
set_cache(cache_key, json.dumps(data, ensure_ascii=False), ttl_hours=ttl)
# akshare 数据源更新不确定,不写入磁盘缓存
return data