Baseline
Reproduced from v1.3.1 at 5a306f8956cb1eeae69f9709de0e4d61b44e11e7.
Reproduction
- Use an isolated home with no fast-path
google-agents-cli-* skills and point _SKILLS_CHECK_STAMP at a temporary path.
- Stub
run_resolved to return one of these startup-check outcomes: an empty JSON list, a timeout, a nonzero exit, or malformed JSON.
- Freeze the clock and call
check_skills_version() twice.
For each of those outcomes, the fallback is attempted twice and no timestamp is written. A normal successful result with an installed skill does write the stamp.
Actual behavior
_record_skills_check() runs only after _find_installed_skills() returns a non-empty result. Empty, timeout, nonzero, and malformed-JSON paths return first, so every CLI startup immediately retries the relatively slow npx fallback.
Expected behavior
Once a due startup check is attempted, record its timestamp regardless of whether the result is success, empty, timeout, nonzero, or malformed. Calls during the existing cooldown interval should not rerun npx.
Minimal fix
Move the existing _record_skills_check() call immediately after the due/CI guard and before _find_installed_skills(). Keep the timestamp write best-effort; no new retry system or dependency is needed.
Reference implementation: benagentai93-dot@905f1c6
Test evidence
A runnable parameterized regression covers success, empty, timeout, nonzero, and malformed JSON. For every outcome, two calls to check_skills_version() produce one fallback invocation and a timestamp file.
Fork verification:
- focused Batch 3 suite: 15 passed
- full root suite: 55 passed
ruff check src tests: passed
ty check src: passed
uv build: passed
- installed-wheel
agents-cli --version: 1.3.1 on Python 3.11 and 3.13
All focused regressions use mocks; no real npx, network, or server command was run.
Baseline
Reproduced from v1.3.1 at
5a306f8956cb1eeae69f9709de0e4d61b44e11e7.Reproduction
google-agents-cli-*skills and point_SKILLS_CHECK_STAMPat a temporary path.run_resolvedto return one of these startup-check outcomes: an empty JSON list, a timeout, a nonzero exit, or malformed JSON.check_skills_version()twice.For each of those outcomes, the fallback is attempted twice and no timestamp is written. A normal successful result with an installed skill does write the stamp.
Actual behavior
_record_skills_check()runs only after_find_installed_skills()returns a non-empty result. Empty, timeout, nonzero, and malformed-JSON paths return first, so every CLI startup immediately retries the relatively slownpxfallback.Expected behavior
Once a due startup check is attempted, record its timestamp regardless of whether the result is success, empty, timeout, nonzero, or malformed. Calls during the existing cooldown interval should not rerun
npx.Minimal fix
Move the existing
_record_skills_check()call immediately after the due/CI guard and before_find_installed_skills(). Keep the timestamp write best-effort; no new retry system or dependency is needed.Reference implementation: benagentai93-dot@905f1c6
Test evidence
A runnable parameterized regression covers success, empty, timeout, nonzero, and malformed JSON. For every outcome, two calls to
check_skills_version()produce one fallback invocation and a timestamp file.Fork verification:
ruff check src tests: passedty check src: passeduv build: passedagents-cli --version: 1.3.1 on Python 3.11 and 3.13All focused regressions use mocks; no real
npx, network, or server command was run.