issues
search
social-protocols
/
jabble
Social Media from the Future
7
stars
0
forks
source link
Vote State Management Bugs
#125
Closed
johnwarden
closed
1 week ago
johnwarden
commented
2 weeks ago
I found these bugs in the remove-critical-thread branch
(FIXED) missing vote here / blue line (criticalThreadId is wrong):
Steps to reproduce
just reset-all
http://localhost:3000/dev-login
http://localhost:3000/post/1
upvote post 1
blue line appears next to post 2
vote on post 2
blue line next to post 2 disappears
blue line does not appear next to post 3 (as it should)
reload page
blue line appears next to post 3
cause
voting on post 2 caused post 3 to become the critical thread. criticalThreadId needs to be part of postDataState.
(FIXED) Missing vote here / blue line (targetHasVote is wrong)
Steps to reproduce
just reset-all
http://localhost:3000/dev-login
http://localhost:3000/post/1
upvote post 1
vote and then clear vote on post 2
vote and then clear vote on post 3
reload page
vote on post 1 is shown as blue/uninformed, but no blue line is shown
Cause:
targetHasVote values is wrong. It is calculated based on the vote state of parent, not target
(FIXED) voteHere doesn't disappear when target vote is cleared
Steps to reproduce
just reset-all
http://localhost:3000/dev-login
http://localhost:3000/post/1
upvote post 1
upvote post 2
reload page
voteHere shown next to post 3
clear vote on post 1
voteHere still shown next to post 3 (it should disappear)
Cause
the critical commendId is different after reload, that's why something else is visualized. Same problem as the first. criticalThreadId needs to be part of postDataState.
isConvincing icon missing
Steps to reproduce
just reset-all
http://localhost:3000/dev-login
http://localhost:3000/post/1
upvote post 1
isConvincing icon not shown
reload page
isConvincing icon shown
Cause
convincing-ness needs to be part of postDataState
Also note: isConvincing is relative to parent, but should be relative to target?
(FIXED) voteHere doesn't disappear (isInformed is wrong / indirectly-informed votes)
Steps to reproduce
just reset-all
http://localhost:3000/dev-login
http://localhost:3000/post/1
downvote post 1
blue line appears next to post 2
vote on post 3
blue line still shown next to post 2 (should disappear, since user is now indirectly informed)
Cause
calculation of isInformed needs to consider indirectly-informed votes.
I found these bugs in the remove-critical-thread branch
(FIXED) missing vote here / blue line (criticalThreadId is wrong):
Steps to reproduce
cause
(FIXED) Missing vote here / blue line (targetHasVote is wrong)
Steps to reproduce
Cause:
(FIXED) voteHere doesn't disappear when target vote is cleared
Steps to reproduce
Cause
isConvincing icon missing
Steps to reproduce
Cause
(FIXED) voteHere doesn't disappear (isInformed is wrong / indirectly-informed votes)
Steps to reproduce
Cause