Commit dbac382
committed
fix(cli): filter non-agent directories from list_agents
list_agents() returns all non-hidden subdirectories, including those
that contain no agent definition (e.g. utils/, data/, tmp/). This
causes the web UI agent selector and /list-apps endpoint to show
non-agent entries that fail to load when selected.
Add _is_agent_dir() static method that checks for root_agent.yaml,
agent.py, or __init__.py — the same files _determine_agent_language()
already relies on — and filter list_agents() output accordingly.
Fixes #46471 parent 8ddddc0 commit dbac382
1 file changed
+10
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
332 | 332 | | |
333 | 333 | | |
334 | 334 | | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
335 | 344 | | |
336 | 345 | | |
337 | 346 | | |
| |||
341 | 350 | | |
342 | 351 | | |
343 | 352 | | |
| 353 | + | |
344 | 354 | | |
345 | 355 | | |
346 | 356 | | |
| |||
0 commit comments