tftsr-devops_investigation/src-tauri/src/shell
Shaun Arman 9ae89bf487
All checks were successful
Test / frontend-typecheck (pull_request) Successful in 1m49s
Test / frontend-tests (pull_request) Successful in 1m46s
PR Review Automation / review (pull_request) Successful in 4m24s
Test / rust-fmt-check (pull_request) Successful in 12m1s
Test / rust-clippy (pull_request) Successful in 13m46s
Test / rust-tests (pull_request) Successful in 15m8s
fix(security): address automated code review findings
BLOCKER fixes:
- Implement create_azuredevops_workitem instead of returning a stub error,
  reusing the existing create_work_item integration helper and writing an
  audit-log entry on success.
- Log kill failures in PtySession::Drop so leaked child processes surface
  in tracing rather than being silently swallowed.
- Add explicit PTY cleanup on every exit path of run_session_io (process
  exit, read error, write error, resize error, terminate command).
- Treat PTY resize failures as fatal: emit terminal-error to the frontend
  and break the session loop instead of just warning.

WARNING fixes:
- Remove the dead extract_json_path_value helper from commands/kube.rs.
- Wrap temp kubeconfig files in commands/metrics.rs in an RAII guard
  (TempKubeconfig) so they're removed on early-return / panic paths.
- Wrap temp kubeconfig files in commands/shell.rs PTY-session starters
  in a disarmable RAII guard (KubeconfigGuard); if kubectl resolution
  fails we no longer leak the file.
- Drop the `clear;` prefix from the kubectl-exec shell fallback so
  containers without `clear`/`tput` don't print a confusing error.

SUGGESTION fixes:
- Document why node CPU/memory percentages are 0.0 in metrics::client
  and link the gap to future work fetching node capacity.
- Add a module-level doc comment to AppState describing the
  synchronization expectations (std vs tokio Mutex) for each public
  field, and warn against holding std::sync MutexGuards across .await.

Verified: cargo fmt --check, cargo clippy -- -D warnings, and
cargo test (377 passed, 6 ignored) all pass.
2026-06-09 18:08:58 -05:00
..
classifier.rs fix(classifier): fix 3 safety bugs, extract const arrays, make tier UI dynamic 2026-06-07 18:15:42 -05:00
executor.rs feat: add three-tier shell execution with kubectl support 2026-06-05 07:59:04 -05:00
helm.rs feat(kube): implement 44 new Rust K8s commands + helm binary support 2026-06-08 20:34:01 -05:00
kubeconfig.rs fix(kube): use current-context for kubectl auth; fix SelectValue label display 2026-06-07 19:40:53 -05:00
kubectl.rs feat: add three-tier shell execution with kubectl support 2026-06-05 07:59:04 -05:00
mod.rs fix(performance): resolve memory leaks and add polish features 2026-06-09 13:28:30 -05:00
pty.rs fix(security): address automated code review findings 2026-06-09 18:08:58 -05:00
session.rs fix(security): address automated code review findings 2026-06-09 18:08:58 -05:00
tests.rs feat: add three-tier shell execution with kubectl support 2026-06-05 07:59:04 -05:00