deerflow2/tests/unit/graph
Willem Jiang d4ab77de5c
fix: migrate from deprecated create_react_agent to langchain.agents.create_agent (#802)
* fix: migrate from deprecated create_react_agent to langchain.agents.create_agent

Fixes #799

- Replace deprecated langgraph.prebuilt.create_react_agent with
  langchain.agents.create_agent (LangGraph 1.0 migration)
- Add DynamicPromptMiddleware to handle dynamic prompt templates
  (replaces the 'prompt' callable parameter)
- Add PreModelHookMiddleware to handle pre-model hooks
  (replaces the 'pre_model_hook' parameter)
- Update AgentState import from langchain.agents in template.py
- Update tests to use the new API

* fix:update the code with review comments
2026-01-07 09:06:16 +08:00
..
test_agent_locale_restoration.py fix: migrate from deprecated create_react_agent to langchain.agents.create_agent (#802) 2026-01-07 09:06:16 +08:00
test_builder.py fix: remove the unnessary conditional edge. (#671) 2025-10-29 10:12:32 +08:00
test_human_feedback_locale_fix.py feat: Qdrant Vector Search Support (#684) 2025-11-11 19:35:00 +08:00
test_plan_validation.py feat: add analysis step type for non-code reasoning tasks (#677) (#723) 2025-11-29 09:46:55 +08:00
test_state_preservation.py fix: presever the local setting between frontend and backend (#670) 2025-10-28 21:45:29 +08:00