Closed personalizedrefrigerator closed 1 month ago
Thanks for bisecting this down. As that commit suggests, this is related to CodeMirror's use of the new EditContext API. The issue appears to be a Chrome bug—I get the same crash in the EditContext example editor. I've filed Chrome issue 370804657. Will try to find some more time today to see if I can do any kind of mitigation on the CodeMirror side.
When this happens, the swipe input doesn't seem to produce any events that are delivered to the script at all. The screen just freezes for a moment, and the tab crashes. It seems hard to detect this virtual keyboard being used (which would allow us to selectively turn off EditContext
). Because the main motivation for using EditContext
in the first place is that it helps work around a host of wonky Android virtual keyboard issues, I really don't want to turn it off for all Chrome Android users.
I'm going to see if there's any response to the Chromium issue before doing anything drastic here.
I've reported this using the SwiftKey issue reporter (https://support-form.swiftkey.com/).
Thanks! Good idea.
The upstream bug has been marked as fixed.
Nice! The only thing we can do then is wait for new Chrome releases that include the fix. I'm going to close this issue here.
Describe the issue
Summary
Attempting to insert swiped text using the SwiftKey keyboard and the example CodeMirror control on
codemirror.net/try
causes the page to crash:codemirror-crash.webm
Note that this also happens with the "minimal editor" example.
Prior versions
If I clone
codemirror/dev
and:git checkout 6.27.0
incodemirror/view
git checkout 6.13.0
incodemirror/autocomplete
(to fix build errors)npm run dev
tcp:8090
to Android withadb reverse tcp:8090 tcp:8090
.then the crash does not occur. However, with
codemirror/view
v6.28.0, the crash does occur.A
git bisect
suggests that the crash was introduced in 51d20b6bde168685f303e5993d79e396b4873f65.Notes:
git checkout 6.28.5
fromcodemirror/view
.Browser and platform
Chrome Android 128.0.6613.148, Microsoft SwiftKey keyboard
Reproduction link
codemirror.net/try