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-09-04] [$250] Expensify Card - Smart limit is missing in the list when it is the selected limit type #66844
Awaiting PaymentAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.DailyKSv2ExternalAdded to denote the issue can be worked on by a contributorWaiting for copyUser facing verbiage needs polishing
The problem is you're should not have been able to turn off Approvals when an Expensify card has SmartLimit. But in this case, the user works around by closing the issue new card flow after selecting the limit type, turn off Approvals first then resume the limit value step.
What changes do you think we should make in order to solve the problem?
We have several approaches regarding this:
Show an error and disallow issuing the card in confirmation step if selected SmartLimit but Approvals is disabled
Show the selected limit type as selected with checkmark but disabled (gray-out) in limit type editor page
Clear the issueNewCard Onyx data whenever the issue new card flow RHP is dismissed
For (1):
Disable the submit button here when Approvals are disabled and data?.limitType is SmartLimit. And display an explanative error message here if so. It requires the user to update limit type before proceeding.
Return a cleanup function the clearIssueNewCardFlow in this effect.
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)
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.
changed the title [-]Expensify Card - Smart limit is missing in the list when it is the selected limit type[/-][+][$250] Expensify Card - Smart limit is missing in the list when it is the selected limit type[/+]on Jul 22, 2025
changed the title [-][$250] Expensify Card - Smart limit is missing in the list when it is the selected limit type[/-][+][Due for payment 2025-09-04] [$250] Expensify Card - Smart limit is missing in the list when it is the selected limit type[/+]on Aug 28, 2025
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.1.99-11 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:
@ahmedGaber93@sakluger 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.
[BugZero Assignee] Create a GH issue for creating/updating the regression test once above steps have been agreed upon.
Link to issue:
Regression Test Proposal
Precondition:
Workspace is set up with Expensify card feature.
Workspace has Approval workflow enabled
Test:
Go to workspace settings > Expensify Card > Issue card.
Select user > Next.
Select any card type > Next.
On Limit type page, select Smart limit > Next.
Proceed to limit input page.
Close the RHP.
Web: click the backdrop
Mobile apps: reopen the app
mWeb: navigate directly to the home page via the browser URL
Go to Workflows.
Disable Add approvals.
Go back to Expensify Card.
Proceed to confirmation step
Verify "Issue card" button is disabled and an error shows "'Please enable approvals in Workflows > Add approvals before setting up smart limits" ("Workflows > Add approvals" part is bolded)
Awaiting PaymentAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.DailyKSv2ExternalAdded to denote the issue can be worked on by a contributorWaiting for copyUser facing verbiage needs polishing
Activity
melvin-bot commentedon Jul 22, 2025
Triggered auto assignment to @sakluger (
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.mkzie2 commentedon Jul 22, 2025
Proposal
Please re-state the problem that we are trying to solve in this issue.
In Step 15, Smart limit is missing in the list when it is the selected option.
What is the root cause of that problem?
In card limit type editor page, we only show the Smart Limit option if Approvals is enabled in that workspace:
App/src/pages/workspace/expensifyCard/WorkspaceEditCardLimitTypePage.tsx
Lines 121 to 123 in 1aa5d22
The problem is you're should not have been able to turn off Approvals when an Expensify card has SmartLimit. But in this case, the user works around by closing the issue new card flow after selecting the limit type, turn off Approvals first then resume the limit value step.
What changes do you think we should make in order to solve the problem?
We have several approaches regarding this:
issueNewCardOnyx data whenever the issue new card flow RHP is dismissedFor (1):
Disable the submit button here when Approvals are disabled and
data?.limitTypeis SmartLimit. And display an explanative error message here if so. It requires the user to update limit type before proceeding.For (2):
Update this line:
App/src/pages/workspace/expensifyCard/WorkspaceEditCardLimitTypePage.tsx
Line 121 in 1aa5d22
to:
And set the option's
isDisabled: !areApprovalsConfigured.Same for
FIXEDoption:App/src/pages/workspace/expensifyCard/WorkspaceEditCardLimitTypePage.tsx
Line 140 in 1aa5d22
For (3):
Return a cleanup function the
clearIssueNewCardFlowin this effect.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)
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.
melvin-bot commentedon Jul 22, 2025
Job added to Upwork: https://www.upwork.com/jobs/~021947709516358065429
[-]Expensify Card - Smart limit is missing in the list when it is the selected limit type[/-][+][$250] Expensify Card - Smart limit is missing in the list when it is the selected limit type[/+]melvin-bot commentedon Jul 22, 2025
Triggered auto assignment to Contributor-plus team member for initial proposal review - @ahmedGaber93 (
External)sakluger commentedon Jul 25, 2025
Hey @ahmedGaber93, could you please review the proposal above?
62 remaining items
[-][$250] Expensify Card - Smart limit is missing in the list when it is the selected limit type[/-][+][Due for payment 2025-09-04] [$250] Expensify Card - Smart limit is missing in the list when it is the selected limit type[/+]melvin-bot commentedon Aug 28, 2025
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.1.99-11 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-09-04. 🎊
For reference, here are some details about the assignees on this issue:
melvin-bot commentedon Aug 28, 2025
@ahmedGaber93 @sakluger 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]
sakluger commentedon Sep 4, 2025
Hey @ahmedGaber93, could you please complete the BZ checklist for this one?
sakluger commentedon Sep 4, 2025
Payment Summary
Contributor: @mkzie2 $250 via Upwork
Contributor+: @ahmedGaber93 $250 via Newdot:
HOLD pending BZ checklistahmedGaber93 commentedon Sep 6, 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/44741/files#r2328022631
[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.
[BugZero Assignee] Create a GH issue for creating/updating the regression test once above steps have been agreed upon.
Link to issue:
Regression Test Proposal
Precondition:
Test:
Do we agree 👍 or 👎
ahmedGaber93 commentedon Sep 6, 2025
@sakluger Checklist have completed. Sorry for the delay 🙏.
sakluger commentedon Sep 8, 2025
Thank you! Please use the payment summary above to request payment.
trjExpensify commentedon Nov 5, 2025
approved $250 for @ahmedGaber93.