You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[$1000] Web - Delete Button Fails to Delete Changed Description in IOU #25997
Enter desired amount and email address for Request Money
Open the IOU and change the description
Click on the three dots and select "Delete Request"
Observe that the Request is deleted, but the changed description remains in the IOU
Expected Result:
The Delete button should delete the changed description from the IOU as well.
Actual Result:
The Delete button fails to delete the changed description inside the IOU.
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Android / native
Android / Chrome
iOS / native
iOS / Safari
MacOS / Chrome / Safari
MacOS / Desktop
Version Number: 1.3.57-5 Reproducible in staging?: y Reproducible in production?: y If this was caught during regression testing, add the test name, ID and link from TestRail: Email or phone of affected tester (no customers): Logs:https://stackoverflow.com/c/expensify/questions/4856 Notes/Photos/Videos: Any additional supporting documentation
changed the title [-]Web - Delete Button Fails to Delete Changed Description in IOU[/-][+][$1000] Web - Delete Button Fails to Delete Changed Description in IOU[/+]on Aug 28, 2023
Please re-state the problem that we are trying to solve in this issue.
The Delete button fails to delete the changed description inside the IOU.
What is the root cause of that problem?
In these lines, we have the logic to check whether we should delete the transaction threads, we'll delete it if there's no visible message. However, we're not excluding the MODIFIEDEXPENSE action when calculating that visible message. So if there's any MODIFIEDEXPENSE action, the transaction thread will not be deleted and the actions will still be visible.
It doesn't make sense to keep all the MODIFIEDEXPENSE actions once the transaction thread is deleted by the user, so we should also delete the transaction thread if it contains only MODIFIEDEXPENSE actions.
What changes do you think we should make in order to solve the problem?
We need to exclude the MODIFIEDEXPENSE report actions when calculating the last message here
This can be done by, for example, adding a shouldExclude callback to the getLastVisibleAction and getLastVisibleMessage. The default value of shouldExclude in those definitions will be shouldExclude = () => false
Similarly, we need to update the usage of getLastVisibleAction, getLastVisibleMessage in that file for consistency.
If it's desirable to delete all MODIFIEDEXPENSE actions even though there're other non-MODIFIEDEXPENSE actions in the list, we can remove them in the optimisticDatahere as well.
The back-end will need to be fixed similarly
What alternative solutions did you explore? (Optional)
There're other ways to do the above besides shouldExclude, like adding shouldExcludeModifiedExpense boolean, or create a new set of functions getLastVisibleAction, getLastVisibleMessage similar to to use in that delete money request case.
Details on the shouldExcludeModifiedExpense solution:
Adding a shouldExcludeModifiedExpense boolean param to the getLastVisibleAction and getLastVisibleMessage. The default value of shouldExcludeModifiedExpense in those definitions will be false
so it won't include the modified expense action if the shouldExcludeModifiedExpense is true.
We'll use it to filter out the MODIFIEDEXPENSE actions here (by passing shouldExcludeModifiedExpense as true)
Same for the usage of getLastVisibleAction, getLastVisibleMessage in that file for consistency.
The back-end will also need to be fixed to delete the transaction thread in that case.
A proposal was #27570 (comment) and while implementing the #29259, it was decided that the issue would be best solved on the backend.
and our internal doc states
We also pay 100% to the contributor and C+ if we hired them then decided to fix the issue internally or close the issue (assuming the contributor and C+ were both actively working on the issue).
This issue is different because we didn't make a decision to fix it on the backend.
For #30692 (comment)
Both Jasper and Vivek agreed to close the issue, so that's also different than issue and also fits with the stated guideline above.
Part of what leads me to believe 50% is fair is because the hire date was Oct 5 and the PR was still being worked on as of Dec 28th and there were multiple bumps to move the PR along. If this PR would have been merged before the one that fixed it, would it have made a difference? (I don't know). If so, then we could have saved time both working on this one AND the other by closing them both sooner.
We appreciate and value the time and investment, our main goal is to get bugs fixed and to do it with urgency, which is what I consider the a benchmark for similar issues like there where another PR (appears to) magically fix the bug (from what I know, I'm not the most well versed on this specific issue or PR)
the hire date was #25997 (comment) and the PR was still being worked on as of #28995 (comment) and there were multiple bumps to move the PR along.
@mallenexpensify I believe part of the reason for the delay is this is a fairly complex issue, we faced many technical challenges during the implementation and tried to make sure to resolve all of them (~50 commits) before merging to not cause regressions/affect the app performance.
So I'd appreciate if we can keep the full payment here since the PR is mostly ready for merging before it was made outdated due to another change. Also the reason why the other PR was able to resolve the bugs is not because that PR resolves the technical issues we faced, just that they achieved a different expectation that conflicts with the expectations in this issue so this issue is no longer reproducible.
If this PR would have been merged before the one that fixed it, would it have made a difference? (I don't know)
@mallenexpensify regarding this, it will not make a difference since the 2 PRs have 2 conflicting expectations, if this PR is merged first, the other PR would still override the expectation in this PR.
@dukenv0307@mollfpr Thank you for your patience with this matter. We've discussed this internally and have decided to keep full payment on your work considering the sheer amount of time and effort you've put into implementation and review. Thank you for sticking with it, we really appreciate your hard work!
Activity
melvin-bot commentedon Aug 26, 2023
Triggered auto assignment to @CortneyOfstad (
Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.melvin-bot commentedon Aug 26, 2023
Bug0 Triage Checklist (Main S/O)
Platformsin OP are ✅)CortneyOfstad commentedon Aug 28, 2023
Was able to recreate, as shown in the screenshots below. Getting eyes on this!
[-]Web - Delete Button Fails to Delete Changed Description in IOU[/-][+][$1000] Web - Delete Button Fails to Delete Changed Description in IOU[/+]melvin-bot commentedon Aug 28, 2023
Job added to Upwork: https://www.upwork.com/jobs/~01462271c6de352d0a
melvin-bot commentedon Aug 28, 2023
Current assignee @CortneyOfstad is eligible for the External assigner, not assigning anyone new.
melvin-bot commentedon Aug 28, 2023
Triggered auto assignment to Contributor-plus team member for initial proposal review - @mollfpr (
External)WaqasIbrahim commentedon Aug 28, 2023
This seems like an internal issue. I sent two requests.

Without description change:
With description change:

Look at the value of
hasOutstandingIOUin both cases.dukenv0307 commentedon Aug 28, 2023
Proposal
Please re-state the problem that we are trying to solve in this issue.
The Delete button fails to delete the changed description inside the IOU.
What is the root cause of that problem?
In these lines, we have the logic to check whether we should delete the transaction threads, we'll delete it if there's no visible message. However, we're not excluding the
MODIFIEDEXPENSEaction when calculating that visible message. So if there's anyMODIFIEDEXPENSEaction, the transaction thread will not be deleted and the actions will still be visible.It doesn't make sense to keep all the
MODIFIEDEXPENSEactions once the transaction thread is deleted by the user, so we should also delete the transaction thread if it contains onlyMODIFIEDEXPENSEactions.What changes do you think we should make in order to solve the problem?
We need to exclude the
MODIFIEDEXPENSEreport actions when calculating the last message hereApp/src/libs/actions/IOU.js
Line 1072 in 64ff471
This can be done by, for example, adding a
shouldExcludecallback to thegetLastVisibleActionandgetLastVisibleMessage. The default value ofshouldExcludein those definitions will beshouldExclude = () => falseAnd then we can update this line to
We'll use it to filter out the
MODIFIEDEXPENSEactions here likeSimilarly, we need to update the usage of
getLastVisibleAction,getLastVisibleMessagein that file for consistency.If it's desirable to delete all
MODIFIEDEXPENSEactions even though there're other non-MODIFIEDEXPENSE actions in the list, we can remove them in theoptimisticDatahere as well.The back-end will need to be fixed similarly
What alternative solutions did you explore? (Optional)
There're other ways to do the above besides
shouldExclude, like addingshouldExcludeModifiedExpenseboolean, or create a new set of functionsgetLastVisibleAction,getLastVisibleMessagesimilar to to use in that delete money request case.Details on the
shouldExcludeModifiedExpensesolution:Adding a
shouldExcludeModifiedExpenseboolean param to thegetLastVisibleActionandgetLastVisibleMessage. The default value ofshouldExcludeModifiedExpensein those definitions will be falseUpdate this line to
so it won't include the modified expense action if the
shouldExcludeModifiedExpenseis true.MODIFIEDEXPENSEactions here (by passingshouldExcludeModifiedExpenseas true)Same for the usage of
getLastVisibleAction,getLastVisibleMessagein that file for consistency.The back-end will also need to be fixed to delete the transaction thread in that case.
133 remaining items
mallenexpensify commentedon Jan 23, 2024
For #27570 (comment)
and our internal doc states
This issue is different because we didn't make a decision to fix it on the backend.
For #30692 (comment)
Both Jasper and Vivek agreed to close the issue, so that's also different than issue and also fits with the stated guideline above.
Part of what leads me to believe 50% is fair is because the hire date was Oct 5 and the PR was still being worked on as of Dec 28th and there were multiple bumps to move the PR along. If this PR would have been merged before the one that fixed it, would it have made a difference? (I don't know). If so, then we could have saved time both working on this one AND the other by closing them both sooner.
We appreciate and value the time and investment, our main goal is to get bugs fixed and to do it with urgency, which is what I consider the a benchmark for similar issues like there where another PR (appears to) magically fix the bug (from what I know, I'm not the most well versed on this specific issue or PR)
dukenv0307 commentedon Jan 23, 2024
@mallenexpensify I believe part of the reason for the delay is this is a fairly complex issue, we faced many technical challenges during the implementation and tried to make sure to resolve all of them (~50 commits) before merging to not cause regressions/affect the app performance.
So I'd appreciate if we can keep the full payment here since the PR is mostly ready for merging before it was made outdated due to another change. Also the reason why the other PR was able to resolve the bugs is not because that PR resolves the technical issues we faced, just that they achieved a different expectation that conflicts with the expectations in this issue so this issue is no longer reproducible.
@mallenexpensify regarding this, it will not make a difference since the 2 PRs have 2 conflicting expectations, if this PR is merged first, the other PR would still override the expectation in this PR.
mallenexpensify commentedon Jan 26, 2024
Thanks @dukenv0307 , we're discussing internally.
jasperhuangg commentedon Jan 26, 2024
@dukenv0307 @mollfpr Thank you for your patience with this matter. We've discussed this internally and have decided to keep full payment on your work considering the sheer amount of time and effort you've put into implementation and review. Thank you for sticking with it, we really appreciate your hard work!
jasperhuangg commentedon Jan 29, 2024
@CortneyOfstad can you help with issuing payment here?
CortneyOfstad commentedon Jan 29, 2024
Created a new Job post here — https://www.upwork.com/jobs/~016e3532aa6b8d64fd
@dukenv0307 sent you a proposal in Upwork
@mollfpr you'll be paid via NewDot — I'll create the proposal once Duc accepts in Upwork 👍
dukenv0307 commentedon Jan 30, 2024
@CortneyOfstad I've accepted, thank you!
tewodrosGirmaA commentedon Jan 30, 2024
@CortneyOfstad @jasperhuangg May I inquire about my eligibility for compensation regarding the bug report? Thank you.
mallenexpensify commentedon Jan 30, 2024
ah.. yes, @tewodrosGirmaA you are eligible since this was reported forever ago, ha. Amount is $250 because it was before the decrease to $50. .
@CortneyOfstad can you pay out plz?
CortneyOfstad commentedon Jan 31, 2024
Sorry about that @tewodrosGirmaA! I sent you a proposal in Upwork — let me know once you accept and I'll get that paid ASAP. Thanks!
tewodrosGirmaA commentedon Jan 31, 2024
Hello @CortneyOfstad i accept it , Thank you
CortneyOfstad commentedon Jan 31, 2024
Payment Summary
@tewodrosGirmaA (reporter) — paid $250 via Upwork
@dukenv0307 (contributor) — paid $1000 via Upwork
@mollfpr (C+) — to be paid $1000 via NewDot
tewodrosGirmaA commentedon Jan 31, 2024
Thank you @CortneyOfstad
JmillsExpensify commentedon Jan 31, 2024
$1,000 approved for @mollfpr for based on summary above.