pollmaster
pollmaster copied to clipboard
Poll Not Updating Votes Correctly
Hi,
We created a poll on our discord yesterday. It was multiple choice (10 choices), non-anonymous, non-weighted, and restricted to one role type. When people came into vote, some of the votes were not matching the reaction total for each options (for example, option I had had 12 reacts, but only registered 9).
When we exported the results, the file displayed the same incorrect results displayed in the bot's posts, and was still different from the actual reaction count. We had to print screen each option's reaction count to make sure we had the right result
This might be caused if people are voting too quickly and the bot can't catch up. I can't replicate it since it only occurs when multiple people are clicking in a short time. I will try out a fix for this problem and would appreciate more feedback if it is working.
can you please verify if #9 has fixed this issue? Would appreciate the feedback (here or on the support discord server). Leaving this open for now.
We tried to go a large group test to try out the new changes. 4 choices, multiple choice, no role restriction, no weights.
At first, the bot was out of sync with the initial high volume. After a couple of minutes, it managed to re-sync with the react count and actually matched up, so that was great!.
However, we then had a second-wave of high volume votes and vote changes and it ended up not syncing correctly. It never caught up.
The only difference between the two waves was that in the second wave, there was someone who reacted with an emoji that wasn't part of the choices (a dog emoji, juxtaposed to 1,2,3,4 and the question mark). This correlated with the bot not updating correctly the second time. Even when this react was removed, the bot did not sync up again.
Could external reacts/emojis cause the bot to not sync up properly when it tries to read the option to update the database? That's the only thing we could think of that could have possibly caused it not to sync up the second time around.
Thank you, that's very valuable testing. I'll investigate with the random emoji. How many votes are we talking about in your tests roughly? Maybe it was caused by an unfortunate restart (then the catching up would stop). I had to restart the bot a couple times today to implement fixes.
Do you think it would be possible to join your server to see it for myself? Might give me a better clue to what is happening.
The total vote count is about 100. Here's the vote count and number of reacts for each:
A restart could be the culprit (I think I saw this when trying to create a new poll). I have a smaller private server that we did a smaller group test on (no external reacts) and worked fine.
As for an invite onto the main server I would have to ask the other mods for privacy reasons (it's also a political server so we're hesitant to make you or any other people uncomfortable). I could invite you to my own private server but the tests aren't as high volume there and it seems to work fine there.
Thanks for your support!
I did a lot of work today on trying to improve this -> #11 Could you please try again an see if it is better? Thanks a lot!
So we did another high-volume group test yesterday (5 choices, multiple choice, no weights, non anonymous, around 120+ gross votes, 24 hours). Here's what we found.
- Initially, when the high volume wave came in, the vote tallies were wrong for about 5-10 minutes (we didn't record the exact lag-time) but then the bot eventually caught up and started processing the votes correctly. All other high-volume waves behaved the same way (although their lag was proportionate to the volume). All other single-cast votes had a delay of around 5 seconds.
- We had users test external emojis/reacts (not 1-5 or question mark). The bot was able to handle this effectively and did not negatively affect the vote tallies.
- Later during the test (many hours later) when users (low-volume, single-users) tried to vote, the bot would not respond and did not refresh the results. This may have been due to the bot being restarted or maybe the DB could have been locked (the bot always appeared as "online", however). Hours after that, when another vote was cast, the bot successfully refreshed all votes (so the missing votes were now accounted for). We did NOT test whether the bot would refresh itself upon ending (as in, if the bot was off by X number of votes, we did not see if the bot would actually refresh the votes when it ended instead of refreshing upon a new vote cast). This may have to be a point of future testing in a new ticket or personal investigation.
- Bot successfully ended by itself with correct results. Bot was not able to export (although I created the poll I am not the server owner not have Manage Server permissions. We were able to export a previous poll made by the Server Owner days ago days ago as well as today. We used the pm!adminrole command but still no effect)
Seems like the main issue of this particular ticket has been resolved, with just some peripheral questions outside the scope of this ticket.
Thank you for your hard work!
I did another big update and worked on performance and scalability in #16. I think I have isolated the "bug" that was causing most of the delay and unresonsiveness.
I would appreciate if you could give it another try!
Also: Does the export issue still exist for you?
Happening to me too, if you need any more information do not hesitate to ask.
Might I suggest a ''refresh'' command to refresh votes if it screws up again?
Having similar issues.
Can we please get an update? This is dragging on too long.
I get no results at all :)
Getting weird bugs if users vote on stuff simulatanously
Same here
Having the same issue myself. Vote tally never seems to match the reaction tally. A refresh count command would be more than enough to make me a happy camper so I can resync the vote count.
This bot is awesome and just what we are looking for with regards to the anonymous setttings etc. However, just created a single choice poll on discord and on both the mac app as well as on my android device, if I tapped multiple choices prior to Pollmaster acknowledgement, the poll counted multiple choices.
Not sure if this issue should be part of this thread or a separate issue @matnad Filed it here separately https://github.com/matnad/pollmaster/issues/72
@aneeshjoshi Yes, can confirm the bug.