-
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
[$500] Chat - After selecting "here" from suggestion list, the suggestion box is opened #32280
Comments
Triggered auto assignment to @sakluger ( |
Bug0 Triage Checklist (Main S/O)
|
ProposalPlease re-state the problem that we are trying to solve in this issue.When entering What is the root cause of that problem?If this is not an expected behavior – it looks like a regression from #30217 What changes do you think we should make in order to solve the problem?To solve it, we should skip the multi-word calculation in case the first word is } else if (secondToLastWord && secondToLastWord !== "@here" && secondToLastWord.startsWith('@') && secondToLastWord.length > 1) {
What alternative solutions did you explore? (Optional) |
@graylewis @allroundexperts, the above proposal says that your PR for #30217 may have caused this regression, do you think that's right? @situchan this also seems related (or at least very similar) to the issue you just fixed for #32214, and your PR there didn't fix this one. Are they related, or just similar? |
Seems like this is another edge case where user display name includes "here" |
Hm... But the root cause is the same as previous bug, right? |
yes, both issues are regression from #30217 |
The first issue is definitely caused by my solution (#32214) (to me this seems more like a UX nit-pick than a bug. If you start typing after selecting the mention the suggestion goes away). However this issue seems like either an edge case that wasn't considered in the solution for #32214, or just a duplicate of that issue. |
Ideally, #31435 should have been reverted at the time of deploy blocker. |
It's a weird situation tbh. @situchan Can you maybe raise a PR for this since you applied the previous patch as well? |
yes will do if @graylewis doesn't want to. |
Another example of this bug: https://expensify.slack.com/archives/C049HHMV9SM/p1701454107049459 |
Just to confirm, should this have been fixed in any of the past PRs? Or is this a separate edge case? |
I think it should have been fixed in the past PRs. @graylewis can you please let us know if you'd have time for creating a fix? If no, then that is fine as well and @situchan can take over. |
I can pick up the ticket but I can't work on it until the weekend @situchan @allroundexperts |
That's fine, we can wait a few days. @graylewis please create a PR as soon as you have a chance, thanks! |
@sakluger @allroundexperts Unfortunately things came up the past couple days. Going to try to get a PR in this week. Sorry for the delay |
@graylewis it's important that we prioritize fixing regressions, can you please prioritize this one today? |
@sakluger I'm not being compensated for this work so I simply can't prioritize it over my job and personal obligations. It's also already 7PM here in the Netherlands. I'll do my best to get this done tomorrow. I was docked $250 for this UX nitpick so being asked to make the solution for free and then being put under time pressure for free work feels inappropriate. |
Trying to build a fix for this issue now but I'm unable to reproduce. Was a patch for this already pushed? Also tested this on Android chrome with the same results @sakluger @allroundexperts @situchan Screen.Recording.2023-12-13.at.10.55.40.AM.mov |
Triggered auto assignment to @arosiclair, see https://stackoverflow.com/c/expensify/questions/7972 for more details. |
I'm thinking the root problem is that we are still showing suggestions after a suggestion has already been selected. I also think this would be an issue for any matching prefix not just "here". For example this would also reproduce the issue:
So this
sounds like a better direction to me. What's tricky is when to start showing suggestions again. Maybe whenever the |
Responding to your concern - no it won't. If you choose When we select a user from the suggestion list the name we typed is replaced with the handle with the user's email login (even for phone numbers) the only exception is the "here" mention - it stays as it is "@here". If some other handles like this will be added in the future, that should be added to the condition. We could have a util function to check for all the possible default mentions. |
You mean this regarding your proposal, right? I'm referring to just the current (broken) behavior. My concern is that with your proposal, we have to hardcode any conflicting
is the real problem and we just need to stop that from happening with a flag or maybe something else. |
@arosiclair Ah, ok, yes I meant my proposal. You're right - if we're going to change the handle behavior, it makes sense to investigate the other solution. Thanks for pointing this out! |
Working on the alternative solution |
Ok, so another solution that would be ready for the mention handle changes: ProposalPlease re-state the problem that we are trying to solve in this issue.same as here What is the root cause of that problem?same as here What changes do you think we should make in order to solve the problem?Just like we save the draft only in Onyx (we don’t sync the draft with other devices, we don’t send it to the BE), we can do the same for the mentions. Let’s save the mention after it was chosen from the suggestion list as What alternative solutions did you explore? (Optional) |
Do we need to use Onyx for that or can we just use local state in |
local state won't work after refreshing the page and leaving the chat and returning back to draft - the suggestion will be shown again |
Ah okay good points. Let's move forward with your proposal 👍. Last thing: can we just name the Onyx key something more clear like |
Thanks! 🙌🏻 Yeah, I'll try to come up with another name 😃 |
Hi! I opened the PR last week 🙂 I'm ooo this week, so if any changes will be required or there will be any conflicts to resolve, please ping Callstack team - someone will take it over |
PR: #37262 |
probably fixed by this: #38361 |
@sobitneupane can you retest to verify this is no longer an issue with those changes? |
@arosiclair Yup. The issue is no longer reproducible. Screen.Recording.2024-03-20.at.12.17.52.mov |
Alright that's good news. I appreciate the efforts from you guys. @sobitneupane still did most of the work so I think they should still get payment. What do you think @sakluger? |
Sounds good to me! Thanks, everyone, for sticking with this one. Summarizing payment on this issue: Contributor: @koko57 - no payment necessary (from CallStack) |
$500 approved for @sobitneupane based on summary. |
If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Version Number: 1.4.6-2
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
Expensify/Expensify Issue URL:
Issue reported by: Applause - Internal Team
Slack conversation:
Action Performed:
Pre-condition : Must have user with 'here' in the display name.
4.Select "here" from suggestion list
Expected Result:
After selecting "here" from suggestion list, the suggestion box must be closed
Actual Result:
After selecting "here" from suggestion list, the suggestion box is opened showing contact with "here" display name
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Screenshots/Videos
Add any screenshot/video evidence
Bug6296214_1701362159518.az_recorder_20231130_210049.mp4
View all open jobs on GitHub
Upwork Automation - Do Not Edit
The text was updated successfully, but these errors were encountered: