-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
[HOLD for payment 2023-06-07] [$1000] Center QR image turns into difference avatar for a moment after being removed. #19211
Comments
Triggered auto assignment to @kadiealexander ( |
Bug0 Triage Checklist (Main S/O)
|
ProposalPlease re-state the problem that we are trying to solve in this issue.Center QR image turns into difference avatar for a moment after being removed What is the root cause of that problem?When we delete user avatar, we set optimisticData of user's avatar to oldDot default avatar (e.i: https://d2k5nsl2zxldvw.cloudfront.net/images/avatars/avatar_4.png). App/src/libs/actions/PersonalDetails.js Line 376 in 2090c05
Later on, the API returns default avatar with newDot (e.i: https://d2k5nsl2zxldvw.cloudfront.net/images/avatars/default-avatar_4.png) In ShareCodePage, we're using this.props.currentUserPersonalDetails.avatar to generate QR code, which uses above value directly => it explains why we see the oldDot avatar in QR code for a moment then see newDot avatar. What changes do you think we should make in order to solve the problem?We can't reuse the util The function to get newDot default URL is almost same with oldDot. But instead of What alternative solutions did you explore? (Optional)Instead of use oldDot default avatar, we can use newDot default avatar for optimisticData, because later on, the API still return the newDot default avatar. So it doesn't make sense to use oldDot default avatar anymore => Write a new util ReportUtils.getNewDotDefaultAvatar same as oldDot, but return with prefix App/src/libs/actions/PersonalDetails.js Line 376 in 2090c05
|
Reproduced in Chrome: 2023-05-19_14-03-36.mp4 |
Job added to Upwork: https://www.upwork.com/jobs/~01e69cb0f1402572c0 |
Current assignee @kadiealexander is eligible for the External assigner, not assigning anyone new. |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @fedirjh ( |
Triggered auto assignment to @tgolen ( |
Hey @hoangzinh thanks for the proposal . I wonder if we can achieve the same result as the chat avatars , check my video below , the avatar in the chat doesn’t change to oldDot default avatar . Avatar.mov |
@fedirjh I thought about it too. For other place, we usually use this util to get avatar |
@hoangzinh QR code accept base64 strings , so we can convert the Svg to base64. Anyway I think we have a simpler option. @grgia Is there any specific reason that we keep using the oldDot default avatar ? Can we update Line 686 in 2090c05
Could be update to : return `${CONST.CLOUDFRONT_URL}/images/avatars/default-avatar_${loginHashBucket}.png`; |
I think we can go ahead and make that update. I don't think there is any reason to keep using the old avatar. |
The old avatar is required in order to update the avatar only on both Old and New Dot. On Old dot we do not use our new default avatar designs |
@grgia I think it makes sense if we store default avatar URL of oldDot in BE, so it works for both oldDot and newDot. But from what I observe: |
OK, what updates to the proposal need to be made? Is it just a matter of changing the reference in the optimistic data? |
The problem is in
we should be using |
We discussed that solution in #19211 (comment) , @hoangzinh, can we implement a new function similar to ReportUtils.getAvatar, but instead of returning an SVG component, it returns a URL? |
@fedirjh definitely we can. I have updated my proposal to reflect above thing. |
📣 @hoangzinh You have been assigned to this job by @kadiealexander! |
@tgolen the assigned engineer assigns in Github, that doesn't need to wait for me. I'll ensure the Upwork contracts get sent and everyone gets paid 😊 |
Cool, I didn't know about that. I'll try to remember it in the future. Thanks! |
Current assignee @kadiealexander is eligible for the External assigner, not assigning anyone new. |
Current assignee @fedirjh is eligible for the External assigner, not assigning anyone new. |
Triggered auto assignment to @danieldoglas ( |
Unfortunately, I need to reassign this due to going on extended leave. |
|
The solution for this issue has been 🚀 deployed to production 🚀 in version 1.3.20-5 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 2023-06-07. 🎊 After the hold period is over and BZ checklist items are completed, please complete any of the applicable payments for this issue, and check them off once done.
As a reminder, here are the bonuses/penalties that should be applied for any External 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:
|
Assigned - May 25th 2:50pm (GMT+12) - Thursday PR was merged within 3 business days, eligible for speed bonus. |
Contracts sent to all, @fedirjh please don't forget about the checklist! |
|
Thanks @fedirjh! Everyone is paid so I'm closing this out. Great work team! |
If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Action Performed:
Expected Result:
Center QR image should turn into default avatar.
Actual Result:
Center QR image turns into difference avatar for a moment after being removed.
Workaround:
Can the user still use Expensify without this being fixed? Have you informed them of the workaround?
Platforms:
Which of our officially supported platforms is this issue occurring on?
Version Number: 1.3.16.3
Reproducible in staging?: y
Reproducible in production?: y
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Notes/Photos/Videos: Any additional supporting documentation
Screen.Recording.2023-05-16.at.22.07.57.mov
Recording.646.mp4
Expensify/Expensify Issue URL:
Issue reported by: @hungvu193
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1684249640364239
View all open jobs on GitHub
Upwork Automation - Do Not Edit
The text was updated successfully, but these errors were encountered: