Skip to content

Handle remote install filesystem environment failures#11150

Draft
alokedesai wants to merge 1 commit into
masterfrom
oz/remote-filesystem-quota-handling
Draft

Handle remote install filesystem environment failures#11150
alokedesai wants to merge 1 commit into
masterfrom
oz/remote-filesystem-quota-handling

Conversation

@alokedesai
Copy link
Copy Markdown
Member

Summary

  • Added a remote install filesystem preflight that expands/creates the SSH extension install directory, verifies writability with a write/delete probe, and checks available KiB/inodes via df -Pk/df -Pi before direct remote install and before SCP fallback upload.
  • Added typed remote install environment failures for permission denied, read-only filesystem, no space, quota, inode exhaustion, and write-probe failures; late install/SCP stderr still classifies common filesystem failures as a backstop.
  • Added user-facing guidance and telemetry disambiguation fields on the existing RemoteServerInstallation event: is_environment_failure, counts_as_product_error, and setup_failure_class.
  • Updated the bundled install script with the same filesystem checks so script-level failures remain recognizable if the standalone preflight is missed.
  • Added regression tests for preflight marker parsing, late stderr classification, transport promotion, and generated preflight script contents.

Base branch note

The requested base branch aloke/remote_code_errors_new was not fetchable in this cloud checkout (fatal: couldn't find remote ref aloke/remote_code_errors_new). Per orchestrator fallback instructions, this PR targets master.

Diff summary

 .../remote_server/ssh_transport/installation.rs    |  22 +-
 .../ssh_transport/installation/scp_fallback.rs     |  35 +--
 app/src/server/telemetry/events.rs                 |   9 +
 app/src/terminal/view.rs                           |  10 +-
 crates/remote_server/src/install_remote_server.sh  |  60 ++++-
 crates/remote_server/src/setup.rs                  | 289 +++++++++++++++++++++
 crates/remote_server/src/setup_tests.rs            |  90 ++++++-
 crates/remote_server/src/transport.rs              |  42 ++-
 8 files changed, 526 insertions(+), 31 deletions(-)

Validation

  • cargo fmt --manifest-path /workspace/warp/Cargo.toml --all
  • cargo test --manifest-path /workspace/warp/Cargo.toml -p remote_server ✅ (77 passed)
  • cargo check --manifest-path /workspace/warp/Cargo.toml -p warp
  • cargo clippy --manifest-path /workspace/warp/Cargo.toml -p remote_server --all-targets
  • cargo clippy --manifest-path /workspace/warp/Cargo.toml -p warp --lib

Visual/artifact evidence

  • /tmp/warp_remote_fs_artifacts/permission_denied_preflight.log (artifact uid 019e3756-e39a-7343-aa33-f0ac797fc24a) shows the production install script exits with code 4 and emits warp_remote_server_filesystem_preflight_failed kind=permission_denied ... detail=mkdir_failed before download/extraction.
  • /tmp/warp_remote_fs_artifacts/telemetry_disambiguation_evidence.json (artifact uid 019e3756-e595-7c8c-93d1-dc4f7887cf5d) shows the intended telemetry disambiguation values: is_environment_failure=true, counts_as_product_error=false, and setup_failure_class=unsupported_environment.
  • /tmp/warp_remote_fs_artifacts/screenshot_permission_denied_preflight_log.png (artifact uid 019e3759-1f0e-715e-8e05-73e1957f86c0) is the GUI screenshot of the preflight log.
  • /tmp/warp_remote_fs_artifacts/screenshot_telemetry_disambiguation_evidence_json.png (artifact uid 019e3759-20ca-76f7-8765-5c3c03368384) is the GUI screenshot of the telemetry evidence JSON.

Limitations

  • docker is not installed in this sandbox, so I could not create an SSH-enabled constrained Linux container. The artifact uses the closest available Linux reproduction: running the production install script as nobody with an unwritable $HOME, which exercises the same remote filesystem preflight marker/classification path.

Co-Authored-By: Oz oz-agent@warp.dev

Conversation: https://staging.warp.dev/conversation/6766a133-e188-46b5-9181-c3ee589d58f8
Run: https://oz.staging.warp.dev/runs/019e3748-dacf-7650-b1ff-abfb5fd05e58
This PR was generated with Oz.

Co-Authored-By: Oz <oz-agent@warp.dev>
@cla-bot cla-bot Bot added the cla-signed label May 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant