Repository navigation
refactor(agents): read edition agent names through the one catalog reader - #16448
Conversation
Design Review (Opus 5.5) — ✅ PASSDesign-level review of Design-Verdict: PASS One thing to check: rows that Watch
[DESIGN-REVIEWED] 3111060 Description read[DESCRIPTION-READ] c6c0710cac9b6c17178b9358f76a67a171654a9dab60ceead964cb7db5081df3 That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with |
First Principles Review (Opus 5.5) — ✅ PASSPremise-level review of First-Principles-Verdict: PASS Check one thing: an edition row that What this change shipsInventory (2 items) — 2 justifiedIntent: keep the default-agent healer's view of which edition agents exist the same as the agent listing's view. This is a FIX for duplicated code, framed as a refactor.
[FIRST-PRINCIPLES-REVIEWED] 3111060 Description read[DESCRIPTION-READ] 36ef35da6a89347788a3a9fd9387d035f51a1604bc19f7d0c81c9027fed2bafa That sha256 names the PR description this verdict read. Recompute it with |
Opus 5.5 Review — ✅ no blocking findingsReviewed Verdict parsed from the review's SHA-scoped output markers for commit False positive or not applicable? A repository writer can comment: |
GPT 6.1 Review — ✅ no blocking findingsGPT 6.1 completed its review of This comment is updated in place on each push. Review detailsNo findings. False positive or not applicable? A repository writer can comment: |
…ader The default-agent healer (#16410) read the edition's agent catalog with its own copy of the seam call and name filter that agent_discovery._with_edition_agents already performs. It now takes the names from that function, so a change to the seam's failure handling or row validation reaches the healer and the agent listing together.
d67e74d to
3111060
Compare
Problem / Motivation
Goal: a single function reads the edition's agent catalog.
#16410 added
config.loader._edition_agent_names. It repeatsagent_discovery._with_edition_agentsline for line: the samesafe_context_call(... builtin_agents() ...)and the same name filter. If the seam's failure handling or row validation changes, one copy will drift, and the healer and the agent listing will disagree on which agents exist. The First Principles review on #16410 raised this (advisory).Why it matters
The healer decides whether to rewrite the owner's
default_agent. Its view of which agents exist has to stay the listing's view.Not a goal
What changed (motivation → approach → change)
_edition_agent_namesnow returns{agent.name for agent in _with_edition_agents([])}, through a deferred import (agent_discovery imports this package's paths at load time). The duplicated seam call and filter are removed.Backwards compatibility
Compatible: same result for every input.
Tests
test_config_loader.py(includingtest_a_removed_file_whose_agent_the_edition_supplies_is_not_reset),test_agent_execution_catalog.pyand thetest_agent_discovery*files: 735 passed._edition_agent_namesreturning nothing, the edition test fails, so the routed reader is what that test exercises.Manual verification
N/A: a refactor covered by the tests above.
Related Issues
Part of #16409. Follow-up to #16410.
Pattern harvest
Not generalizable: a single duplicated seam read, removed.
Checklist