Skip to content
Back to skills

175 Fn 13 Pxj1 821ee332

ASecurity

Add `flowctl status [--json]` command to show epic/task counts plus active Ralph run info.

  • 9 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added May 31, 2026
toolspython

Security analysis

A100/100

Pro scans all 2 files and shows the line behind each finding

Scanned May 31, 2026

npx -y skills add tools-only/X-Skills --skill 175-fn-13-pxj1_821ee332 --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of 175 Fn 13 Pxj1 821ee332?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for 175 Fn 13 Pxj1 821ee332
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/tools-only-175-fn-13-pxj1-821ee332/badge)](https://www.skillsdirectory.com/skills/tools-only-175-fn-13-pxj1-821ee332)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
# fn-13-pxj.1 Add flowctl status command

## Description
Add `flowctl status [--json]` command to show epic/task counts plus active Ralph run info.

### Prerequisites
Task fn-13-pxj.2 must ensure ralph.sh writes `promise=COMPLETE` on ALL exit paths, otherwise status will incorrectly show finished runs as "active".

### Implementation

**In flowctl.py:**

1. Add `find_active_runs()` helper:
   - Scan `scripts/ralph/runs/*/progress.txt`
   - Run is active if: progress.txt exists AND does NOT contain "promise=COMPLETE"
   - Return list of (run_id, run_dir, progress_info)

2. Add `cmd_status()`:
   - Get epic/task counts via existing functions
   - Call `find_active_runs()` for Ralph state
   - Check for PAUSE/STOP sentinel files in active runs
   - Output human-readable or JSON based on `--json`

3. Register parser:
   ```python
   p_status = subparsers.add_parser("status", help="Show .flow state and active runs")
   p_status.add_argument("--json", action="store_true")
   p_status.set_defaults(func=cmd_status)
   ```

### Output Format

**Human-readable:**
```
Epics: 2 open, 1 done
Tasks: 5 todo, 1 in_progress, 3 done, 1 blocked

Active runs:
  run-abc123 (iteration 5, working on fn-1-xyz.2)
```

**JSON:**
```json
{
  "epics": {"open": 2, "done": 1},
  "tasks": {"todo": 5, "in_progress": 1, "done": 3, "blocked": 1},
  "runs": [
    {
      "id": "run-abc123",
      "iteration": 5,
      "current_task": "fn-1-xyz.2",
      "paused": false,
      "stopped": false
    }
  ]
}
```

### Key Files
- `plugins/flow-next/scripts/flowctl.py` - add cmd_status and find_active_runs
## Acceptance
- [ ] `flowctl status` outputs epic/task counts
- [ ] `flowctl status` shows active Ralph runs (or "No active runs")
- [ ] `flowctl status --json` returns valid JSON
- [ ] JSON includes runs array with id, iteration, current_task, paused, stopped
- [ ] Works when no runs/ directory exists
- [ ] Works when runs/ is empty
## Done summary
- Added `find_active_runs()` helper to detect Ralph runs by scanning progress.txt
- Added `cmd_status()` showing epic/task counts + active runs with PAUSE/STOP state
- Registered `flowctl status [--json]` subparser

Why: Enable monitoring of .flow state and Ralph runs externally

Verification: CI tests pass (31/31), manual tests for active/paused/stopped states
## Evidence
- Commits: 4197e7e
- Tests: plugins/flow-next/scripts/ci_test.sh
- PRs:

Files in this skill

  • README.md995 B
  • skill.md2.3 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.