fix: propagate ping spawn errors in verify_port_forwarding#556
Closed
claude-claude[bot] wants to merge 1 commit intofix-pasta-restore-probefrom
Closed
fix: propagate ping spawn errors in verify_port_forwarding#556claude-claude[bot] wants to merge 1 commit intofix-pasta-restore-probefrom
claude-claude[bot] wants to merge 1 commit intofix-pasta-restore-probefrom
Conversation
The new ping-based ARP check used `if let Ok(...)` which silently swallowed command spawn failures (nsenter/ping not found, permission denied). This could cause a 5-second busy loop with a misleading "ARP not resolved" error. Propagate spawn errors immediately with `.context()?` to match the old code's behavior. Also update stale comment in snapshot.rs to reflect the ping-based ARP resolution approach. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Owner
|
Cherry-picked into fix-pasta-restore-probe |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Auto-Fix for PR #555
Issues Fixed
verify_port_forwarding()usedif let Ok(...)on the ping command result, silently discarding spawn failures (e.g.,nsenternot found, permission denied). This caused a 5-second busy loop with no backoff, ending with a misleading "ARP not resolved" error instead of reporting the actual spawn failure.ip neigh showapproach; updated to reflect the new ping-based ARP resolution.Changes
src/network/pasta.rs: Replaceif let Ok(ref out) = ping_resultwith.context("running ping via nsenter in namespace")?to propagate spawn errors immediately (matching the old code's behavior withip neigh show)src/commands/snapshot.rs: Update comment at theverify_port_forwarding()call site to accurately describe the ping → port probe two-step verificationGenerated by Claude | Review Run