refactor: remove legacy history and proxy migrations (#6518)

This commit is contained in:
chengyongru authored and GitHub committed 2026-10-29 18:28:44 +08:00
1 parent 1c28b20c7e
commit cb3ba45317
47 files changed
+207 -1925

No files matched your search

+1 -2
View File
@@ -138,7 +138,6 @@ class _EmptyGatewaySessionManager:
def state(self):
return SimpleNamespace(
list_sessions=AsyncMock(return_value=[]),
migrate_history=AsyncMock(),
record_delivery=AsyncMock(),
aclose=AsyncMock(),
)
@@ -941,7 +940,7 @@ def test_provider_login_openai_codex_uses_explicit_config_proxy(tmp_path, monkey
proxy = "http://127.0.0.1:23458"
config_path = tmp_path / "config.json"
config_path.write_text(
json.dumps({"providers": {"openaiCodex": {"proxy": proxy}}}),
json.dumps({"network": {"proxy": proxy}, "providers": {"openaiCodex": {"useProxy": True}}}),
encoding="utf-8",
)
active_path: dict[str, Path] = {}
+1 -2
View File
@@ -9,7 +9,7 @@ from typer.testing import CliRunner
from nanobot.cli.commands import app
from nanobot.config import home as instance_home
from nanobot.config import loader
from nanobot.config.paths import get_cli_history_path, get_legacy_sessions_dir, get_media_dir
from nanobot.config.paths import get_cli_history_path, get_media_dir
from nanobot.config.schema import Config
@@ -54,7 +54,6 @@ def test_home_paths_and_saved_workspace(tmp_path):
assert Config().workspace_path == tmp_path / "workspace"
assert get_media_dir() == tmp_path / "media"
assert get_cli_history_path() == tmp_path / "history" / "cli_history"
assert get_legacy_sessions_dir() == tmp_path / "sessions"
config = Config()
config.agents.defaults.workspace = str(tmp_path / "custom")
loader.save_config(config)