synpress
synpress copied to clipboard
[๐ Bug]: 'approveTokenPermission' method is flaky
๐ Have you searched existing issues to avoid duplicates?
- [x] I have made sure that my issue is not a duplicate.
๐งช Have you tested your code using latest version of Synpress?
- [x] I have made sure that my issue still exists on latest version of Synpress.
๐ก Are you able to provide enough information to be able to reproduce your issue locally?
- [x] I can provide enough details to reproduce my issue on local environment.
Synpress version
4.0.10
Node.js version
20.17.0
Operating system
Ubuntu 22.04 AMD64
Run mode
Playwright + Synpress (as plugin)
CI platform (if applicable)
Github Actions
Are you running your tests inside docker? (if applicable)
- [ ] This issue could be related to docker.
What happened?
We have experienced that the metamask.approveTokenPermission method has flaky behaviour. As for rough numbers for how flaky - in ~30 runs in our GitHub Actions workflow in the last week, we may have experienced 1-4 test failures due to metamask.approveTokenPermission being flaky.
When we look at the Playwright traces, we see that the UI is stuck on the Metamask Approve screen.
Here is a Github Workflow run where it has failed due to this method being unreliable - https://github.com/Consensys/linea-monorepo/actions/runs/14128499736/job/39582945183
Essentially the metamask.approveTokenPermission method has completed execution, yet the Metamask Approval screen has not been interacted with, leading to a stuck test.
What is your expected behavior?
'metamask.approveTokenPermission' method should not be flaky
How to reproduce the bug.
Don't have a deterministic method to reproduce the bug unfortunately. But seeing that I've encountered it 5 times in the last 2 weeks (in maybe ~50 test runs), I think the flakiness rate is too high.
Relevant log output