Conversation
…HANGE See #8675. Bumps the winit git dependency to warpdotdev/winit#20, which handles WM_INPUTLANGCHANGE by refreshing the keyboard-layout cache instead of leaving it unhandled.
acarl005
marked this pull request as draft
September 11, 2026 21:56
Contributor
|
I'm starting a first review of this pull request. You can view the conversation on Warp. I completed the review and no human review was requested for this pull request. Comment Powered by Oz |
Contributor
There was a problem hiding this comment.
Overview
This PR updates the winit git dependency and corresponding lockfile entries to a newer fork revision intended to refresh the Windows keyboard layout cache on WM_INPUTLANGCHANGE.
Concerns
- No blocking correctness, security, testing, comment-guideline, or spec-drift concerns found in the attached diff.
- No approved spec context was provided for implementation comparison.
Verdict
Found: 0 critical, 0 important, 0 suggestions
Approve
Comment /warp-agent-review on this pull request to retrigger a review (up to 3 times on the same pull request).
Powered by Oz
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.
Description
#8675 ("Punto Switcher freezes Warp") links a chain that I could not treat as reliable: this repo's winit fork PR #15,
rust-windowing/winit#4584, and an alleged upstream mergerust-windowing/winit#4582. I found that chain to be fabricated:rust-windowing/winit's real commit history shows the Windows backend (src/platform_impl/windows/keyboard.rs) was moved into a separatewinit-win32crate on 2025-05-25, before the dates on the alleged ctrl+d exits shell during input #4582 fix. That PR/merge doesn't exist in winit's real history.{ let mut layouts = LAYOUT_CACHE.lock().unwrap(); layouts.get_current_layout(); }) is a no-op:get_current_layoutreturns an already-cached entry unchanged, so it can't "refresh" anything.What I could independently confirm is a real, narrower defect in the same area:
LayoutCacheis keyed byHKLand nothing ever explicitly refreshes an entry once cached, even though Windows can reuse anHKLvalue for a different layout after the original is unloaded. warpdotdev/winit#20 fixes that by addingLayoutCache::refresh_current_layout(which, unlike the previously-proposed one-liner, actually recomputes and replaces the cache entry) and wiring it up toWM_INPUTLANGCHANGE, while still deferring toDefWindowProcper the Win32 docs.This PR just bumps the
winitgit dependency to that fix.Linked Issue
Testing
cargo check -p warpuiagainst the updated winit revision./ITtask targeting the logged-on console session, since my shell itself runs in a non-interactive session whereLoadKeyboardLayoutW/ActivateKeyboardLayoutsilently no-op), then ran a harness that installs aWH_GETMESSAGEhook mirroring Punto Switcher's mechanism and performs real backspace+layout-switch+retype cycles (alternating Russian/US English via the real Win32 APIs) against both winit revisions for 25s each. Both completed ~48-49 real layout switches with zero failures andIsHungAppWindowstaying0throughout -- no freeze in either the pre-fix or post-fix build via this mechanism.LayoutCache::refresh_current_layoutis a real, tested, and dynamically-verified improvement, I can't claim it resolves Punto Switcher freezes Warp #8675's exact "Not Responding" symptom -- I was unable to reproduce that symptom at all here to confirm a fix against it.Agent Mode
Conversation: https://staging.warp.dev/conversation/31296228-6871-4644-8ff9-761c1f03e060
Run: https://platform.staging.warp.dev/runs/01a0925f-ddb5-7e1c-9b87-afd8ec007016