# Posts Read Discrepancy

**URL:** https://meta.discourse.org/t/posts-read-discrepancy/18694
**Category:** Feature
**Created:** [August 10, 2014, 11:36am UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694 "2014-08-10T11:36:02Z")
**Posts on this page:** 19
**Page:** 1

<div class="post-metadata">

### Author: ![cpradio](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/cpradio/32/4970_2.png) [@cpradio](https://meta.discourse.org/u/cpradio)
#### Post date: [August 10, 2014, 11:36am UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/1 "2014-08-10T11:36:02Z")

</div>

Okay, so maybe the numbers don’t mean exactly what I think they do, but the Requirements for TL 3 show I’ve read (all time) 1905 posts.

![](https://global.discourse-cdn.com/meta/original/3X/b/c/bc130d1f495a508aa380238113975243c563f929.png)

But if you go to my admin user page, it has 2743. Why the large discrepancy? I’d expect these numbers to match.

![](https://global.discourse-cdn.com/meta/original/3X/7/c/7ca92eddc3ea075e487c41feb704ea149b603983.png)

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [August 10, 2014, 11:45am UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/2 "2014-08-10T11:45:59Z")

</div>

Tl3 stuff looks at 100 days for all stats

---

<div class="post-metadata">

### Author: ![cpradio](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/cpradio/32/4970_2.png) [@cpradio](https://meta.discourse.org/u/cpradio)
#### Post date: [August 10, 2014, 11:48am UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/3 "2014-08-10T11:48:32Z")

</div>

That can’t be as the two Posts Read statistics would be the same then… There is a Posts Read, which should be the past 100 days, and there is a Posts Read (all time).

As an aside, it shows correctly for Topics, just doesn’t show correctly for Posts.

---

<div class="post-metadata">

### Author: ![TechnoBear](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/technobear/32/40546_2.png) [@TechnoBear](https://meta.discourse.org/u/TechnoBear)
#### Post date: [August 10, 2014, 12:00pm UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/4 "2014-08-10T12:00:23Z")

</div>

I can confirm there’s a discrepancy.

The requirements show I’ve read 2,327 posts:

 ![](https://global.discourse-cdn.com/meta/original/3X/3/9/39a46f8156ea52351a4ca8ad367ddc598d9bfe73.png)

But the admin page shows 3,205:

 ![](https://global.discourse-cdn.com/meta/original/3X/4/9/49855be4e9ee0b48e786ef1d7a12514df706f75f.png)

---

<div class="post-metadata">

### Author: ![cpradio](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/cpradio/32/4970_2.png) [@cpradio](https://meta.discourse.org/u/cpradio)
#### Post date: [August 10, 2014, 3:06pm UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/5 "2014-08-10T15:06:42Z")

</div>

@sam I think this would be a good bug for me to get my “feet” wet, so to speak. So if you don’t mind it sitting for a while (until my time frees up – should be another week or two), I’ll see if I can’t resolve it 😄

I’ve got my environment up, now i just need to work through a good way to load up the code.

---

<div class="post-metadata">

### Author: ![Mittineague](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mittineague/32/114259_2.png) [@Mittineague](https://meta.discourse.org/u/Mittineague)
#### Post date: [August 10, 2014, 5:39pm UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/6 "2014-08-10T17:39:06Z")

</div>

I’m guessing this might have to do with many of our earlier test posts being deleted in preparation for the official Move? i.e. Deleting posts did not decrement counts..

---

<div class="post-metadata">

### Author: ![TechnoBear](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/technobear/32/40546_2.png) [@TechnoBear](https://meta.discourse.org/u/TechnoBear)
#### Post date: [August 10, 2014, 5:44pm UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/7 "2014-08-10T17:44:52Z")

</div>

That would make sense, i suppose, but it seems strange that one total has been reduced and not the other. And I’ve still _read_ those posts, even if they were subsequently deleted. I’d expect my own post count to go down (which I think it did), but not the posts read.

---

<div class="post-metadata">

### Author: ![Mittineague](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mittineague/32/114259_2.png) [@Mittineague](https://meta.discourse.org/u/Mittineague)
#### Post date: [August 10, 2014, 5:49pm UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/8 "2014-08-10T17:49:49Z")

</div>

I haven’t had enough coffee yet to give me even a chance to see a connection, but maybe comparing with the dashboard stats can offer a clue?

 ![](https://global.discourse-cdn.com/meta/original/3X/6/7/674988c6fa6d4a6ed7a5a55a5dd534851da97ba7.png)  
 ![](https://global.discourse-cdn.com/meta/original/3X/d/6/d672288a8fd5b7b364632010a04798c7ad25a430.png)  
If @HAWK knows how many Topics and Posts were deleted that should help.

I’m wondering if reading and posting in our private Staff categories is in play here?

---

<div class="post-metadata">

### Author: ![TechnoBear](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/technobear/32/40546_2.png) [@TechnoBear](https://meta.discourse.org/u/TechnoBear)
#### Post date: [August 10, 2014, 6:15pm UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/9 "2014-08-10T18:15:11Z")

</div>

I’ve had a look at SuperTed’s stats, which are a bit easier to check, as virtually all his posts have been deleted.

![](https://global.discourse-cdn.com/meta/original/3X/8/8/886c92f4a3cc09f29510dabf54fab3d415fe00c2.png)

And from the “Activity” section:

 ![](https://global.discourse-cdn.com/meta/original/3X/d/4/d45b695b6744b97e8911afea9e65d136cbb34c9b.png) 

19 private topics (as shown under “activity”) matches what he sees in his profile. 2 topics replied to (as shown in the TL3 dialogue) is right, after the test threads were deleted. **But** almost every thread he was involved in has been deleted. He didn’t have access to the private areas of the forums, so if the “posts read” figure were reflecting the total after the threads were deleted, it should be very much lower. There are not 687 posts remaining in the public area, or anything close to that number.

---

<div class="post-metadata">

### Author: ![cpradio](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/cpradio/32/4970_2.png) [@cpradio](https://meta.discourse.org/u/cpradio)
#### Post date: [August 10, 2014, 7:04pm UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/10 "2014-08-10T19:04:56Z")

</div>

So I’m playing with this right now in my dev environment and I found something that may be curious. If I create a topic, and read it, it is counted on my activity admin page, but doesn’t seem to be counted on the TL requirements.

I’m still investigating (trying to find ways of reproducing the discrepancy, at least)

---

<div class="post-metadata">

### Author: ![HAWK](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/hawk/32/86627_2.png) [@HAWK](https://meta.discourse.org/u/HAWK)
#### Post date: [August 10, 2014, 9:29pm UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/11 "2014-08-10T21:29:16Z")

</div>

> [@Mittineague](#):
>
> If @HAWK knows how many Topics and Posts were deleted that should help.

Nope, no idea I’m afraid.

---

<div class="post-metadata">

### Author: ![cpradio](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/cpradio/32/4970_2.png) [@cpradio](https://meta.discourse.org/u/cpradio)
#### Post date: [August 20, 2014, 10:48pm UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/12 "2014-08-20T22:48:55Z")

</div>

@sam

So here is what I discovered (or think I discovered). It seems the info found on the Admin User page (not the TL requirements page), are read from the user\_stat table and include deleted posts, posts that have changed ownership, etc.

The TL requirement seems to be based on the user\_visits table. Obviously the two must be out of sync.

This is where I’m stuck. I see a call to `object.user_stat.send(sym)` where sym is `posts_read_count`, but I haven’t found the send method of user\_stat yet. My guess is there isn’t an actual method, it is built into ActiveRecord::Base and it simply reads the column from the table (but that is a guess).

I’m assuming the same is true for `posts_read` in the user\_visits table.

Thoughts?

---

<div class="post-metadata">

### Author: ![zogstrip](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/zogstrip/32/512781_2.png) [@zogstrip](https://meta.discourse.org/u/zogstrip)
#### Post date: [August 21, 2014, 7:26am UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/13 "2014-08-21T07:26:07Z")

</div>

> [@cpradio](#):
>
> This is where I’m stuck. I see a call to object.user\_stat.send(sym) where sym is posts\_read\_count, but I haven’t found the send method of user\_stat yet. My guess is there isn’t an actual method, it is built into ActiveRecord::Base and it simply reads the column from the table (but that is a guess).

It’s actually [built into Ruby](http://ruby-doc.org/core-2.1.2/Object.html#method-i-send). It’s used when “_metaprogramming_” and allows the programmer to dynamically call a method on the object (here calling the `post_read_count` method on the `object.user_stat` object).

---

<div class="post-metadata">

### Author: ![cpradio](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/cpradio/32/4970_2.png) [@cpradio](https://meta.discourse.org/u/cpradio)
#### Post date: [August 21, 2014, 10:05am UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/14 "2014-08-21T10:05:20Z")

</div>

Thanks!

Okay, so the difference in counts is definitely due to the tables being out of sync for those columns. Interesting…

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [October 8, 2014, 2:48am UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/15 "2014-10-08T02:48:37Z")

</div>

I think we are simply not bumping up read counts for “self created” posts and topics on the user visits table.

I am not sure if its desired or not to bump up these numbers.

---

<div class="post-metadata">

### Author: ![cpradio](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/cpradio/32/4970_2.png) [@cpradio](https://meta.discourse.org/u/cpradio)
#### Post date: [October 8, 2014, 10:40am UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/16 "2014-10-08T10:40:39Z")

</div>

They are included in the Total calculation, so if they aren’t part of the User accessed/read/whatever, then that is a big disadvantage for the user… isn’t it?

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [October 8, 2014, 4:21pm UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/17 "2014-10-08T16:21:14Z")

</div>

Should reading your own topics and posts count? Reading your own books isn’t the same as reading words other people wrote.

---

<div class="post-metadata">

### Author: ![cpradio](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/cpradio/32/4970_2.png) [@cpradio](https://meta.discourse.org/u/cpradio)
#### Post date: [October 8, 2014, 4:32pm UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/18 "2014-10-08T16:32:03Z")

</div>

Agreed, but if my posts are included in the right column (number of posts you must read), I’m at a disadvantage if I contributed 200 of those posts in that count (in the last 100 days) and my posts aren’t reflected on the left (for the ones I have read), aren’t I? (than someone who only contributed 30 posts)

Maybe my logic is flawed, but to me it sounds right…

---

<div class="post-metadata">

### Author: ![chapoi](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/chapoi/32/537252_2.png) [@chapoi](https://meta.discourse.org/u/chapoi)
#### Post date: [December 4, 2025, 11:31am UTC](https://meta.discourse.org/t/posts-read-discrepancy/18694/19 "2025-12-04T11:31:40Z")

</div>


