Skip to content

feat: PLAN31_2-project-ops project login/ps/logs/scale/build の TUI 追加#57

Merged
takemi-ohama merged 3 commits into
release/PLAN31_2from
feature/PLAN31_2-project-ops
Jun 10, 2026
Merged

feat: PLAN31_2-project-ops project login/ps/logs/scale/build の TUI 追加#57
takemi-ohama merged 3 commits into
release/PLAN31_2from
feature/PLAN31_2-project-ops

Conversation

@takemi-ohama

Copy link
Copy Markdown
Contributor

Summary

Test plan

  • 該当 action が plan 2.3 の契約どおり SimpleNamespace を組んで既存ハンドラを呼ぶ (monkeypatch 単体)
  • 破壊的操作は confirm を介す (該当時)
  • 非 TTY / questionary 不在のフォールバック

@takemi-ohama takemi-ohama marked this pull request as ready for review June 10, 2026 04:10
takemi-ohama and others added 2 commits June 10, 2026 05:27
running 行の操作サブメニューを up/down/login/ps/logs/scale/build/rebuild の全操作へ
拡張し、各操作の引数を tui.menu の収集ヘルパで CLI と同じ属性 (plan 2.3 契約) として
集める。stopped/unknown は従来どおり直接 up (PR1 非回帰)。

- login: index (既定 "1") を text で収集
- ps: --all を confirm で収集
- logs: --follow を confirm、--tail を optional int (空=全件) で収集
- scale: new_scale を integer (min=1) で収集
- build: containers/<image>/Dockerfile を列挙して選択 (compose.yml 全体= image None)
- down: 破壊的操作のため confirm で確認 (plan 3.4)
- 引数収集を Esc/Ctrl-C で中止したら操作サブメニューへ戻る (_ARG_CANCEL)

login/ps/logs/scale は running コンテナ対象のため running 行限定とした。
全 pytest 542 passed / 1 skipped (PR2 で +22)。

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@takemi-ohama takemi-ohama force-pushed the feature/PLAN31_2-project-ops branch from 9660e12 to c3a620c Compare June 10, 2026 05:33

@takemi-ohama takemi-ohama left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 cross-review | round 1 | codex | APPROVE

修正必須の指摘はありません。

検証: uv run pytest -q tests/cli/tui/test_actions_project.py tests/cli/tui/test_menu.py (64 passed)

@takemi-ohama takemi-ohama left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 cross-review | round 1 | gemini | REQUEST_CHANGES

TUI での引数収集におけるエッジケース(空入力や不正な値のハンドリング)について修正を提案します。インラインコメントを確認してください。

Comment thread lib/devbase/tui/actions_project.py Outdated
Comment thread lib/devbase/tui/actions_project.py Outdated
…round1)

- login: menu.text(空入力で "" → --index= 失敗) を menu.integer(default=1,
  min_value=1) に変更し、str(index) で文字列契約を満たして dispatch。
- _optional_int: min_value=0 検証を追加し、logs --tail への負数入力を弾いて
  再入力を促す (docker compose エラー防止)。
- テスト: login を menu.integer モックに追従、負数再入力テストを追加。

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@takemi-ohama

Copy link
Copy Markdown
Contributor Author

cross-review round 1 修正サマリ

gemini の指摘 2 件 (major=1 / minor=1) をいずれも対応しました。codex は APPROVE (0 件) でした。

severity 件数 内容
critical 0 -
major 1 login の index が空入力で --index= 失敗 → menu.integer(default=1, min_value=1) + str(index) で修正
minor 1 logs --tail の負数を _optional_int で弾く (min_value=0 検証追加)
nit 0 -
  • deferred: 0 / rejected: 0
  • fix commit: 88ee5306741a4bb15fca64e7b5ed0783f570fa46
  • テスト: uv run pytest543 passed / 1 skipped (基準 542 から負数テスト +1、退行なし)
  • CI: このブランチに登録 check なし (NONE)
  • 該当 review thread 2 件はいずれも reply + Resolve 済み

🤖 Generated with Claude Code

@takemi-ohama takemi-ohama left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 cross-review | round 2 | codex | APPROVE

修正必須の指摘はありません。

@takemi-ohama takemi-ohama left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 cross-review | round 2 | gemini | APPROVE

PR1の基盤に則り、引数収集とCLIへの委譲がPlan 2.3の契約通りに実装されています。中止や空入力のエッジケースも適切にハンドリングされており問題ありません。

@takemi-ohama takemi-ohama merged commit 29f4d9c into release/PLAN31_2 Jun 10, 2026
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