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 2026-04-28] [CMB] [$250] Notifications - A notification is received by submitter when admin edits expense description #87467
Version Number: 9.3.55-0 Reproducible in staging?: Yes Reproducible in production?: Yes If this was caught during regression testing, add the test name, ID and link from BrowserStack:#87034 Email or phone of affected tester (no customers):ibellicotest+2250@gmail.com Issue reported by: Applause Internal Team Bug source: Pull Request QA execution Device used: Motorola MotoG60 / Android 12 (Hybrid app) App Component: Notifications
Action Performed:
Prerequisite: Require two accounts in a policy, a submitter and a manager. (User A as submitter and User B as manager/owner)
Open the Expensify app as User A.
Open workspace chat where User B is manager.
Create a manual expense.
Open report of the just created expense and send a message.
Navigate away from report to "Inbox"
As User B, open the expense created by User A.
Tap on "Description" field, add a description and save.
As User A, note that a notification is received showing that manager just edited the description of the expense.
Expected Result:
Notifications shouldn´t be received for non-actionable actions on a report, such as the edition of description.
Actual Result:
Submitter of a workspace receives a notification after the manager edits the description of an expense.
Push notifications for expense modifications are controlled by a two-layer system:
Server-side (Web-Expensify/lib/MobilePushNotifications.php): Decides to send push notifications via Airship and populates actionableForAccountIDs in the MODIFIEDEXPENSE report action's originalMessage.
Client-side (src/libs/ReportActionsUtils.ts:1008-1033): The isActionable() function checks if the current user's accountID is in actionableForAccountIDs to decide whether to display the notification.
The bug is that the server includes the submitter's accountID in actionableForAccountIDs for all expense modifications, including non-actionable edits like description changes. Additionally, the client-side filter (shouldShowPushNotification.ts) only runs as a foreground display predicate (ForegroundNotifications/index.android.ts:6, index.ios.ts:17). When the app is backgrounded, the OS displays the push notification directly from Airship with no client-side filtering opportunity.
What changes do you think we should make in order to solve the problem?
The fix should be server-side in Web-Expensify/lib/MobilePushNotifications.php: when creating MODIFIEDEXPENSE report actions for non-financially-relevant modifications (description, category, tag, comment), the server should either:
Not include the submitter in actionableForAccountIDs, OR
Not send a push notification at all for these modification types
This is the only reliable fix because background push notifications bypass all client-side filtering.
What alternative solutions did you explore?
Client-side filtering was considered but is insufficient: shouldShowPushNotification.ts is registered as a foreground display predicate on both Android and iOS. When the app is backgrounded (the common case for receiving notifications), the OS shows whatever the server sends without consulting the client. The isActionable() check at ReportActionsUtils.ts:1028-1032 would correctly suppress these notifications, but only when the foreground predicate is actually invoked.
Supporting evidence
isActionable() at src/libs/ReportActionsUtils.ts:1008-1033 does NOT include MODIFIED_EXPENSE in actionableTypes, falling through to actionableForAccountIDs check
shouldShowReportActionNotification() at src/libs/actions/Report/index.ts:4107-4110 gates on isActionable()
Foreground-only registration at ForegroundNotifications/index.android.ts:6 and index.ios.ts:17
Local notifications are no-ops on native mobile (Notification/LocalNotification/index.native.ts)
Test at tests/unit/showReportActionNotificationTest.ts:154-170 confirms: without actionableForAccountIDs, MODIFIEDEXPENSE notifications are suppressed
Next Steps for Contributor+ team: Reply with @MelvinBot implement this to create a draft PR, @MelvinBot <your feedback> to refine this analysis, or explain why you are rejecting Melvin's proposal.
Please re-state the problem that we are trying to solve in this issue.
When a workspace admin edits a description (or other non-actionable field) on an expense created by a submitter, the submitter receives a push notification on mobile even though the change requires no action from them.
What is the root cause of that problem?
PR #87034 added an isActionable guard in shouldShowReportActionNotification so that non-actionable report actions (like MODIFIED_EXPENSE) no longer trigger local or foreground push notifications. However, that guard only applies when data.type is not 'transaction'. In shouldShowPushNotification.ts, there is a hard-coded early return that unconditionally shows any notification whose payload type is 'transaction', before the isActionable check is ever reached.
Editing an expense description modifies a transaction field, so the server sends a push notification with type === 'transaction'. The client receives this and immediately returns shouldShow = true on line 32 without consulting shouldShowReportActionNotification at all. The MODIFIED_EXPENSE report action that accompanies the update is never examined.
What changes do you think we should make in order to solve the problem?
The 'transaction' branch in shouldShowPushNotification should not blindly return true. Instead, it should apply the same shouldShowReportActionNotification check used for other notification types, extracting the associated report action from onyxData. If no report action is present in the payload (stripped payload), the notification should still be shown since we cannot determine it is non-actionable — this preserves the existing safe-default behavior for payloads that lack action data.
let shouldShow = false;
- if (data.type === 'transaction') {- shouldShow = true;- } else {- const reportAction = ReportActionUtils.getLatestReportActionFromOnyxData(data.onyxData ?? null);- shouldShow = Report.shouldShowReportActionNotification(String(data.reportID), currentUserAccountID, reportAction, true);- }+ const reportAction = ReportActionUtils.getLatestReportActionFromOnyxData(data.onyxData ?? null);+ if (data.type === 'transaction' && !reportAction) {+ // Payload was stripped — we cannot determine actionability, so show the notification.+ shouldShow = true;+ } else {+ shouldShow = Report.shouldShowReportActionNotification(String(data.reportID), currentUserAccountID, reportAction, true);+ }
With this change, transaction-type notifications that carry a MODIFIED_EXPENSE action in their onyxData will go through shouldShowReportActionNotification → isActionable → false → notification suppressed. Transaction-type notifications with stripped payloads (no action available) still show as before, preserving the safe fallback. All other notification types are unaffected.
What alternative solutions did you explore? (Optional)
changed the title [-]Notifications - A notification is received by submitter when admin edits expense description[/-][+][$250] Notifications - A notification is received by submitter when admin edits expense description[/+]on Apr 9, 2026
Please re-state the problem that we are trying to solve in this issue.
When an admin edits only the description of an expense, the submitter receives a notification even though this change requires no action from them.
What is the root cause of that problem?
shouldShowReportActionNotification() in Report has no filtering for MODIFIED_EXPENSE actions. It checks whether the action is deleted, whether the actor is the current user, whether the report is currently visible, etc. — but it never inspects what was modified. So a description-only edit passes every gate and triggers a notification to the submitter via both the foreground push filter in shouldShowPushNotification and the Onyx-driven path in triggerNotifications.
What changes do you think we should make in order to solve the problem?
In shouldShowReportActionNotification() in Report, after the existing whisper check, add a guard that suppresses notifications for description-only expense modifications:
This checks the OriginalMessageModifiedExpense fields (defined in OriginalMessage) to confirm only the comment/description changed, with no financially relevant modifications.
What alternative solutions did you explore?
MelvinBot's proposal suggests this must be fixed exclusively on the API side, arguing that client-side filtering cannot suppress background push notifications. That analysis is partially correct for OS-level push delivery, but it overlooks the Onyx-driven notification path: triggerNotifications() in User calls showReportActionNotification() which calls shouldShowReportActionNotification() — this path runs regardless of app state and is where the client controls notification display. Fixing shouldShowReportActionNotification provides concrete, immediately deployable coverage in the App repo with a targeted field-level check, rather than a broad directive to change API behavior.
This happens because description edits are created as MODIFIED_EXPENSE actions, and notification gating treats them as actionable when actionableForAccountIDs includes the submitter. There is no special check to suppress notifications for description-only expense edits (which are non-actionable for this flow).
functionisModifiedExpenseAction(reportAction: OnyxInputOrEntry<ReportAction>): reportAction is ReportAction<typeofCONST.REPORT.ACTIONS.TYPE.MODIFIED_EXPENSE>{
This keeps notifications for actionable expense changes (amount/category/tag/etc.) but suppresses notifications for non-actionable description-only edits.
⚠️@abbasifaizan70 Your proposal is a duplicate of an already existing proposal and has been automatically withdrawn to prevent spam. Please review the existing proposals before submitting a new one.
changed the title [-][CMB] [$250] Notifications - A notification is received by submitter when admin edits expense description[/-][+][Due for payment 2026-04-28] [CMB] [$250] Notifications - A notification is received by submitter when admin edits expense description[/+]on Apr 21, 2026
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.3.60-22 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:
@bernhardoj 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]
Activity
MelvinBot commentedon Apr 9, 2026
Proposal
What is the root cause of that problem?
Push notifications for expense modifications are controlled by a two-layer system:
Web-Expensify/lib/MobilePushNotifications.php): Decides to send push notifications via Airship and populatesactionableForAccountIDsin theMODIFIEDEXPENSEreport action'soriginalMessage.src/libs/ReportActionsUtils.ts:1008-1033): TheisActionable()function checks if the current user's accountID is inactionableForAccountIDsto decide whether to display the notification.The bug is that the server includes the submitter's accountID in
actionableForAccountIDsfor all expense modifications, including non-actionable edits like description changes. Additionally, the client-side filter (shouldShowPushNotification.ts) only runs as a foreground display predicate (ForegroundNotifications/index.android.ts:6,index.ios.ts:17). When the app is backgrounded, the OS displays the push notification directly from Airship with no client-side filtering opportunity.What changes do you think we should make in order to solve the problem?
The fix should be server-side in
Web-Expensify/lib/MobilePushNotifications.php: when creatingMODIFIEDEXPENSEreport actions for non-financially-relevant modifications (description, category, tag, comment), the server should either:actionableForAccountIDs, ORThis is the only reliable fix because background push notifications bypass all client-side filtering.
What alternative solutions did you explore?
Client-side filtering was considered but is insufficient:
shouldShowPushNotification.tsis registered as a foreground display predicate on both Android and iOS. When the app is backgrounded (the common case for receiving notifications), the OS shows whatever the server sends without consulting the client. TheisActionable()check atReportActionsUtils.ts:1028-1032would correctly suppress these notifications, but only when the foreground predicate is actually invoked.Supporting evidence
isActionable()atsrc/libs/ReportActionsUtils.ts:1008-1033does NOT includeMODIFIED_EXPENSEinactionableTypes, falling through toactionableForAccountIDscheckshouldShowReportActionNotification()atsrc/libs/actions/Report/index.ts:4107-4110gates onisActionable()ForegroundNotifications/index.android.ts:6andindex.ios.ts:17Notification/LocalNotification/index.native.ts)tests/unit/showReportActionNotificationTest.ts:154-170confirms: withoutactionableForAccountIDs, MODIFIEDEXPENSE notifications are suppressedNext Steps for Contributor+ team: Reply with
@MelvinBot implement thisto create a draft PR,@MelvinBot <your feedback>to refine this analysis, or explain why you are rejecting Melvin's proposal.melvin-bot commentedon Apr 9, 2026
Triggered auto assignment to Contributor-plus team member for initial proposal review - @bernhardoj (
External)MobileMage commentedon Apr 9, 2026
Proposal
Please re-state the problem that we are trying to solve in this issue.
When a workspace admin edits a description (or other non-actionable field) on an expense created by a submitter, the submitter receives a push notification on mobile even though the change requires no action from them.
What is the root cause of that problem?
PR #87034 added an
isActionableguard inshouldShowReportActionNotificationso that non-actionable report actions (likeMODIFIED_EXPENSE) no longer trigger local or foreground push notifications. However, that guard only applies whendata.typeis not'transaction'. InshouldShowPushNotification.ts, there is a hard-coded early return that unconditionally shows any notification whose payload type is'transaction', before theisActionablecheck is ever reached.Editing an expense description modifies a transaction field, so the server sends a push notification with
type === 'transaction'. The client receives this and immediately returnsshouldShow = trueon line 32 without consultingshouldShowReportActionNotificationat all. TheMODIFIED_EXPENSEreport action that accompanies the update is never examined.App/src/libs/Notification/PushNotification/shouldShowPushNotification.ts
Lines 30 to 36 in caae603
What changes do you think we should make in order to solve the problem?
The
'transaction'branch inshouldShowPushNotificationshould not blindly returntrue. Instead, it should apply the sameshouldShowReportActionNotificationcheck used for other notification types, extracting the associated report action fromonyxData. If no report action is present in the payload (stripped payload), the notification should still be shown since we cannot determine it is non-actionable — this preserves the existing safe-default behavior for payloads that lack action data.App/src/libs/Notification/PushNotification/shouldShowPushNotification.ts
Lines 1 to 40 in caae603
With this change, transaction-type notifications that carry a
MODIFIED_EXPENSEaction in theironyxDatawill go throughshouldShowReportActionNotification→isActionable→false→ notification suppressed. Transaction-type notifications with stripped payloads (no action available) still show as before, preserving the safe fallback. All other notification types are unaffected.What alternative solutions did you explore? (Optional)
N/A
[-]Notifications - A notification is received by submitter when admin edits expense description[/-][+][$250] Notifications - A notification is received by submitter when admin edits expense description[/+]melvin-bot commentedon Apr 9, 2026
Job added to Upwork: https://www.upwork.com/jobs/~022042163892991660040
twilight2294 commentedon Apr 9, 2026
Proposal
Please re-state the problem that we are trying to solve in this issue.
When an admin edits only the description of an expense, the submitter receives a notification even though this change requires no action from them.
What is the root cause of that problem?
shouldShowReportActionNotification()in Report has no filtering forMODIFIED_EXPENSEactions. It checks whether the action is deleted, whether the actor is the current user, whether the report is currently visible, etc. — but it never inspects what was modified. So a description-only edit passes every gate and triggers a notification to the submitter via both the foreground push filter in shouldShowPushNotification and the Onyx-driven path in triggerNotifications.What changes do you think we should make in order to solve the problem?
In
shouldShowReportActionNotification()in Report, after the existing whisper check, add a guard that suppresses notifications for description-only expense modifications:This checks the
OriginalMessageModifiedExpensefields (defined in OriginalMessage) to confirm only the comment/description changed, with no financially relevant modifications.What alternative solutions did you explore?
MelvinBot's proposal suggests this must be fixed exclusively on the API side, arguing that client-side filtering cannot suppress background push notifications. That analysis is partially correct for OS-level push delivery, but it overlooks the Onyx-driven notification path:
triggerNotifications()in User callsshowReportActionNotification()which callsshouldShowReportActionNotification()— this path runs regardless of app state and is where the client controls notification display. FixingshouldShowReportActionNotificationprovides concrete, immediately deployable coverage in the App repo with a targeted field-level check, rather than a broad directive to change API behavior.abbasifaizan70 commentedon Apr 9, 2026
Proposal
What is the root cause of that problem?
This happens because description edits are created as
MODIFIED_EXPENSEactions, and notification gating treats them as actionable whenactionableForAccountIDsincludes the submitter. There is no special check to suppress notifications for description-only expense edits (which are non-actionable for this flow).App/src/libs/ReportUtils.ts
Lines 5591 to 5605 in 441332c
App/src/libs/actions/Report/index.ts
Lines 4045 to 4112 in 441332c
App/src/libs/ReportActionsUtils.ts
Lines 1008 to 1033 in 441332c
So a manager’s description-only edit can still pass notification checks and notify the submitter.
What changes do you think we should make in order to solve the problem?
App/src/libs/actions/Report/index.ts
Lines 4045 to 4112 in 441332c
App/src/libs/ReportActionsUtils.ts
Lines 378 to 380 in 441332c
This keeps notifications for actionable expense changes (amount/category/tag/etc.) but suppresses notifications for non-actionable description-only edits.
github-actions commentedon Apr 9, 2026
Ltbltbltbltb commentedon Apr 9, 2026
🚫 Duplicated proposal withdrawn by 🤖 ProposalPolice.
14 remaining items
s77rt commentedon Apr 14, 2026
Auth PR is merged. Waiting for deploy to unhold App PR.
melvin-bot commentedon Apr 17, 2026
@s77rt Whoops! This issue is 2 days overdue. Let's get this updated quick!
s77rt commentedon Apr 17, 2026
Waiting for PR to hit production
[-][CMB] [$250] Notifications - A notification is received by submitter when admin edits expense description[/-][+][Due for payment 2026-04-28] [CMB] [$250] Notifications - A notification is received by submitter when admin edits expense description[/+]melvin-bot commentedon Apr 21, 2026
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.3.60-22 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 2026-04-28. 🎊
For reference, here are some details about the assignees on this issue:
melvin-bot commentedon Apr 21, 2026
@bernhardoj 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]
melvin-bot commentedon Apr 21, 2026
@bernhardoj Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!
s77rt commentedon Apr 21, 2026
This is done and I think no payment is due here. Closing!