Skip to content

Use Effect Duration policies in SSH readiness#2894

Draft
cursor[bot] wants to merge 1 commit into
mainfrom
cursor/idiomatic-effect-patterns-6a04
Draft

Use Effect Duration policies in SSH readiness#2894
cursor[bot] wants to merge 1 commit into
mainfrom
cursor/idiomatic-effect-patterns-6a04

Conversation

@cursor
Copy link
Copy Markdown
Contributor

@cursor cursor Bot commented Jun 1, 2026

What Changed

  • Replaced SSH command and tunnel readiness timeout options with Duration.Input values.
  • Centralized SSH readiness, probe, and shutdown policy constants as Duration values.
  • Swapped nullable readiness probe state for Option while preserving millisecond diagnostic fields.
  • Updated SSH Effect-vitest coverage to exercise the duration-based API.

Why

This makes the SSH path more idiomatic Effect by keeping timing policies in effect/Duration and using Option for optional state. Millisecond conversion now happens only at integration/diagnostic boundaries such as remote script placeholders and log fields.

UI Changes

None.

Checklist

  • This PR is small and focused
  • I explained what changed and why
  • I included before/after screenshots for any UI changes
  • I included a video for animation/interaction changes
Open in Web View Automation 

Note

Replace millisecond number options with Duration inputs in SSH readiness checks

  • Replaces timeoutMs, intervalMs, and probeTimeoutMs number options with timeout, interval, and probeTimeout accepting Duration.Input in waitForHttpReady (tunnel.ts) and runSshCommand (command.ts).
  • Internal millisecond constants (e.g. SSH_READY_TIMEOUT_MS) are replaced with Duration constants; effective timeout values are unchanged.
  • Scripts built by buildRemoteLaunchScript still receive millisecond strings, now derived via Duration.toMillis.
  • Risk: Breaking API change — callers of runSshCommand and waitForHttpReady must update from numeric millisecond options to Duration.Input options.

Macroscope summarized 4316922.

Co-authored-by: Julius Marminge <juliusmarminge@users.noreply.github.com>
@github-actions github-actions Bot added vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. size:M 30-99 changed lines (additions + deletions). labels Jun 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:M 30-99 changed lines (additions + deletions). vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant