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-03-27] Report fields - App crashes when field type “Text” is selected #58135
Version Number: v9.1.11-1 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:https://expensify.testrail.io/index.php?/tests/view/5715253 Email or phone of affected tester (no customers):sustinov@applausemail.com Issue reported by: Applause Internal Team Device used: Macbook/15.3/Chrome, OnePlus 9 PRO/Android 14/Chrome, iPhone 12 PRO/iOS 18.3.1 App Component: Workspace Settings
Action Performed:
Open new expensify app
Log in with a new HT account
Create a new WS
Navigate to the WS settings
Navigate to More features
Enable Report fields
Navigate to Report fields
Click on the “Add field” button
Select in RHP Type -> Text
Expected Result:
The application should not crash when the “Text” field type is selected
What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?
We can simulate user click and verify the screen is rendered properly with type field is displayed correctly
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.
⚠️ Thanks for your proposal. Please update it to follow the proposal template, as proposals are only reviewed if they follow that format (note the mandatory sections).
@paultsimura@mountiny I can run the basic fix for this right now. However, this should be investigated more deeply since we always initialize the value as an empty string for input.
changed the title [-]Report fields - App crashes when field type “Text” is selected[/-][+][Due for payment 2025-03-27] Report fields - App crashes when field type “Text” is selected[/+]on Mar 20, 2025
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.1.15-9 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:
@shubham1206agra@NicMendonca@shubham1206agra 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.
Activity
melvin-bot commentedon Mar 11, 2025
Triggered auto assignment to @NicMendonca (
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.daledah commentedon Mar 11, 2025
🚨 Edited by proposal-police: This proposal was edited at 2025-03-11 02:12:23 UTC.
Proposal
Please re-state the problem that we are trying to solve in this issue.
App crashes when field type “Text” is selected
What is the root cause of that problem?
When user first select type Text,
formInitialValueis undefined, becauseinitialValueinput is not shown yet:App/src/pages/workspace/reportFields/CreateReportFieldsPage.tsx
Lines 169 to 181 in ef00a61
So the condition here will crash app because
undefineddoesn't havelengthApp/src/pages/workspace/reportFields/CreateReportFieldsPage.tsx
Line 84 in ef00a61
What changes do you think we should make in order to solve the problem?
Add condition to check if
formInitialValueis truthyApp/src/pages/workspace/reportFields/CreateReportFieldsPage.tsx
Line 84 in ef00a61
What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?
We can simulate user click and verify the screen is rendered properly with type field is displayed correctly
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.
github-actions commentedon Mar 11, 2025
layacat commentedon Mar 11, 2025
regression from #56588
NicMendonca commentedon Mar 11, 2025
@paultsimura @slafortune @mountiny can you confirm? ^^ This would be the issue where the regression came from? #56003
paultsimura commentedon Mar 11, 2025
Looks like it is.
@shubham1206agra please take a look
shubham1206agra commentedon Mar 11, 2025
@paultsimura @mountiny I can run the basic fix for this right now. However, this should be investigated more deeply since we always initialize the value as an empty string for input.
daledah commentedon Mar 13, 2025
@shubham1206agra In this case the input doesn't even existed yet in the component tree so there's no initial value.
mountiny commentedon Mar 13, 2025
@shubham1206agra can you please prioritize this fix?
6 remaining items
[-]Report fields - App crashes when field type “Text” is selected[/-][+][Due for payment 2025-03-27] Report fields - App crashes when field type “Text” is selected[/+]melvin-bot commentedon Mar 20, 2025
Reviewinglabel has been removed, please complete the "BugZero Checklist".melvin-bot commentedon Mar 20, 2025
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.1.15-9 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-03-27. 🎊
For reference, here are some details about the assignees on this issue:
melvin-bot commentedon Mar 20, 2025
@shubham1206agra @NicMendonca @shubham1206agra 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]
slafortune commentedon Mar 21, 2025
@NicMendonca I can take care of the payment here - #56003
shubham1206agra commentedon Mar 22, 2025
@slafortune No payment required here.
mountiny commentedon Mar 24, 2025
@paultsimura @shubham1206agra coul dyou just please complete the checklist and we can close this. Thanks!
paultsimura commentedon Mar 24, 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/56588/files#r2010062723
[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:
NicMendonca commentedon Mar 26, 2025
@paultsimura do we need a regression test?
mountiny commentedon Mar 26, 2025
I dont think we need a specific regression test for this one