3

I've been seeing this on Firefox Floorp & Zen Browser (all Firefox-based) for months. I just tried this: either get a new notification, mark it as unread, right > open link in new tab, then wait 5-15 mins and refresh the page. Either it goes away or it doesn't. I did this twice, and it didn't go away immediately after opening the link in either instance.

15
  • 5
    At least the last time I checked this, in response to the multiple duplicate questions about this issue that have already been posted, your problem statement is inaccurate. The code does, in fact, try to mark them as read. The issue is that there's a race condition resulting from the browser navigating away from the page to the link you clicked prior to the notification to the server that you actually clicked being actually sent. Thus, if it's marked will depend on your browser, how loaded it is, etc. In other words, this will be intermittent. Commented Dec 4, 2024 at 16:56
  • 1
    Why can't the notification the server be sent before marking it? Commented Dec 4, 2024 at 17:11
  • @Makyen oh, I assumed this was by design. If that’s the case it should be an easy fix, at least: developer.mozilla.org/en-US/docs/Web/API/RequestInit#keepalive Commented Dec 4, 2024 at 17:15
  • 1
    Hmm, the code is already using sendBeacon, so this shouldn't be an issue in remotely-modern browsers... ("It’s been available across browsers since April 2018.") Maybe I'm just always opening in new tabs, so the click handler isn't being triggered. I haven't been paying enough attention to be sure. Commented Dec 4, 2024 at 17:20
  • 1
    @Jeremy the beacon just ensures that the request will be sent. It is but navigating to a new page can still fetch the count before the update, then only initialise the web socket connection after the beacon request finishes and the update response was sent via the socket. Happens quite frequently for me and I'm currently on FF 133. Commented Dec 4, 2024 at 18:26
  • The notifications mechanism changed a couple of years ago. See meta.stackexchange.com/q/384148/334566 for details Commented Dec 4, 2024 at 18:44
  • @VLAZ ah, so it is being marked as read but that might not be immediately visible on the next page load. Gotcha, thanks for explaining, that makes sense. Commented Dec 4, 2024 at 19:20
  • @Jeremy Yes, it looks like SE's code changed sometime between 2024-06-06 and 2024-08-04, based on the copies of the code I saved on those dates, to using sendBeacon, which should work, instead of $.ajax(). So, it's possibly the other race condition of the data for the new page being generated prior to the POST caused by sendBeacon getting to SE's servers and propagating through the distributed database. However, we don't really know what the OP's issue is, as there's really not enough detailed information provided in the question to know exactly what they are having a problem with. Commented Dec 4, 2024 at 20:03
  • 5
    @Oneechan69 Please edit your question to more explicitly indicate what you're having a problem with for which you posted this feature-request to resolve. As currently written, this feature-request is asking for something to be implemented that already is implemented (and has been implemented for a long time, even if it had some bugs for a considerable period of time). However, you, presumably, still experienced an issue in this area of functionality. Without more detailed information from you, we have to assume that this is asking for something already implemented. Commented Dec 4, 2024 at 20:07
  • it sounds like you're describing how it currently should work, but doesn't in some cases. Expanding on how exactly you're interacting with the menu and on what device/browser may help. Commented Dec 4, 2024 at 20:14
  • 2
    The best solution would be if SE would provid a method to mark notifications as read via the api. Then people could create their own inbox which would actually work how they need it. Commented Dec 4, 2024 at 21:24
  • If you mean middle clicking aka opening in a new tab, this is a bug and it's already reported. Commented Dec 5, 2024 at 12:21
  • OK I took a closer look at the issue and updated the title & body. Commented Dec 6, 2024 at 4:33
  • So it's duplicate of Inbox is no longer immediately marking item as read when middle-clicking to open in new tab bug report. Commented Dec 7, 2024 at 15:11
  • OK. My post originally said and I thought that they weren't being dismissed at all. Commented Dec 7, 2024 at 16:58

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.