-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[$250] Three QA guides in mention suggestion list after onboarding with Manage my team's expenses #54563
Comments
Triggered auto assignment to @bfitzexpensify ( |
Not a regression of PR #54147 as the issue is present on production as well and the PR was only deployed on staging, which proves that the issue was present before the PR changes. iOS: mWeb Chrome
We simply did not consider removing the duplicated entries from the mentions list as that wasn't part of the other issue's scope nor mentioned anywhere in the other issue's testing steps / actual behaviour. |
ProposalPlease re-state the problem that we are trying to solve in this issueDuplicated QA guide entries in mention suggestion list after onboarding with Manage my team's expenses. What is the root cause of that problem?Sometimes there's two QA guide entries in the member list after onboarding flow with Manage my team's expenses choice which seems to come from BE. Real example of array with duplicated entries[
{
"text": "[email protected]",
"alternateText": "[email protected]",
"keyForList": "14365522",
"isSelected": false,
"isDisabled": false,
"accountID": 14365522,
"login": "[email protected]",
"icons": [
{
"source": "https://d2k5nsl2zxldvw.cloudfront.net/images/avatars/default-avatar_11.png",
"type": "avatar",
"name": "[email protected]",
"id": 14365522
}
],
"reportID": ""
},
{
"text": "[email protected]",
"alternateText": "[email protected]",
"keyForList": "714749267",
"isSelected": false,
"isDisabled": false,
"accountID": 714749267,
"login": "[email protected]",
"icons": [
{
"source": "ƒ SvgFallbackAvatar(props)",
"type": "avatar",
"name": "[email protected]",
"id": 714749267
}
],
"reportID": ""
}
] Since we don't have bandwith to investigate this on BE side as stated in this comment, we should move forward with a FE fix which simply filters out duplicated values based on Similar to issue #53579 where I proposed the fix and implemented it, the mention suggestion list does not have any logic to handle duplicates in this filtering block: App/src/pages/home/report/ReportActionCompose/SuggestionMention.tsx Lines 283 to 306 in 918488a
which is separate from Note Note for reviewerIn order for the issue to be reproduced on DEV and subsequently be able to verify and review whether the fix works, it is necessary that Use Staging Server is set to ON in Onyx storage before creating the new account (random email without +) because when we create the workspace via onboarding flow, if we're not on staging server we won't be assigned the To do this we can add What changes do you think we should make in order to solve the problem?Same as the fix implemented in PR #54147, add the following logic to const filteredPersonalDetails = Object.values(personalDetailsParam ?? {}).filter((detail, index, array) => { // <- access `index` and `array` of filter method
// ... existing logic
// on staging server, in specific cases (see issue) BE returns duplicated personalDetails entries with the same login which we need to filter out
return array.findIndex((i) => i?.login === detail?.login) === index;
// return true; <- replaced by the line above
}) as Array<PersonalDetails & {weight: number}>; this will filter out duplicated entries that have the same What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?We can add a test in Result video (before / after)MacOS: Chrome
|
Yah, I think it's not the regression from #54147, in this PR, we're trying to fix the duplicated item in as many places as possible. But there are too many places that use |
Not really, I think there are different places in the app where personal details are used and is not always centralized like we had for the recent PR in the utils file. My proposal above suggests to fix the issue where it occurs, since the case of suggestions is isolated to 1 component. |
@bfitzexpensify I can help take this issue as C+ since I reviewed a similar issue like this before |
@bfitzexpensify Should we add |
Job added to Upwork: https://www.upwork.com/jobs/~021873744853399955342 |
Good catch - added |
Current assignee @dukenv0307 is eligible for the External assigner, not assigning anyone new. |
I tried to find other places that use personal details to see if this issue happened, but it seems like most of them are handled at #54147. I think we should go with @ikevin127's proposal to fix the issue in suggestion list. 🎀👀🎀 C+ reviewed |
Triggered auto assignment to @MarioExpensify, see https://stackoverflow.com/c/expensify/questions/7972 for more details. |
Proposal for Fixing Issue issue #54563ProblemWhen typing Root Cause
Proposed SolutionBackend Changes:
Frontend Changes:
Testing Scenarios
Alternative Solutions
Why This Solution?
|
📣 @POPE001! 📣
|
Contributor details |
✅ Contributor details stored successfully. Thank you for contributing to Expensify! |
Nice, thanks @dukenv0307, let's move forward with @ikevin127 proposal! |
📣 @ikevin127 🎉 An offer has been automatically sent to your Upwork account for the Contributor role 🎉 Thanks for contributing to the Expensify app! Offer link |
Will open the PR in a few hours, thanks! |
@ikevin127 any updates? |
@dukenv0307 Sorry, this one fell off my radar, let me open the PR now since I already tested it and have the videos. |
@ikevin127 Thank you |
@dukenv0307 PR #54805 is ready for review! 🚀 Thank you for the reminder! |
If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!
Version Number: 9.0.78-2
Reproducible in staging?: Yes
Reproducible in production?: Yes
If this was caught on HybridApp, is this reproducible on New Expensify Standalone?: Yes
If this was caught during regression testing, add the test name, ID and link from TestRail: #54147
Email or phone of affected tester (no customers): [email protected]
Issue reported by: Applause Internal Team
Device used: Mac 15.0 / Chrome
App Component: Other
Action Performed:
Expected Result:
There will be only one QA guide contact.
Actual Result:
There are three QA guide contacts in the mentioned suggestion list.
Workaround:
Unknown
Platforms:
Screenshots/Videos
Bug6702020_1735119636515.20241225_173701.mp4
View all open jobs on GitHub
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @Issue Owner
Current Issue Owner: @MarioExpensifyThe text was updated successfully, but these errors were encountered: