Jump to content


Photo

Post Rep Count Shows 0


If an entry does not have a reputation_cache entry and reputation is in regular points mode (not like) then the count will show zero despite having entries.

http://screencast.com/t/zxxhMcoy19FZ

The reputation_cache entry is not getting built.

I recall we made a change in this area to prevent the cache entry being updated on every view unnecessarily so possibly related.

Status: Fixed
Version: 3.3.0
Fixed In: 3.3.1


14 Comments

Same issue for me after the upgrade. Could you post a fix here?
Photo
Adriano Faria
Mar 22 2012 02:38 PM
Same here.
One problem about rep counter is that reputation_cache table gets cleared out periodically, because cache_date field is not being set properly and always set to zero. I've patched it this way.
diff --git a/admin/sources/classes/class_reputation_cache.php b/admin/sources/classes/class_reputation_cache.php
index b6c3410..e5d8dcd 100644
--- a/admin/sources/classes/class_reputation_cache.php
+++ b/admin/sources/classes/class_reputation_cache.php
@@ -785,6 +785,7 @@ class classReputationCache
																										   'type'		   => $type,
																										   'type_id'		=> $type_id,
																										   'rep_points'		 => intval($data['sum']),
+																										  'cache_date'	 => time(),
																										   'rep_like_cache' => serialize( $store ) ), array( 'app', 'type', 'type_id' ) );
		}
	  


Not sure if it is correct way, $store['cache_expire'] might be used for this.

I am sure there may be some other bugs, because cache table is not actively filled. If someone finds it out, please post.
OMG ! exact same problem here... I tough it was just me but I guess not!
Ok - topics.php goes into admin/applications/forums/sources/classes

[attachment=38165:topics.php]

class_reputation_cache.php goes into /admin/sources/classes/

[attachment=38166:class_reputation_cache.php]
Topics.php in ../sources or../sources/classes?
Edited: sources/classes
just small clarification so there is no confusion, the full path for topics.php should be:
admin/applications/forums/sources/classes/
After update and rebuild, reputation of every user was set to 0, i download and upload this two files but after rebuilding still everyone have 0 reputation. I have 1034 position in ipb_reputation_index database. How can i fix this?
This bug relates to the reputation shown in posts it is not related to user reputation values themselves. Please submit a ticket so we can look into that for you.
I did apply this fix. But I still have problems. For example when you recache you content. It go back to 0 again. And go up again when you visit the post. But if no one visit the post it stays at 0.

Because of this The best content list and reputation points overview in the profile will not show the correct number.
Please fix this.
Best content list has been already fixed for 3.3.1, not sure about the profile however so I'll double-check with Matt.
All should be fixed in 3.3.1.