-
Notifications
You must be signed in to change notification settings - Fork 3k
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
[HOLD for payment 2024-12-30] [$250] iOS&Android Expense - App does not respond to long tap on receipt placeholder area on expense preview #53697
Comments
Triggered auto assignment to @bfitzexpensify ( |
Edited by proposal-police: This proposal was edited at 2024-12-12 08:04:33 UTC. ProposalPlease re-state the problem that we are trying to solve in this issue.Long press on a empty receipt doesn't show the context menu. What is the root cause of that problem?The receipt empty state is wrapped with a pressable. App/src/components/ReceiptEmptyState.tsx Lines 24 to 33 in b9107bf
This makes it a nested pressable in a ReportPreview or MoneyRequestPreviewContent. The long press doesn't bubble up, which is why we manually handle the report preview long press to show the context menu. App/src/components/ReportActionItem/ReportPreview.tsx Lines 464 to 468 in b9107bf
But we don't do the same for the receipt empty state component. What changes do you think we should make in order to solve the problem?But instead of handling the long press manually for receipt empty state, we can just render a View instead of Pressable if the receipt empty state App/src/components/ReceiptEmptyState.tsx Lines 24 to 33 in b9107bf
Then, we can remove the receipt image App/src/components/ReportActionItem/ReportPreview.tsx Lines 475 to 480 in b9107bf
App/src/components/ReportActionItem/MoneyRequestPreview/MoneyRequestPreviewContent.tsx Lines 351 to 355 in b9107bf
It was added because the parent pressable What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?When creating the test for this, I found that it behaves differently when running on the test environment. The issue we have here is basically if we have nested pressable, then only the inner pressable will receive the press/long-press event (which was observed first in this PR). But when I recreate this on the test environment as simple as this:
the outer pressable long press is triggered just fine. So, the unit test can't cover this case. |
@bfitzexpensify Whoops! This issue is 2 days overdue. Let's get this updated quick! |
Job added to Upwork: https://www.upwork.com/jobs/~021866480849153052085 |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @suneox ( |
@bernhardoj proposal LGTM. In this case, we can prevent nested pressables 🎀 👀 🎀 C+ reviewed |
Triggered auto assignment to @blimpich, see https://stackoverflow.com/c/expensify/questions/7972 for more details. |
@bernhardoj @suneox can we add unit testing to the proposal? Or list a strong reason why we aren't adding unit tests? See this slack post for a reminder on our new policy of unit tests for bugs. |
Currently, our tests focus on unit testing for functions like utilities, Onxy data, Req/Res, .... However, this issue involves user interactions, which we don’t fully support in unit tests yet |
I believe we are able to test user interactions, there just aren't many test suites yet. See below test suites:
If there is a technical reason why we can't add unit tests for this I'd like that to be added to the proposal. If it would take too much work than I'd also accept that, but I'd like to know why it takes so much work / isn't possible right now. |
@bernhardoj Thank you for the explanation! Sorry for bugging you both for it but we are really trying to push for more unit tests and its very helpful for me to know why its difficult or what scenarios we aren't able to test right now. Thank you! Lets fix this without new jest tests 👍 |
📣 @suneox 🎉 An offer has been automatically sent to your Upwork account for the Reviewer role 🎉 Thanks for contributing to the Expensify app! |
PR is ready cc: @suneox |
|
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.77-6 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue: If no regressions arise, payment will be issued on 2024-12-30. 🎊 For reference, here are some details about the assignees on this issue:
|
@suneox @bfitzexpensify @suneox The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the BugZero Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button] |
If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!
Version Number: 9.0.72-0
Reproducible in staging?: Yes
Reproducible in production?: Yes
If this was caught on HybridApp, is this reproducible on New Expensify Standalone?: Yes, reproducible on both
If this was caught during regression testing, add the test name, ID and link from TestRail: Exp
Email or phone of affected tester (no customers): [email protected]
Issue reported by: Applause Internal Team
Action Performed:
Expected Result:
App will respond to the long tap and open more options menu.
Actual Result:
App does not respond to long tap on the empty receipt placeholder area on the expense preview.
Workaround:
Unknown
Platforms:
Screenshots/Videos
Bug6686288_1733482732185.ScreenRecording_12-06-2024_18-50-53_1.mp4
View all open jobs on GitHub
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @bfitzexpensifyThe text was updated successfully, but these errors were encountered: