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
[Due for payment 2025-10-06] [$250] Expense - After exporting to CSV, "Unapprove report" modal shows up when unapproving report #70011
Wait for download message from Concierge to show up.
Click More > Unapprove.
Expected Result:
The report will be unapproved without "Unapprove report" confirm modal because the workspace is not connected to accounting system.
Actual Result:
After exporting to All Data - report level, "Unapprove report" confirm modal shows up when unapproving the report.
"Heads up! This report has already been exported to ." is incomplete.
What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?
N/A
What alternative solutions did you explore? (Optional)
we should explicitly check connectedIntegration in isExported function and return false if there is no connected integration Reminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job.
Please re-state the problem that we are trying to solve in this issue.
After exporting to All Data - report level, "Unapprove report" confirm modal shows up when unapproving the report.
"Heads up! This report has already been exported to ." is incomplete
What is the root cause of that problem?
We don't check if user connected integration before showing modal here
What changes do you think we should make in order to solve the problem?
The easiest way is update that condition to if (isExported && connectedIntegration) {
What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?
NA
What alternative solutions did you explore? (Optional)
Reminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job.
I don't try to post a duplicated version. When I post my proposal, his proposal looks like below picture and I see it is different with my proposal (diff in code changes and place to change). That's why I posted here. However, after the first proposal updated their solution (He didnt notice), I found somehow is 2 proposals are pretty the same. So I will let u decide, if u think my proposal is duplicated from beginning, I will remove it
Here is the first proposal's original version, it uses the function to get connectedIntegration while mine version doesn't use it. And the change scope my version is outside his proposal (This one looks like due to different code version in git)
@lorretheboy mind telling us what was different in your proposal that you think your proposal was not duplicated??
This issue was related to not having the check for connectedIntegration and I already mentioned that. I just make sure to keep the isExported check there while adding connectedIntegration check, in update you mentioned.
Please take a look:
Note: Before submitting a proposal on an issue, be sure to read any other existing proposals. ALL NEW PROPOSALS MUST BE DIFFERENT FROM EXISTING PROPOSALS. The difference should be important, meaningful or considerable.
@samranahm, Hello. In your solution I think you suggested to create connectedIntegration while in my suggestion and in @lorretheboy suggestion we were using existing variables. This was the diff I think.
Hi, I have mentioned here to compare your original proposal with my proposal. It is clearly different (I am not C+, so I don't check the details how u handle it but for the first glance, it is different both in places to change and how we change). Please note that I'm not reviewer, so I can't go to check every single proposal details implementation to view how many percent it is duplicated
Here is the comparision of our two proposals. Your first proposal is creating connectedIntegration while mine is not
.
.
.
.
So I will let u decide, if u think my proposal is duplicated from beginning, I will remove it
Lastly, I have also mentioned here. If C+ think it is really duplicated, then I'm happy to remove, I don't try to post the duplicated version
Please re-state the problem that we are trying to solve in this issue.
After exporting to All Data - report level, "Unapprove report" confirm modal shows up when unapproving the report.
"Heads up! This report has already been exported to ." is incomplete.
What is the root cause of that problem?
We only pass reportActions to check the isExported here, then we skip report?.isExportedToIntegration check because the report is undefined. When we export CSV, a report action exported to All Data - report level is returned and it's a EXPORTINTEGRATION. So the isExported function returns true, and the warning modal appears
// We consider any reports marked manually as exported to be exported, so we shortcut here.
if(getOriginalMessage(action)?.markedManually){
returntrue;
}
exportIntegrationActionsCount++;
What changes do you think we should make in order to solve the problem?
We can pass the expense report to isExportedUtils function here to also check the isExportedToIntegration if it exists. If we want to do that we need to ensure update isExportedToIntegration in the optimistic data when we export to an integration or manually export.
We should check the label/type in the original message of EXPORTINTEGRATION action to consider whether it's exported to integration or not when calculating exportIntegrationActionsCount here
// We consider any reports marked manually as exported to be exported, so we shortcut here.
if(getOriginalMessage(action)?.markedManually){
returntrue;
}
exportIntegrationActionsCount++;
OPTIONAL: We can also rename this function to isExportedToIntegration
What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?
Add a test case to isExported function with an exported to All Data - report level action and verify that this function returns false
What alternative solutions did you explore? (Optional)
NA
Reminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job.
I can't go to check every single proposal details implementation to view how many percent it is duplicated
@lorretheboy No one is 100% percent perfect and can't expect someone to be. But I believe that It does not took a lot of time to check what other developers has posted and is there any proposal with the same RCA you found. Even if there's is, It actually make us more confident that we found the correct RCA.
Next we need to make sure our solution does not contain the same logic or same approach others have already posted. No one can post the whole implementation in proposal but we get the complete idea what they are proposing. So we should make sure to post something different instead to altering and adjusting the already posted proposal to make yours look like different one.
changed the title [-][$250] Expense - After exporting to CSV, "Unapprove report" modal shows up when unapproving report[/-][+][Due for payment 2025-10-06] [$250] Expense - After exporting to CSV, "Unapprove report" modal shows up when unapproving report[/+]on Sep 29, 2025
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.2.19-3 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:
@dukenv0307@twisterdotcom 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]
[Contributor] If the regression was CRITICAL (e.g. interrupts a core flow) A discussion in #expensify-open-source has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner.
Link to discussion: N/A
[Contributor] If it was decided to create a regression test for the bug, please propose the regression test steps using the template below to ensure the same bug will not reach production again. Yes
Regression Test Proposal Template
[BugZero Assignee] Create a GH issue for creating/updating the regression test once above steps have been agreed upon.
Activity
melvin-bot commentedon Sep 6, 2025
Triggered auto assignment to @twisterdotcom (
Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.samranahm commentedon Sep 6, 2025
Proposal
Please re-state the problem that we are trying to solve in this issue.
Expense - After exporting to CSV, "Unapprove report" modal shows up when unapproving report
What is the root cause of that problem?
we are not checking for connected integration here
App/src/components/MoneyReportHeader.tsx
Lines 928 to 945 in 34c2f92
What changes do you think we should make in order to solve the problem?
we should check if we have connected integration before setting
UnapproveModalVisibletrue hereApp/src/components/MoneyReportHeader.tsx
Lines 928 to 945 in 34c2f92
What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?
N/A
What alternative solutions did you explore? (Optional)
we should explicitly check
connectedIntegrationinisExportedfunction and return false if there is no connected integrationReminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job.
aadil42 commentedon Sep 6, 2025
Proposal
Please re-state the problem that we are trying to solve in this issue.
"Unapprove report" modal shows up after unapproving the report even when no Accounting system was connected.
What is the root cause of that problem?
This is the root cause.
App/src/components/MoneyReportHeader.tsx
Line 663 in 34c2f92
We're only checking if the data was exported. We should also check if an Accounting system is setup.
What changes do you think we should make in order to solve the problem?
We should simply add for
integrationNameFromExportMessagea check in the existing if condition here.We already get
integrationNameFromExportMessagehere:App/src/components/MoneyReportHeader.tsx
Lines 236 to 237 in 34c2f92
App/src/components/MoneyReportHeader.tsx
Line 663 in 34c2f92
What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?
N/A
What alternative solutions did you explore? (Optional)
Or we can have the condition as:
lorretheboy commentedon Sep 6, 2025
Proposal
Please re-state the problem that we are trying to solve in this issue.
After exporting to All Data - report level, "Unapprove report" confirm modal shows up when unapproving the report.
"Heads up! This report has already been exported to ." is incomplete
What is the root cause of that problem?
We don't check if user connected integration before showing modal here
App/src/components/MoneyReportHeader.tsx
Line 951 in 5953b32
What changes do you think we should make in order to solve the problem?
The easiest way is update that condition to
if (isExported && connectedIntegration) {What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?
NA
What alternative solutions did you explore? (Optional)
Reminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job.
lorretheboy commentedon Sep 6, 2025
Note for C+ review here:
I don't try to post a duplicated version. When I post my proposal, his proposal looks like below picture and I see it is different with my proposal (diff in code changes and place to change). That's why I posted here. However, after the first proposal updated their solution (He didnt notice), I found somehow is 2 proposals are pretty the same. So I will let u decide, if u think my proposal is duplicated from beginning, I will remove it
Here is the first proposal's original version, it uses the function to get
connectedIntegrationwhile mine version doesn't use it. And the change scope my version is outside his proposal (This one looks like due to different code version in git)The first propoosal original version:

My proposal:

samranahm commentedon Sep 6, 2025
@lorretheboy mind telling us what was different in your proposal that you think your proposal was not duplicated??
This issue was related to not having the check for
connectedIntegrationand I already mentioned that. I just make sure to keep theisExportedcheck there while addingconnectedIntegrationcheck, in update you mentioned.Please take a look:
aadil42 commentedon Sep 6, 2025
@samranahm, Hello. In your solution I think you suggested to create
connectedIntegrationwhile in my suggestion and in @lorretheboy suggestion we were using existing variables. This was the diff I think.lorretheboy commentedon Sep 6, 2025
Hi, I have mentioned here to compare your original proposal with my proposal. It is clearly different (I am not C+, so I don't check the details how u handle it but for the first glance, it is different both in places to change and how we change). Please note that I'm not reviewer, so I can't go to check every single proposal details implementation to view how many percent it is duplicated
Here is the comparision of our two proposals. Your first proposal is creating connectedIntegration while mine is not
.
.
.
.
Lastly, I have also mentioned here. If C+ think it is really duplicated, then I'm happy to remove, I don't try to post the duplicated version
nkdengineer commentedon Sep 6, 2025
Proposal
Please re-state the problem that we are trying to solve in this issue.
After exporting to All Data - report level, "Unapprove report" confirm modal shows up when unapproving the report.
"Heads up! This report has already been exported to ." is incomplete.
What is the root cause of that problem?
We only pass
reportActionsto check theisExportedhere, then we skipreport?.isExportedToIntegrationcheck because thereportisundefined. When we export CSV, a report actionexported to All Data - report levelis returned and it's aEXPORTINTEGRATION. So theisExportedfunction returnstrue, and the warning modal appearsApp/src/components/MoneyReportHeader.tsx
Line 234 in 34c2f92
App/src/libs/ReportUtils.ts
Lines 11039 to 11060 in 34c2f92
What changes do you think we should make in order to solve the problem?
isExportedUtilsfunction here to also check theisExportedToIntegrationif it exists. If we want to do that we need to ensure updateisExportedToIntegrationin the optimistic data when we export to an integration or manually export.App/src/components/MoneyReportHeader.tsx
Line 234 in 34c2f92
label/typein the original message ofEXPORTINTEGRATIONaction to consider whether it's exported to integration or not when calculatingexportIntegrationActionsCounthereApp/src/libs/ReportUtils.ts
Lines 11039 to 11060 in 34c2f92
OPTIONAL: We can also rename this function to
isExportedToIntegrationWhat specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?
Add a test case to
isExportedfunction with anexported to All Data - report levelaction and verify that this function returnsfalseWhat alternative solutions did you explore? (Optional)
NA
Reminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job.
samranahm commentedon Sep 6, 2025
@lorretheboy No one is 100% percent perfect and can't expect someone to be. But I believe that It does not took a lot of time to check what other developers has posted and is there any proposal with the same RCA you found. Even if there's is, It actually make us more confident that we found the correct RCA.
Next we need to make sure our solution does not contain the same logic or same approach others have already posted. No one can post the whole implementation in proposal but we get the complete idea what they are proposing. So we should make sure to post something different instead to altering and adjusting the already posted proposal to make yours look like different one.
lorretheboy commentedon Sep 6, 2025
Btw I dont really agree that it is duplicated with your original version, thats why I left the comment for C+ decision
samranahm commentedon Sep 6, 2025
Let them handle that.
51 remaining items
[-][$250] Expense - After exporting to CSV, "Unapprove report" modal shows up when unapproving report[/-][+][Due for payment 2025-10-06] [$250] Expense - After exporting to CSV, "Unapprove report" modal shows up when unapproving report[/+]melvin-bot commentedon Sep 29, 2025
Reviewinglabel has been removed, please complete the "BugZero Checklist".melvin-bot commentedon Sep 29, 2025
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.2.19-3 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 2025-10-06. 🎊
For reference, here are some details about the assignees on this issue:
melvin-bot commentedon Sep 29, 2025
@dukenv0307 @twisterdotcom 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]
dukenv0307 commentedon Sep 30, 2025
BugZero Checklist:
Bug classification
Source of bug:
Where bug was reported:
Who reported the bug:
[Contributor] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake.
Link to comment: https://github.com/Expensify/App/pull/61704/files#r2390917533
[Contributor] If the regression was CRITICAL (e.g. interrupts a core flow) A discussion in #expensify-open-source has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner.
Link to discussion: N/A
[Contributor] If it was decided to create a regression test for the bug, please propose the regression test steps using the template below to ensure the same bug will not reach production again. Yes
[BugZero Assignee] Create a GH issue for creating/updating the regression test once above steps have been agreed upon.
Link to issue: https://github.com/Expensify/Expensify/issues/556068
Regression Test Proposal
Test:
Do we agree 👍 or 👎
twisterdotcom commentedon Oct 9, 2025
Payment Summary:
nkdengineer commentedon Oct 16, 2025
@twisterdotcom I will request payment via NewDot
trjExpensify commentedon Oct 17, 2025
approved $250 for @dukenv0307.
JmillsExpensify commentedon Nov 3, 2025
$250 approved for @nkdengineer