x11: don't panic in request_user_attention when sending WM hints fails - #34
Draft
Conversation
…tion request_user_attention rings the urgency hint by mutating the window's WM_HINTS and sending the update to the X server. The send result was unwrapped with expect_then_ignore_error, so a failure to send the request (e.g. a dead X11 connection) panicked and aborted the process. Treat the send failure as recoverable: log a warning instead of panicking. On success, keep ignoring the resulting cookie as before. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1 of 4 tasks
This branch has not been deployed
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.
On X11,
Window::request_user_attentionsets the window's urgency hint by mutatingWM_HINTSand sending the update to the X server. The send result was unwrapped withexpect_then_ignore_error, so a failure to send the request — for example a dead X11 connection — panicked and aborted the process. Warp hits this when it rings the terminal bell while inactive; it shows up in Sentry as WARP-CLIENT-BETA-STABLE-89S1.This treats the send failure as recoverable: it logs a warning instead of panicking. On success it keeps ignoring the resulting cookie exactly as before, matching the surrounding error handling in this file.
cargo check --no-default-features --features x11,rwh_06). The failure branch needs a dead X11 connection mid-request, for which winit has no test seam, so it is not covered by an automated test.changelogmodule (src/changelog/unreleased.md).Base branch: this targets
warpdotdev/v0.30.x; the change is applied on the pin Warp currently resolves (a4e0ecb5).Warp side (dependency bump): warpdotdev/warp-for-benchmarks#77.
This PR was created by Warp (running Claude Code).