First time here? Check out the FAQ!

Can't moderate more than 16 bits of karma?

I tried giving myself a million karma and got a warning - adding the actual karma worked, but the moderation record complained; the repute object got stored with 32767 for positive and 1000001 for karma.

Does this mean the model field should be changed (assuming you agree this is a bug)?

rfrankel's avatar
asked 2010-09-22 18:02:05 -0500
edit flag offensive 0 remove flag close merge delete


I agree that it is a bug, but it's probably better to add error checking rather than allowing more bits for an instance of reputation change b/c it will be a waste of space. There is a repute for each vote and storage for them does add up.
Evgeny's avatar Evgeny (2010-09-22 19:58:52 -0500) edit
add a comment see more comments

1 Answer


Repute model uses SmallInteger field which in MySQL is in range –32768 to 32767. The user reputation is UnsignedInteger with a much larger range and apparently there is no check on the limits in the code, I've saved this issue in the bug tracker. Thanks.

edit: btw bug tracker is at

Evgeny's avatar
updated 2010-09-22 20:00:19 -0500, answered 2010-09-22 18:42:39 -0500
edit flag offensive 0 remove flag delete link


Got it - I'll make sure to put (potential) bugs there and restrict this to things like installation and documentation issues. Thanks again for the help.
rfrankel's avatar rfrankel (2010-09-23 01:22:12 -0500) edit
add a comment see more comments