-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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] Messages are not showing in the LHN when someone sends it #45356
Comments
This has been labelled "Needs Reproduction". Follow the steps here: https://stackoverflowteams.com/c/expensify/questions/16989 |
Triggered auto assignment to @jliexpensify ( |
Problem Statement: Messages are not displaying in the LHN (Left Hand Navigation) when someone sends a message, resulting in users missing important notifications and updates. Root Cause: The root cause of the problem is likely due to an issue with the message rendering logic, WebSocket connection, or data storage. Changes to Solve the Problem: To solve the problem, I propose the following changes:
// Update message rendering logic useEffect(() => { return ( {messages.map((message) => ( ))} ); }; 2. Verify WebSocket Connection Verify that the WebSocket connection is established correctly and messages are being received from the server. This includes reviewing the WebSocket connection logic and error handling to ensure that messages are not being lost or dropped. // Verify WebSocket connection socket.onmessage = (event) => { socket.onopen = () => { socket.onerror = (event) => { -- Check message storage in database Use a Different Message Rendering Library: Explore alternative message rendering libraries, such as react-chat-elements, to see if they provide better performance and reliability. |
I can reproduce this with only one person in my LHN - @SofiedeVreese. All of her messages don't appear unless I click out of her chat and back in. I think this will be hard to accurately repro, but it can be reproduced. |
Job added to Upwork: https://www.upwork.com/jobs/~01263f65273fb956e2 |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @dukenv0307 ( |
I think this should be criticial in newDot quality since it affects core chat workflow cc @muttmuure |
Should we make this |
Triggered auto assignment to @lakchote ( |
I got some messages from @iwiznia today, and the LHN isn't showing the chat as unread. I looked at onyx and it doesn't look like the report actions are in there, which explains why the message isn't being marked as unread. I think the issue we're seeing in this case is that the messages aren't being delivered to the client And these are the last 3 report actions in onyx for that reportID [
{
"html": "I used our social channel, but maybe I can use a better one, like a public channel",
"text": "I used our social channel, but maybe I can use a better one, like a public channel",
"type": "COMMENT",
"whisperedTo": []
}
]
[
{
"html": "Do you know one with many many participants?",
"text": "Do you know one with many many participants?",
"type": "COMMENT",
"whisperedTo": []
}
]
[
{
"html": "Yeah I think it runs a lot which is why I think 10-12ms <em>could</em> be a problem",
"text": "Yeah I think it runs a lot which is why I think 10-12ms could be a problem",
"type": "COMMENT",
"whisperedTo": []
}
] After opening the chat, I get all the messages [
{
"type": "COMMENT",
"html": "Yeah I think it runs a lot which is why I think 10-12ms <em>could</em> be a problem",
"text": "Yeah I think it runs a lot which is why I think 10-12ms could be a problem",
"isEdited": false,
"whisperedTo": [],
"isDeletedParentAction": false,
"deleted": "",
"reactions": []
}
]
[
{
"type": "COMMENT",
"html": "And more importantly it runs on many writes.",
"text": "And more importantly it runs on many writes.",
"isEdited": false,
"whisperedTo": [],
"isDeletedParentAction": false,
"deleted": "",
"reactions": []
}
]
[
{
"type": "COMMENT",
"html": "So 5x on 2ms to 10ms is probably fine, but if there's indeed some that take 50ms and those are also x 10 that would be 500ms which might be bad",
"text": "So 5x on 2ms to 10ms is probably fine, but if there's indeed some that take 50ms and those are also x 10 that would be 500ms which might be bad",
"isEdited": true,
"whisperedTo": [],
"isDeletedParentAction": false,
"deleted": "",
"reactions": []
}
]
[
{
"type": "COMMENT",
"html": "<blockquote>Do you know one with many many participants?</blockquote>No, but yes, probably some of the public channels",
"text": "Do you know one with many many participants?\nNo, but yes, probably some of the public channels",
"isEdited": false,
"whisperedTo": [],
"isDeletedParentAction": false,
"deleted": "",
"reactions": []
}
]
[
{
"type": "COMMENT",
"html": "Once you find it, you should add it to the PR template: <a href=\"https://github.com/Expensify/Auth/blob/main/.github/PULL_REQUEST_TEMPLATE.md?plain=1#L21\" target=\"_blank\" rel=\"noreferrer noopener\">https://github.com/Expensify/Auth/blob/main/.github/PULL_REQUEST_TEMPLATE.md?plain=1#L21</a>",
"text": "Once you find it, you should add it to the PR template: https://github.com/Expensify/Auth/blob/main/.github/PULL_REQUEST_TEMPLATE.md?plain=1#L21",
"isEdited": false,
"whisperedTo": [],
"isDeletedParentAction": false,
"deleted": "",
"reactions": []
}
]
[
{
"type": "COMMENT",
"html": "Maybe one of those will do? I assumed big chats mean lots of messages though, not lots of people.",
"text": "Maybe one of those will do? I assumed big chats mean lots of messages though, not lots of people.",
"isEdited": false,
"whisperedTo": [],
"isDeletedParentAction": false,
"deleted": "",
"reactions": []
}
]
[
{
"type": "COMMENT",
"html": "Yep, just checked, those are chats with only 2 people",
"text": "Yep, just checked, those are chats with only 2 people",
"isEdited": false,
"whisperedTo": [],
"isDeletedParentAction": false,
"deleted": "",
"reactions": []
}
] |
Investigated this with @cead22. Here are logs from his device. One of the messages I sent and he was not seeing has actionID of 5285273928576337160 Conclusions are:
My guess is that the bug is that client needs to be updated here but something in OnyxUpdates.saveUpdateInformation is going wrong and the update is never applied. |
The PR I sent will log whenever we detect the onyx updates need updating. |
Shit.. we have two issues for this! I was able to reproduce this week and shared onyx data with Puneet. Check this thread Since you sent a PR Ioni, I should close the other one, right? it's here |
I just has an instance where LHN and the chats in #social didn't update. I had a sneaking suspicion they weren't so I captured onyx data, refreshed, then saw new chats load. Hope it's helpful (or you're able to find the logs and those are helpful) |
#social still isn't auto-updating for me to show the latest chats in LHN. ie. Vit's showed as being the most recent in LHN but I felt like it had been sent quite a while ago, when I clicked on the channel, it updated to show multiple chats since the one Vit sent. Onyx data before clicking on the room. Onyx data after clicking on the chat and opening the room. Let me know if there's anything I can do to help get this fixed. |
We're discussing the latest theory here: https://expensify.slack.com/archives/C05LX9D6E07/p1721679415535579?thread_ts=1721217121.843389&cid=C05LX9D6E07 |
Hi, I am Alexey from Margelo and I can work on this issue. |
📣 @dukenv0307 🎉 An offer has been automatically sent to your Upwork account for the Reviewer role 🎉 Thanks for contributing to the Expensify app! |
lonnnnng thread in #newdot-quality here |
@puneetlath @Kureev @jliexpensify @dukenv0307 this issue was created 2 weeks ago. Are we close to approving a proposal? If not, what's blocking us from getting this issue assigned? Don't hesitate to create a thread in #expensify-open-source to align faster in real time. Thanks! |
I think.. hope.. we're all fixed here. Read the |
Shit... on the latest desktop staging build and chats didn't load after restarting my computer and opening NewDot (I think I updated the app this morn too). What I see when I open new.expensify.com in Firefox Gonna share in the thread too |
Gonna close this cuz the initial bug here appears to be "I'm active in NewDot and new chats are showing in LHN" where my issue is "After having my laptop closed for some time, I opened Desktop and chats aren't sending (which is likely a reconnect issue)". More discussion here and a new thread for my specific bug here |
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:
Reproducible in staging?: needs reproduction
Reproducible in production?: needs reprroduction
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: @cead22
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1720045541007929
Action Performed:
Expected Result:
UserB's message should update in the LHN
Actual Result:
Message does not appear in the LHN and user A has to switch to another chat and open the chat report from B to appear the message
Workaround:
unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Screenshots/Videos
SS before chat :
When opening chat with B
After opening the chat
View all open jobs on GitHub
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @lakchoteThe text was updated successfully, but these errors were encountered: