Skip to content
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 #8267] Web - Read messages are marked unread after a while #3981

Closed
isagoico opened this issue Jul 12, 2021 · 97 comments
Closed

[HOLD #8267] Web - Read messages are marked unread after a while #3981

isagoico opened this issue Jul 12, 2021 · 97 comments
Assignees
Labels
Engineering Monthly KSv2 Needs Reproduction Reproducible steps needed

Comments

@isagoico
Copy link

isagoico commented Jul 12, 2021

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:

  1. Open an unread chat
  2. Navigate to other chats and use the app for a little while

Expected Result:

Unread chat should stay marked as unread.

Actual Result:

The chat that was opened earlier is marked as unread. Explained by @iwiznia:

I can't reliably reproduce this, but happens several times a day in web. I get a new message, I read it, come back later and the message is back to unread.

Workaround:

None needed. It's just confusing to the user to see a chat marked as unread when it was opened before.

Platform:

Where is this issue occurring?

Web ✔️
iOS
Android
Desktop App ✔️
Mobile Web

Version Number: 1.0.77-0

Logs: https://stackoverflow.com/c/expensify/questions/4856

Notes/Photos/Videos:

I haven't been able to reproduce this yet on my side. Will update here if I find any more information about this.

Expensify/Expensify Issue URL:

View all open jobs on Upwork


From @iwiznia https://expensify.slack.com/archives/C01GTK53T8Q/p1626078601100700

I can't reliably reproduce this, but happens several times a day in web. I get a new message, I read it, come back later and the message is back to unread.

@MelvinBot
Copy link

Triggered auto assignment to @thienlnam (Engineering), see https://stackoverflow.com/c/expensify/questions/4319 for more details.

@thienlnam thienlnam added the External Added to denote the issue can be worked on by a contributor label Jul 12, 2021
@MelvinBot
Copy link

Triggered auto assignment to @jboniface (External), see https://stackoverflow.com/c/expensify/questions/8582 for more details.

@jboniface
Copy link

Since this hasn't been reproduced, I am hesitant to post the job

@jboniface jboniface removed their assignment Jul 12, 2021
@jboniface jboniface added the Needs Reproduction Reproducible steps needed label Jul 12, 2021
@isagoico
Copy link
Author

Looks like @tgolen @stitesExpensify and @cead22 were able to reproduce this issue too 🤔 @iwiznia I know this is a long shot but I have some questions that could help me get solid repro steps:

  • Do you have an estimate of how much time it passes from reading the message to the unread status?
  • Are there other tabs opened with e.cash active? Or other devices logged in with the same account that were being used at the same time?
  • Does this happen with the same chat each time or are several chats affected?

@cead22
Copy link
Contributor

cead22 commented Jul 12, 2021

@iwiznia also check that you don't have policy rooms with unread messages (eg, #announce) -- Cole let me know recently that this could be another cause of 3.cash showing the unread indicator

@tgolen
Copy link
Contributor

tgolen commented Jul 12, 2021 via email

@iwiznia
Copy link
Contributor

iwiznia commented Jul 13, 2021

Do you have an estimate of how much time it passes from reading the message to the unread status?

It varies, I don't think the time is a determining factor here.

Are there other tabs opened with e.cash active? Or other devices logged in with the same account that were being used at the same time?

Nope

Does this happen with the same chat each time or are several chats affected?

Same as Tim, only one at a time, but not the same one each time

@iwiznia also check that you don't have policy rooms with unread messages (eg, #announce) -- Cole let me know recently that this could be another cause of 3.cash showing the unread indicator

Already did, this is not it. If it was, then the unread would not go away when I re-read the chat

@isagoico
Copy link
Author

Thanks for the extra info! 🙇 No luck yet on being able to repro the issue yet. Will update if I find something.

@isagoico
Copy link
Author

isagoico commented Jul 19, 2021

@puneetlath Had this same behaviour with his own message: (slack link here https://expensify.slack.com/archives/C01GTK53T8Q/p1626387107365600)

I have no idea how to reproduce this, but sometimes when I come back to the app after being away from my computer, my own messages will be marked unread. For example, this was a message that I sent to Tom a little earlier

image

@isagoico
Copy link
Author

@joaniew was able to reproduce this too (slack thread: https://expensify.slack.com/archives/C01GTK53T8Q/p16263903423766000)

sometimes messages will get randomly marked as unread (on iOS mobile) even if they’ve been read previously on either mobile or web

@iwiznia
Copy link
Contributor

iwiznia commented Jul 19, 2021

Yep, I get that too seemingly randomly, not even sure if I need to go away for it to happen, I think not.

@MelvinBot
Copy link

@thienlnam Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!

@thienlnam
Copy link
Contributor

Still having trouble getting consistent reproduction steps for this - with how random it is maybe it has to do with having instances on other devices and an older set of data overwriting the newer data

@MelvinBot MelvinBot added Overdue and removed Overdue labels Jul 23, 2021
@thienlnam
Copy link
Contributor

Throwing on a weekly until we can get better reproduction steps

@MelvinBot MelvinBot removed the Overdue label Jul 26, 2021
@thienlnam thienlnam added Weekly KSv2 and removed Daily KSv2 labels Jul 26, 2021
@thienlnam
Copy link
Contributor

No proposals or clear re-production steps yet

@MelvinBot MelvinBot removed the Overdue label Aug 4, 2021
@mallenexpensify
Copy link
Contributor

mallenexpensify commented Dec 15, 2021

@johnmlee101 can you review @kidroca 's comment above, #3981 (comment) and provide feedback

I just had this happen again, steps:

  1. Drafted a message to post in Chronos
  2. Closed laptop lid (not sure if Desktop was foreground, chat with Chronos was still in main window or if cursor was still in compose box or not..)
  3. Opened laptop lid, Chronos was bold in LHN, no new messages had been received.

I have a guess/feeling that all 'closing lid' actions are equal, ie. if the lid is closed for longer than a certain time, something different might happen. Kinda like screensaver vs sleep

@johnmlee101
Copy link
Contributor

Okay so I have a few thoughts right now. Some of which deal with how we might want to deal with requests when they are "offline" and it starts tying into the larger discussion on how we should deal with our offline logic. Basically we should be able to support newer requests overriding older ones in the queue, if I'm understanding correctly? And we need the information from the response to make a proper judgement on which requests to ignore.

@johnmlee101
Copy link
Contributor

cc @roryabraham because of our recent discussion 😄

@mallenexpensify mallenexpensify added Monthly KSv2 and removed Weekly KSv2 labels Dec 28, 2021
@MelvinBot MelvinBot removed the Overdue label Dec 28, 2021
@kidroca
Copy link
Contributor

kidroca commented Jan 7, 2022

One more ➕ for addressing this on the backend would be accidentally introduced bugs like loading a conversation from the middle would not cause everything past that point to be considered unread

We should be able to say (to the backend)

  • "mark everything up to this comment as read" and it's read anyway it'll just do nothing
  • "mark this comment as unread" then and only then it would mark everything past that point as unread

@tgolen
Copy link
Contributor

tgolen commented Jan 10, 2022 via email

@johnmlee101
Copy link
Contributor

Should I go ahead and split these assignments into two parts? One for the front-end changes in this repo and one for the back-end internal development?

@MelvinBot MelvinBot removed the Overdue label Jan 28, 2022
@mallenexpensify
Copy link
Contributor

@tgolen can you reply to #3981 (comment)

I'm off next week, not reassiging to another CM cuz doubt this will have much action

@tgolen
Copy link
Contributor

tgolen commented Feb 14, 2022

Splitting it out is fine, yes.

@mallenexpensify
Copy link
Contributor

Should I go ahead and split these assignments into two parts? One for the front-end changes in this repo and one for the back-end internal development?

@johnmlee101 can you go ahead and do this plz

@mallenexpensify
Copy link
Contributor

@johnmlee101 can you please help with the above and split the assignments into two parts?

@johnmlee101
Copy link
Contributor

Sorry, just saw this update now! On it

@johnmlee101
Copy link
Contributor

This issue is responsible for adding the two API end points needed.
#8267

Once those endpoints exist, then we'll go ahead and come back to this issue to make sure we're properly using the new API endpoint to update the read/unread markers (which can be done externally). This step will be combined with the deprecation of the API command and we'll revisit once things are all moved over.

@mallenexpensify mallenexpensify changed the title Web - Read messages are marked unread after a while [HOLD #8267] Web - Read messages are marked unread after a while Mar 25, 2022
@mallenexpensify mallenexpensify removed the Help Wanted Apply this label when an issue is open to proposals by contributors label Mar 25, 2022
@mallenexpensify
Copy link
Contributor

Put on hold pending #8267 (internal), updated title, removed Help Wanted label (don't forget to add back when take off hold)

@johnmlee101
Copy link
Contributor

johnmlee101 commented Mar 31, 2022

I will be keeping this on hold as we'll be pursuing a potential high-level refactor of this logic to simplify and inevitably fix these issues as put through our proposal process.

@melvin-bot melvin-bot bot added the Overdue label May 2, 2022
@mallenexpensify
Copy link
Contributor

From @stitesExpensify 8 days ago

Web PR is on prod, unsure why it didn't get posted here, but that means this is done!

Should we take off hold? And/or, is this related to Offline First?

@melvin-bot melvin-bot bot removed the Overdue label May 4, 2022
@stitesExpensify
Copy link
Contributor

I think that this issue might be fixed? My PR made it so that we can never set the lastRead backwards unless manually done by the user, that should fix this issue right?

@mallenexpensify
Copy link
Contributor

Since it doesn't sound like it's easy to reliably reproduce, it's hard to test. @iwiznia any idea of this has happened to you the past week?!?! If not, I'm down to close this then reopen if/when needed

@iwiznia
Copy link
Contributor

iwiznia commented May 5, 2022

I don't know, since the unread message indicator is totally broken for me right now. Let's close, since Marc is revamping all this soon anyway

@iwiznia iwiznia closed this as completed May 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Engineering Monthly KSv2 Needs Reproduction Reproducible steps needed
Projects
None yet
Development

No branches or pull requests