feat(game-cli): epic E6 — admin CLI on gum (TASK-49…52) #7

Merged
geekiot merged 6 commits from feat/game-cli-e6 into main 2026-08-09 21:23:31 +05:00
Owner

Summary

Epic E6 delivers game-cli, the system's only admin panel (D-18, NFR-031): a thin Python + gum client over the game-core admin API (localhost, D-77). No game logic, no direct DB access (CON-001).

Tasks

  • TASK-49 — CLI skeleton and admin API client: httpx-based AdminApiClient, contract error parsing ({"error": {code, message}}, all five codes), unified Russian error output, exit codes 0/1/2 (D-77).
  • TASK-51 — settings management (FR-051, US-A-03…05): settings list / settings set [key] [value] with type/range hints from SETTINGS_REGISTRY, client-side pre-validation (server stays source of truth, D-49), application notes for interval (D-80) and memory limit (US-A-04).
  • TASK-52 — session control and diagnostics (FR-052, US-A-06/07): sessions start-now (409 on an already active session, D-25) and sessions status showing status, last_seq and journal incident events (D-81, D-82).
  • TASK-50 — interactive player creation (FR-050, US-A-01/02): free or custom name (D-78), catalog or custom temperament with validated metrics (D-70), model from catalog only, explicit head/body/legs avatar pick with no skipping (D-79); 409 name_taken re-fetches the free list and re-asks the name.

Tests and checks

  • 52 new game-cli tests (mocked admin API via httpx.MockTransport, scripted PromptUI fakes — no network, no DB); backend suite: 507 passed, 1 skipped (known skip: owner-supplied temperament content, TASK-53).
  • ruff check, ruff format --check, ty check, nix flake check, treefmt — all green on every commit.

Contract deviations: none. Open TODOs: none.

## Summary Epic E6 delivers game-cli, the system's only admin panel (D-18, NFR-031): a thin Python + gum client over the game-core admin API (localhost, D-77). No game logic, no direct DB access (CON-001). ## Tasks - TASK-49 — CLI skeleton and admin API client: httpx-based AdminApiClient, contract error parsing ({"error": {code, message}}, all five codes), unified Russian error output, exit codes 0/1/2 (D-77). - TASK-51 — settings management (FR-051, US-A-03…05): settings list / settings set [key] [value] with type/range hints from SETTINGS_REGISTRY, client-side pre-validation (server stays source of truth, D-49), application notes for interval (D-80) and memory limit (US-A-04). - TASK-52 — session control and diagnostics (FR-052, US-A-06/07): sessions start-now (409 on an already active session, D-25) and sessions status <id> showing status, last_seq and journal incident events (D-81, D-82). - TASK-50 — interactive player creation (FR-050, US-A-01/02): free or custom name (D-78), catalog or custom temperament with validated metrics (D-70), model from catalog only, explicit head/body/legs avatar pick with no skipping (D-79); 409 name_taken re-fetches the free list and re-asks the name. ## Tests and checks - 52 new game-cli tests (mocked admin API via httpx.MockTransport, scripted PromptUI fakes — no network, no DB); backend suite: 507 passed, 1 skipped (known skip: owner-supplied temperament content, TASK-53). - ruff check, ruff format --check, ty check, nix flake check, treefmt — all green on every commit. Contract deviations: none. Open TODOs: none.
geekiot deleted branch feat/game-cli-e6 2026-08-09 21:23:31 +05:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
geekiot/mafia-agents!7
No description provided.