mirror of
https://github.com/bytedance/deer-flow.git
synced 2026-04-25 11:18:22 +00:00
- title_middleware: drop the _resolve_title_config() try/except wrapper and the optional title_config=None fallback on every helper. after_model/aafter_model read runtime.context.app_config.title directly; helpers take TitleConfig as a required parameter. Matches the typed Runtime[DeerFlowContext] signature. - memory_middleware: drop resolve_context() call; use runtime.context directly since the type is already declared. - sandbox/tools.py: drop three layers of try/except Exception around resolve_context(runtime).app_config.sandbox. If the config can't be resolved that's a real bug that should surface, not be swallowed with a default. - task_tool.py: same — drop the try/except around resolve_context(). - client.py: drop the set_override() call in __init__ and _reload_config(). It was leaking overrides across test boundaries and the leak-free path (init() alone) is enough for the single-Client case. - conftest: autouse fixture that initializes a minimal AppConfig for every test so AppConfig.current() doesn't try to auto-load config.yaml. - test_title_middleware_core_logic: pass TitleConfig explicitly to helpers instead of patching AppConfig.current globally.