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
Unable to click on an element that uses use-gesture (FF / iOS) #6852
Comments
Hello @Arthy000, Thanks for your report. I reproduced this behavior. |
This issue has been automatically marked as stale because it has not had any activity for a long period. It will be closed and archived if no further activity occurs. However, we may return to this issue in the future. If it still affects you or you have any additional information regarding it, please leave a comment and we will keep it open. |
We're closing this issue after a prolonged period of inactivity. If it still affects you, please add a comment to this issue with up-to-date information. Thank you. |
Any progress on this? This just broke a lot of our testcafe tests and I'd rather not re-introduce a hacky homebrew solution. We can reproduce the issue with @Arthy000's example. |
@ska-kialo If your tests fail in Firefox, please share a simple sample as there could be another underlying issue. |
Thanks for getting back on this so quickly :) Our own tests worked in Chrome but failed in Firefox with the "Invalid pointer id" error.
Edit: The issue that affected our project was the "invalid pointer id" error in Firefox. |
@ska-kialo, I've researched the issue using the attached example in Firefox. It seems there is an underlying bug in Firefox, which is why I would like to investigate your example to validate my assumption. |
@AlexKamaev I'll have to spend some time to set up a small example with our code as it is quite intertwined with our whole application and the failing version is not publicly accessible. I can take a look in the coming days :) |
Okay, so this is an example. Source code: https://codesandbox.io/p/sandbox/recursing-shtern-6t8g7k?file=%2Fsrc%2FApp.js%3A20%2C43 The test fails in Firefox only if I specify Testcafe script: import { fixture, Selector, test } from 'testcafe';
fixture`Test fixture`;
test('Fails on firefox with TC 3.3.0 but succeeds with chrome', async (t) => {
const element = Selector('button').withText('Click me!');
await t.navigateTo('https://6t8g7k.csb.app').click(element);
}); TestCafe version: 3.3.0 Works with |
@ska-kialo <!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
</head>
<body>
<button>click me</button>
<script>
document.querySelector('button').addEventListener('pointerdown', event => {
event.target.setPointerCapture(event.pointerId);
});
setTimeout(() => {
const ev = new PointerEvent('pointerdown', { pointerId: 0 });
document.querySelector('button').dispatchEvent(ev);
}, 1000);
</script>
</body>
</html> To reproduce this behavior, you need to run Firefox using the Terminal. I used Windows
If you open Inspector Panel in Firefox, you will see the same error. I will reopen the issue. However, we need additional time to research the cause of the described behavior and find possible solutions. |
We ran into this issue with https://github.com/inferpse/testcafe-browser-provider-playwright.
(TestCafe 3.4.0) |
@dcsaszar |
I'm facing this issue mentioned by @dcsaszar since version 3.4.0. For 3.3.0 everything works normally.
Not sure if it's related to this issue thread, but I can create another issue if it would make sense. |
@TAkbay, |
What is your Scenario?
Clicking on an element that uses use-gesture
Updating TestCafe to the latest version actually made the issue worse
What is the Current behavior?
With TestCafé 1.18.1 (original issue)
When running the test on FireFox, getting a JS exception.
Ignoring the error doesn't solve the issue as the expected behavior doesn't happen
(no issues when doing the same action manually, or in any other browser)
With TestCafé 1.18.3 (original issue + new issue)
The original Firefox issue still occurs exactly the same way
But now clicking on the same component, running on an iOS device, has no effect at all (neither a JS exception nor the effect of the button)
(no issue manually or in other browsers - full disclosure I haven't tested Android yet)
Regarding the iOS devices I used, I could reproduce the issue consistently on browserstack devices AND on a chrome emulation run
"browserstack:iPhone 13 Pro@15"
"chrome:emulation:device=iphone X"
What is the Expected behavior?
Clicking on that component doesn't raise an exception on any browser/device, and the desired effect of the click happens normally
What is your public website URL? (or attach your complete example)
We made a sandbox with very little content and were able to reproduce the issue easily:
https://0don3.csb.app/
The code is here:
https://codesandbox.io/s/replicate-use-gesture-fail-tce-0don3?file=/src/App.js
What is your TestCafe test code?
TestCafe version
1.18.3
Node.js version
16.13.2
Command-line arguments
testcafe firefox test.ts
testcafe "chrome:emulation:device=iphone X" test.ts
testcafe "browserstack:iPhone 13 Pro@15" test.ts
Browser name(s) and version(s)
Firefox 96.0.3
Chrome 97.0.4692.99
Browserstack => Safari 15.0 / iOS 15.0
The text was updated successfully, but these errors were encountered: