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
[HOLD for payment 2024-07-22] [HOLD for payment 2024-07-17] [$250] Able to save empty display first name #44167
Precondition: Have an existing Profile display name
Go to settings -> Profile
Click on display name
Remove the text in first and last name
Hit save
Expected Result:
We should not be able to save empty first name (This will be similar to the onboarding flow, we allow the user to keep last name empty but they have to fill the first name)
Actual Result:
Able to save empty display first name
Workaround:
unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Please re-state the problem that we are trying to solve in this issue.
Able to save name without first name
What is the root cause of that problem?
We do not validate whether the name is empty or not when we click save, we only check for special characters and word limit
This is why we do not get any error while saving empty name.
What changes do you think we should make in order to solve the problem?
We can add a validation check similar to the onboarding page which checks whether the name is empty and gives error if the first name is empty, we can apply similar logic here.
We should create a new error message here because the other one is used for onboarding flow/ or we can reuse the same variable.
Then we should add a validation to check for the empty first name and throw error accordingly:
We do not need to add a extra .replace(CONST.REGEX.ANY_SPACE, '') like we do in the onboarding flow, because extra whitespaces are trimmed by default
We can create a separate text as it won't be ideal to use from the onboarding flow as the current errors for the display name are set personalDetailsmessages
What alternative solutions did you explore? (Optional)
We can create a separate text as it won't be ideal to use from the onboarding flow as the current errors for the display name are set personalDetails messages
I would like the opinion of the internal engineer here if we should create a new text or reuse the same from onboarding flow, anyway NAB 👍
@bondydaa, please hold off on assigning. I am still confused why my proposal wasn't selected. The solution is straightforward, and my proposal includes all the necessary details. I am still waiting for a response from @allgandalf.
changed the title [-][HOLD for payment 2024-07-17] [$250] Able to save empty display first name[/-][+][HOLD for payment 2024-07-22] [HOLD for payment 2024-07-17] [$250] Able to save empty display first name[/+]on Jul 15, 2024
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.6-8 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:
BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
[@allgandalf] The PR that introduced the bug has been identified. Link to the PR:
[@allgandalf] 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:
[@allgandalf] A discussion in #expensify-bugs 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:
[@allgandalf] Determine if we should create a regression test for this bug.
[@allgandalf] If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again.
[@isabelastisser] Link the GH issue for creating/updating the regression test once above steps have been agreed upon:
A discussion in #expensify-bugs 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
If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again.
Regression Test Proposal
Precondition: Have an existing Profile display name
Go to settings -> Profile
Click on display name
Remove the text in first name.
Hit save
Verify that error occurs when saving empty First Name.
@isabelastisser , this is ready for payment, the payment date is wrong, idk why melvin is acting so weird lately, I notified about the deployment to production here, so the payment date was actually 15th, can you pay this out please, thanks
Activity
melvin-bot commentedon Jun 21, 2024
Triggered auto assignment to @isabelastisser (
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.Krishna2323 commentedon Jun 21, 2024
Proposal
Please re-state the problem that we are trying to solve in this issue.
Able to save empty display first name
What is the root cause of that problem?
We don't have a check for making the firstname required.
App/src/pages/settings/Profile/DisplayNamePage.tsx
Lines 48 to 56 in 7512346
What changes do you think we should make in order to solve the problem?
Add a check like we do in
BaseOnboardingPersonalDetails.App/src/pages/OnboardingPersonalDetails/BaseOnboardingPersonalDetails.tsx
Lines 97 to 100 in 7512346
What alternative solutions did you explore? (Optional)
allgandalf commentedon Jun 21, 2024
Note
@isabelastisser , can i be the C+ here as i reported this issue and already have context
eucool commentedon Jun 21, 2024
Proposal
Please re-state the problem that we are trying to solve in this issue.
Able to save name without first name
What is the root cause of that problem?
We do not validate whether the name is empty or not when we click save, we only check for special characters and word limit
This is why we do not get any error while saving empty name.
What changes do you think we should make in order to solve the problem?
We can add a validation check similar to the onboarding page which checks whether the name is empty and gives error if the first name is empty, we can apply similar logic here.
We should create a new error message here because the other one is used for onboarding flow/ or we can reuse the same variable.
Then we should add a validation to check for the empty first name and throw error accordingly:
.replace(CONST.REGEX.ANY_SPACE, '')like we do in the onboarding flow, because extra whitespaces are trimmed by defaultpersonalDetailsmessagesWhat alternative solutions did you explore? (Optional)
isabelastisser commentedon Jun 22, 2024
@allgandalf can you please review the proposals above? Thanks!
allgandalf commentedon Jun 22, 2024
@eucool's proposal looks good to me here.
I would like the opinion of the internal engineer here if we should create a new text or reuse the same from onboarding flow, anyway NAB 👍
🎀👀🎀 C+ reviewed
melvin-bot commentedon Jun 22, 2024
Triggered auto assignment to @bondydaa, see https://stackoverflow.com/c/expensify/questions/7972 for more details.
allgandalf commentedon Jun 22, 2024
@isabelastisser can you add an external tag here for the job to be created on upwork, thanks :)
Krishna2323 commentedon Jun 22, 2024
Hey @allgandalf, could you let me know if there's anything wrong with my proposal?
Krishna2323 commentedon Jun 24, 2024
@bondydaa, please hold off on assigning. I am still confused why my proposal wasn't selected. The solution is straightforward, and my proposal includes all the necessary details. I am still waiting for a response from @allgandalf.
29 remaining items
[-][HOLD for payment 2024-07-17] [$250] Able to save empty display first name[/-][+][HOLD for payment 2024-07-22] [HOLD for payment 2024-07-17] [$250] Able to save empty display first name[/+]melvin-bot commentedon Jul 15, 2024
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.6-8 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 2024-07-22. 🎊
For reference, here are some details about the assignees on this issue:
melvin-bot commentedon Jul 15, 2024
BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
allgandalf commentedon Jul 16, 2024
The PR that introduced the bug has been identified. Link to the PR: Update display name front-end validation to match back-end #14873 (this was a missed case and not really a bug from that PR)
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/14873/files#r1678876418
A discussion in #expensify-bugs 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
If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again.
Regression Test Proposal
Note: We are allowed to have last name as empty
Do we agree 👍 or 👎
allgandalf commentedon Jul 16, 2024
Note
@isabelastisser , this is ready for payment, the payment date is wrong, idk why melvin is acting so weird lately, I notified about the deployment to production here, so the payment date was actually 15th, can you pay this out please, thanks
isabelastisser commentedon Jul 16, 2024
Thanks for the heads up, @allgandalf!
@bondydaa, can you please review the regression test above? Thanks!
isabelastisser commentedon Jul 16, 2024
The payments were processed in Upwork!
bondydaa commentedon Jul 16, 2024
regression steps look good
eucool commentedon Jul 18, 2024
I can still see that the job is pending payment @isabelastisser , can you confirm once please
isabelastisser commentedon Jul 18, 2024
Hi @eucool, it was paid on July 16:
isabelastisser commentedon Jul 18, 2024
All set!