-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Intervention] Ignored attempt to cancel a touchstart event with cancelable=false, for example because scrolling is in progress and cannot be interrupted. #553
Comments
jschaf
added a commit
to jschaf/signature_pad
that referenced
this issue
Jul 17, 2022
Chrome has started warning when canceling an event that cannot be cancelled, like scrolling. This causes a fair bit of log spam. I know it fires for touchmove and touchend and there's reports that it also fires for touchstart. IgnoredEventCancel: intervention: Ignored attempt to cancel a touchmove event with cancelable=false, for example because scrolling is in progress and cannot be interrupted References: - react-grid-layout/react-draggable#553 - https://www.uriports.com/blog/easy-fix-for-intervention-ignored-attempt-to-cancel-a-touchmove-event-with-cancelable-false/ - FL3NKEY/scroll-lock#19 - https://stackoverflow.com/a/53315365/30900
jschaf
added a commit
to jschaf/mapbox-gl-js
that referenced
this issue
Jul 28, 2022
Chrome has started warning when canceling an event that cannot be cancelled, like scrolling. This causes a fair bit of log spam. I know it fires for touchmove and touchend and there's reports that it also fires for touchstart. IgnoredEventCancel: intervention: Ignored attempt to cancel a touchmove event with cancelable=false, for example because scrolling is in progress and cannot be interrupted References: - react-grid-layout/react-draggable#553 - https://www.uriports.com/blog/easy-fix-for-intervention-ignored-attempt-to-cancel-a-touchmove-event-with-cancelable-false/ - FL3NKEY/scroll-lock#19 - https://stackoverflow.com/a/53315365/30900 Fixes mapbox#11961.
mourner
added a commit
to mapbox/mapbox-gl-js
that referenced
this issue
Jul 28, 2022
* check for event.cancelable in touch events Chrome has started warning when canceling an event that cannot be cancelled, like scrolling. This causes a fair bit of log spam. I know it fires for touchmove and touchend and there's reports that it also fires for touchstart. IgnoredEventCancel: intervention: Ignored attempt to cancel a touchmove event with cancelable=false, for example because scrolling is in progress and cannot be interrupted References: - react-grid-layout/react-draggable#553 - https://www.uriports.com/blog/easy-fix-for-intervention-ignored-attempt-to-cancel-a-touchmove-event-with-cancelable-false/ - FL3NKEY/scroll-lock#19 - https://stackoverflow.com/a/53315365/30900 Fixes #11961. * Update src/ui/handler/touch_pan.js Co-authored-by: Volodymyr Agafonkin <agafonkin@gmail.com> Co-authored-by: Volodymyr Agafonkin <agafonkin@gmail.com>
It looks like a working small change, any chance to merge a PR for this? |
I would like to suggest adding // Short circuit if handle or cancel prop was provided and selector doesn't match.
if (
// 1. we can't cancel the non-cancelable events
// 2. so, we shouldn't start the dragging logic to avoid unpredictable behavior
// 3. otherwise, we might fall into the situation e.g. when the scrolling is happening and touchmove is firing,
// but the touchmove event will be fired on android in chrome once per 200ms
e.cancelable === false ||
// .... other conditions
return;
} the main problem I came across:
I can get that bug on the emulator during performance profiling and real-device Screen_Recording_20240707_113056_Chrome.1.mp4 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I get an error on touch events (however, the app doesn't break).
This problem can be solved by using:
https://alexandrerosseto.medium.com/solving-issue-intervention-ignored-attempt-to-cancel-a-touchmove-event-with-cancelable-false-62014ef15742
The text was updated successfully, but these errors were encountered: