Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 PST on 31 March 2024, to get $100 off your ticket.
Hello everyone,
I am experiencing an issue where one of my categories in the forum always has the "1 New" message notice on the forum. It does not go away by clicking mark all messages as read. I even erased a couple of latest messages but also did not work.
You can see what I mean here:
http://www.cancerconnections.com.au/forum
Any idea on how to fix this?
Any help would be very welcome.
Comment | File | Size | Author |
---|---|---|---|
#5 | db screenshot.jpg | 89.85 KB | totocol |
Comments
Comment #1
MichelleIs the "1 new" in the topics column or the posts column? If it's on the topics, does it go away if you disable AF?
Michelle
Comment #2
totocol CreditAttribution: totocol commentedHi Michelle,
Thanks for the quick reply.
it is in the "posts column" I disabled AF and the "1 new" was gone. I enabled AF again and the "1 new" was back. I ran update.php on both cases. Any other idea on how I could fix this?
Thanks again,
Raul
Comment #3
MichelleThe post count isn't in core so that will always go away if you disable AF.
The query that gets this is cached so possibly there's an issue there. Try clearing your cache (under performance).
If that doesn't do it, put this into a page with the php filter enabled:
Change the $uid=1; to the UID of the user with the problem. That should spit out the comment ID of the problem comment. If you look that comment up in the database maybe it will give you some idea of why it's stuck.
Michelle
Comment #4
totocol CreditAttribution: totocol commentedHi Michelle,
Clearing cache did not help. The "1 new" is staying for all users.
I will try the PHP code and report back.
Thanks again
Comment #5
totocol CreditAttribution: totocol commentedHi Michelle,
I followed your instructions and I got the cid of the problem comment. I did not look different to the others so that I could get a clue about what it was. I have attached a screenshot.
I have decided to delete that comment all together and the "1 new" is gone.
Thanks a lot again for your quick reply and effective solution.
Raul
Comment #6
MichelleWeird, I don't know what was special about the comment. You didn't say which one it was so it's hard to tell anything from your screenshot. All I can think of is the timestamp maybe got goofy somehow.
Michelle
Comment #7
totocol CreditAttribution: totocol commentedOh, sorry. It was comment 916. And yes, weird. There isn't anything in particular to point an issue with the comment.
Thanks a lot anyway. Great to have such a great support from one of my favourites Drupal contributors.
Raul
Comment #8
MichelleWeird... It comes to March 17, 2009 so it's not like it was in the future or something odd. Leprechauns, maybe? LOL! Well, glad it's fixed and hopefully it won't happen again.
Michelle
Comment #10
Jaypan CreditAttribution: Jaypan commentedI've had this same issue come up with the Silver Bells theme (if that makes any difference). Clearing the cache didn't do anything.
What I'm pretty sure happened is that a user either edited or deleted a comment, meaning that the thread had been updated. The problem was that clicking the '1 new' link didn't show which thread had been updated, so there was no way to know which thread to click on.
As a stopgap, I altered the script above to output links to the unread threads, created a page with that scirpt, and gave my users a link to that page so that they could click on links. The script now looks like this:
However, this is only a stop-gap solution and doesn't actually fix the problem. I'm in the middle of a couple big projects right now and don't have time to try to track down the issue, but when I do, I'll see if I can figure out how to fix it.
Comment #11
MichelleDid you ever look at this anymore?
Comment #12
Jaypan CreditAttribution: Jaypan commentedNo! it still happens sometimes. I have no idea what the instigator is. I ended up creating a 'mark all forums read' button for my users, and they are able to clear the message using this. But I have no idea what the original issue was.
Comment #13
MichelleWhat's the difference between your "mark all read" and AF's?
Comment #14
Jaypan CreditAttribution: Jaypan commentedI never saw one on AF. My users were asking for one, so I built it in. Does it need to be enabled?
That said, I'm not sure I could use it anyways - my forum is quite customized, with various content types only be included as forum topics depending on various circumstances (for example, whether or not they have any comments), so a generic mark all forums read button may not work for my site.
Comment #15
MichelleOooh... I just noticed you're on 1.x. I haven't looked at that in sooooo long I don't remember what's in it. Most of the good stuff is in 2.x. That's why I'm triaging the queue... Trying to move things along to get that off alpha so people start using it.
Not sure what to set this... I don't know if I can do anything else without more info but it's hard to provide info for something that happens just now and then. :( I guess will just leave it as is for now and see if anything new pops up.
Michelle
Comment #16
Jaypan CreditAttribution: Jaypan commentedI'm on 2.x. The OP was probably on 1.x.
If I see the problem specifically for my user in the future, I'll not clear it and leave a post here. We can debug it together, or maybe I can give you access to look at it.
Comment #17
MichelleI'm going to set this to 2.x, then, if you have the problem there. 1.x isn't getting much attention at all anymore and I'm pushing to get 2.x stable.
Comment #18
MichelleI'm going to bump this up to 7 since it's been reported there as well. If this is ever figured out, it should be backported to 6.
Unfortunately, I still haven't the foggiest.
Comment #19
joelrichard CreditAttribution: joelrichard commentedI'm going to jump in here as I have this problem occurring and I plan to identify the trouble tonight.
My version: 7.x-2.0 (not dev) datestamp 1332167738
First off, when I do use EITHER the "mark all forums read" (on the main forum page) or the "mark all topics read" (in an individual forum) the items that are remaining are often on the last one or two topics in a given forum. Example, I have four pages of topics, all the ones up and including most of page 4 are cleared. But in this case, the last two topics still show "View 1 new" and "view 71 new".
It's definitely inconsistent as it seems to work in some forums but not others.
More info as I track it down.
Comment #20
joelrichard CreditAttribution: joelrichard commentedLet's see if I can make some sense of the query that is being used to select the topics that need to be marked read. Here's one that I came up with that seems to miss two nodes: (it's finding 61 of 63 nodes in the forum)
If I understand correctly,
NODE_NEW_LIMIT
is calculated by default to be one month ago.From what I can tell, this is only going to find those items that were modified or whose comments were added within the past month. Am I correct?
I think the correction here is to remove the check for
n.changed
andncs.last_comment_timestamp
. When I try this on my copy of the code, it correctly identifies 63 node to be marked as read.I think this makes sense to me. What about you, Michelle?
Thanks!!
--Joel
Comment #21
Michelletroky ported and is caring for the D7 branch. I haven't had my head in this in a long time. He's doing a great job with this so I'll leave it up to him. :)
Michelle
Comment #22
troky CreditAttribution: troky commentedIt's interesting that nobody saw NODE_NEW_LIMIT bug before... Thanks for tracking it down.
Fixed in 7.x-2.x-dev
Comment #23
MichelleJust looked at that closer... Why would you need to mark read things older than the new limit? Things older than the new limit don't show as new anyway... I guess just be careful not to bloat the history table. I'm pretty fuzzy on this stuff since it's been so long but I'm at least somewhat sure that was the reason for adding that check.
Michelle