Files
ruflo/plugins/ruflo-goals/scripts/lib
Mr. Makandruflo a04319a732 fix(ruflo-goals): research-list runs the installed ruflo CLI before npx @latest (#3558)
v3.52.0 added plugins/ruflo-goals/scripts/research-list.mjs (ADR-438). It
spawns `npx -y @claude-flow/cli@latest` once for the namespace listing and
once more for every research record. Installed from the marketplace there
is no CLI beside the plugin, so every /goals or deep-research listing
resolved `latest` through the registry and could read a different CLI and
memory store than the one deep-research wrote with: the same class as
cost-tracker, adr and metaharness in this PR.

scripts/lib/ruflo-cli.mjs is ruflo-adr's resolver (built CLI that ships
the plugin or a repo checkout, then `ruflo`/`claude-flow` on PATH), with
goals' own fallback kept exactly as before: `npx -y @claude-flow/cli@latest`.

Test: test-cli-resolution-3558.mjs (hermetic marketplace-cache copy, fake
ruflo/npx on PATH): installed ruflo serves list + retrieve with no npx; no
ruflo falls back to npx -y @latest; RUFLO_PLUGIN_SKIP_PATH_CLI=1 forces npx.
It fails on the v3.52.0 script and passes here; wired into smoke.sh as
step 12b (16/16). test-research-list.mjs unchanged (5/5).

Co-Authored-By: ruflo <ruv@ruv.net>
2026-10-05 10:00:47 -07:00
..