Skip to content

feat(status): rewrite combined uffs --status on uffs-statusfmt (+ -v / --json)#529

Merged
githubrobbi merged 1 commit into
mainfrom
feat/status-system
Jul 5, 2026
Merged

feat(status): rewrite combined uffs --status on uffs-statusfmt (+ -v / --json)#529
githubrobbi merged 1 commit into
mainfrom
feat/status-system

Conversation

@githubrobbi

Copy link
Copy Markdown
Collaborator

What

Phase (C) of the --status refactor. Brings the combined uffs --status view to the same unified uffs-statusfmt styling as --daemon status (#528), with short / long / JSON levels — and folds in "broker completeness" without touching the broker's security-sensitive pipe protocol.

uffs --status

  • short (default): per-section health glyph + key fields for Daemon, Access Broker, MCP HTTP Gateway, MCP Stdio Sessions.
  • -v / --verbose: expands each section —
  • --json: machine-readable superset of all four sections.

Broker completeness — no new wire protocol

Binary path / uptime / stale-check are derived from the service PID via process introspection: a new process_creation_time FFI in uffs-mft::platform::process, alongside the existing process_image_path. So the broker's named-pipe protocol (which vends elevated handles) is untouched. Handle-adoption is already visible via the daemon's reading_via_broker (#527).

Consistency

TTY/NO_COLOR-aware colour via Palette; piped output stays plain. health() is shared with --daemon status so both agree on the daemon glyph + phase wording. -v / --json threaded through dispatch::run_status; --status --help documents them.

Verification

All local gates green before push (host + xwin Windows clippy --all-targets -D warnings, rustdoc -Dwarnings --document-private-items, fmt) — full 14-gate pre-push passed (133s). Smoke-tested the daemon-down render for --status, --status --json, --daemon status -v, and the --daemon stats redirect.

Example (--status --json, daemon down):

{ "daemon": {"running": false}, "broker": {"applicable": false},
  "mcp_http": {"running": false}, "mcp_stdio": [] }

Follow-ups

  • Docs-only "Part of UFFS" README section for uffs-text / uffs-time (separate tiny PR).

…v / --json)

Bring the combined system view to the same unified styling as `--daemon
status`, with short / long / JSON levels and richer operator detail — no
change to the broker's security-sensitive pipe protocol.

- `uffs --status` (short): per-section health glyph + key fields for Daemon,
  Access Broker, MCP HTTP Gateway, MCP Stdio Sessions.
- `uffs --status -v`: expands each section. Daemon adds commit / elevation /
  broker mode, live-update loops, memory, data dir (the #527 fields). Broker
  adds binary path + uptime + a stale-binary check (Windows).
- `uffs --status --json`: machine-readable superset of all four sections.

Broker "completeness" (binary path, uptime, stale check) is derived from the
service PID via process introspection — a new `process_creation_time` FFI in
`uffs-mft::platform::process` alongside the existing `process_image_path`, so
NO new broker wire-protocol surface. Handle-adoption is already visible via
the daemon's `reading_via_broker` (#527).

TTY/NO_COLOR-aware colour via `uffs-statusfmt::Palette`; piped output stays
plain. `health()` is shared with `--daemon status` so both agree on the
daemon glyph + phase wording. `-v` / `--json` threaded through dispatch;
`--status --help` documents them.

Verified: host + xwin (Windows) clippy `--all-targets -D warnings`, rustdoc
`-Dwarnings --document-private-items`, fmt — all green. Smoke-tested the
daemon-down render for `--status`, `--status --json`, `--daemon status -v`.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@githubrobbi githubrobbi enabled auto-merge July 5, 2026 04:20
@githubrobbi githubrobbi added this pull request to the merge queue Jul 5, 2026
Merged via the queue into main with commit 00b7819 Jul 5, 2026
21 checks passed
@githubrobbi githubrobbi deleted the feat/status-system branch July 5, 2026 04:36
deep-soft pushed a commit to deep-soft/UltraFastFileSearch-Rust that referenced this pull request Jul 5, 2026
…tatus` (skyllc-ai#531)

The status rewrite (skyllc-ai#528, skyllc-ai#529) restyled the output and folded `--daemon stats`
into `--daemon status -v`. Update the user manual to match:

- daemon.md: replace the old `Daemon PID:` / `Daemon Performance Stats` example
  blocks with the new short / `-v` long / `--json` examples; note the `stats`
  fold + redirect; add the `status -v` and `status --json` command rows.
- cli-overview.md: add `status -v` / `status --json`; document `--status`
  `-v` / `--json` and mention the Access Broker section.
- troubleshooting.md: point diagnostics at `status -v` and `--status --json`.

Docs-only.

Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
deep-soft pushed a commit to deep-soft/UltraFastFileSearch-Rust that referenced this pull request Jul 5, 2026
…i#532)

The status rewrite (skyllc-ai#528, skyllc-ai#529) restyled the human output, so the CLI
validation harness's text-scraping of `--daemon status` was stale (it looked
for `Daemon PID:`, `Ready`, `Total records:` labels that no longer print in
that shape). Point the CLI target at `--daemon status --json` and parse the
structured payload instead.

- cli-validation.rs RPC.1/2/4: parse the `--json` wrapper
  `{running, status, drives, stats}` — pid + lifecycle state (RPC.1), the
  tier-aware drives array (RPC.2, Parked/Cold may report 0 records), and the
  folded-in performance counters under `stats` (RPC.4). No more string
  scraping, so the checks are stable across cosmetic output changes.
- 11-rpc.toml RPC.1/2/4 + 01-general.toml T169: invoke `status --json` and
  assert JSON keys (`"running"`, `"pid"`, `"drives"`, `"total_records"`, ...).

api-validation.rs already validates the raw JSON-RPC responses, so its
RPC.1-4 validators needed no change. Verified cli-validation.rs compiles
clean (`cargo check` on the rust-script package); it runs live-on-Windows
only, so end-to-end execution is unverified here.

Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant