Summary
The TUI shell connect ([s] key on sandbox detail) is completely broken. Pressing it flashes the screen briefly and returns to the TUI immediately. After a few attempts the terminal goes black.
Root Cause
Commit 61f3e7f (#175) renamed the ssh-proxy subcommand's CLI arguments as part of the cluster→gateway rebranding:
| Before #175 |
After #175 |
Purpose |
--gateway |
--gateway-endpoint |
Gateway URL (token mode) |
--cluster |
--gateway |
Cluster/gateway name (TLS cert resolution) |
That commit updated three of the five proxy command format strings:
- CLI
ssh_session_config in ssh.rs — updated
- CLI
print_ssh_config in ssh.rs — updated
- TUI
start_port_forwards in lib.rs — updated
- TUI
handle_shell_connect in lib.rs — missed
- TUI
handle_exec_command in lib.rs — missed
The two missed functions still build the proxy command as:
nemoclaw ssh-proxy --gateway <url> --sandbox-id <id> --token <token>
After the rename, --gateway means "cluster name" (name mode), not "URL" (token mode). Since --gateway-endpoint is missing, the ssh-proxy subcommand can't match token mode. Since --name is also missing, it can't match name mode either. It falls through to the error case and exits immediately.
SSH sees its ProxyCommand fail and exits — that's the flash. Repeated rapid TUI suspend/resume cycles (leave alternate screen → SSH fails instantly → re-enter alternate screen) corrupt the terminal state — that's the black screen.
Pre-existing gap
These two functions also never passed the cluster name for TLS cert resolution. The TUI was added in 734ec5e (Mar 2, 09:56), four hours before 189470c added --cluster to the CLI's proxy command (Mar 2, 13:52). The TUI was never backfilled. Before #175 this was a latent issue (no TLS on local clusters). After #175 it became a hard failure.
Fix
Change both handle_shell_connect and handle_exec_command to use the correct argument names matching the current main.rs definitions, and pass the cluster name:
// Before (broken)
"{exe_str} ssh-proxy --gateway {gateway_url} --sandbox-id {} --token {}"
// After (correct — matches start_port_forwards and CLI ssh_session_config)
"{exe_str} ssh-proxy --gateway-endpoint {gateway_url} --sandbox-id {} --token {} --gateway {cluster}"
Affected Code
crates/navigator-tui/src/lib.rs — handle_shell_connect() (~line 712)
crates/navigator-tui/src/lib.rs — handle_exec_command() (~line 854)
Reproduction
mise run term
- Select a sandbox, press
Enter
- Press
[s] to connect shell
- Screen flashes and returns to TUI immediately
- Repeat a few times — terminal goes black
Summary
The TUI shell connect (
[s]key on sandbox detail) is completely broken. Pressing it flashes the screen briefly and returns to the TUI immediately. After a few attempts the terminal goes black.Root Cause
Commit
61f3e7f(#175) renamed thessh-proxysubcommand's CLI arguments as part of the cluster→gateway rebranding:--gateway--gateway-endpoint--cluster--gatewayThat commit updated three of the five proxy command format strings:
ssh_session_configinssh.rs— updatedprint_ssh_configinssh.rs— updatedstart_port_forwardsinlib.rs— updatedhandle_shell_connectinlib.rs— missedhandle_exec_commandinlib.rs— missedThe two missed functions still build the proxy command as:
After the rename,
--gatewaymeans "cluster name" (name mode), not "URL" (token mode). Since--gateway-endpointis missing, thessh-proxysubcommand can't match token mode. Since--nameis also missing, it can't match name mode either. It falls through to the error case and exits immediately.SSH sees its
ProxyCommandfail and exits — that's the flash. Repeated rapid TUI suspend/resume cycles (leave alternate screen → SSH fails instantly → re-enter alternate screen) corrupt the terminal state — that's the black screen.Pre-existing gap
These two functions also never passed the cluster name for TLS cert resolution. The TUI was added in
734ec5e(Mar 2, 09:56), four hours before189470cadded--clusterto the CLI's proxy command (Mar 2, 13:52). The TUI was never backfilled. Before #175 this was a latent issue (no TLS on local clusters). After #175 it became a hard failure.Fix
Change both
handle_shell_connectandhandle_exec_commandto use the correct argument names matching the currentmain.rsdefinitions, and pass the cluster name:Affected Code
crates/navigator-tui/src/lib.rs—handle_shell_connect()(~line 712)crates/navigator-tui/src/lib.rs—handle_exec_command()(~line 854)Reproduction
mise run termEnter[s]to connect shell