Repository navigation
Conversation
The interactive pipeline forwards agent_runner.config.model.fallback_provider_ids into MainAgentBuildConfig, but the cron wakeup path left the field at its default, so a scheduled run had no fallback model to switch to when the primary failed (AstrBotDevs#10026). _woke_main_agent now reads the same config path, with a regression test pinning the forwarded ids. Signed-off-by: Yufeng He <40085740+he-yufeng@users.noreply.github.com>
There was a problem hiding this comment.
Hey - I've reviewed your changes and they look great!
Sourcery assessment
Needs a human reviewer. If the inherited fallback list is wrong, a scheduled run could use an unintended provider and write an incorrect agent response or history. Reverting stops future fallback use, but any response or history already produced would need to be identified and repaired or the job rerun.
kilisamemarisaaa
left a comment
There was a problem hiding this comment.
I reviewed the current head and the added regression test. The cron path reads the same agent_runner.config.model fallback_provider_ids used by the interactive pipeline and passes the list into MainAgentBuildConfig without mutating the session configuration. The test captures the built config through the real _woke_main_agent path and asserts both fallback IDs are preserved; the full CI matrix, CodeQL, format check, and smoke tests are green. I found no correctness or compatibility blocker.
|
#10028 fixed |
Motivation
Fixes #10026. The interactive pipeline forwards
agent_runner.config.model.fallback_provider_idsintoMainAgentBuildConfig, but the cron wakeup path (cron/manager.py::_woke_main_agent) left the field at its default, so a scheduled run had no fallback model to switch to when the primary model failed.Changes
_woke_main_agentnow readsagent_runner.config.model.fallback_provider_idsand passes it intoMainAgentBuildConfig, matching the interactive pipeline.Tests
New regression test
test_woke_main_agent_forwards_fallback_provider_idsdrives the cron wakeup with fallback ids configured and asserts the build config carries them; red on current master, green here. Fulltests/unit/test_cron_manager.py45/45 green; ruff clean.Signed-off-by: Yufeng He 40085740+he-yufeng@users.noreply.github.com
Summary by Sourcery
Propagate configured fallback provider IDs to scheduled agent runs and verify the behavior with a regression test.
Bug Fixes:
Tests: