perf(webui): accelerate JSONL session list and thread loading (#5194)

This commit is contained in:
chengyongru
2026-08-03 09:51:35 +08:00
committed by GitHub
parent db6c9effc3
commit 580824a15a
14 changed files with 864 additions and 129 deletions
+1
View File
@@ -13,6 +13,7 @@ from nanobot.webui.transcript import (
def test_delete_webui_thread_removes_legacy_json_and_transcript(tmp_path, monkeypatch) -> None:
monkeypatch.setattr("nanobot.config.paths.get_data_dir", lambda: tmp_path)
monkeypatch.setattr("nanobot.webui.transcript._MAX_TRANSCRIPT_FILE_BYTES", 520)
monkeypatch.setattr("nanobot.webui.transcript._ACTIVE_TRANSCRIPT_ROTATE_BYTES", 520)
monkeypatch.setattr("nanobot.webui.transcript._TARGET_ACTIVE_TRANSCRIPT_BYTES", 260)
key = "websocket:k1"
json_path = webui_thread_file_path(key)