Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ticketvote: Add cache fsck #1531

Merged
merged 9 commits into from
Oct 12, 2021
Merged

ticketvote: Add cache fsck #1531

merged 9 commits into from
Oct 12, 2021

Conversation

thi4go
Copy link
Member

@thi4go thi4go commented Oct 8, 2021

This diff adds a fsck command for the ticketvote plugin. For every
record of the provided tokens, it:

  • Verifies the coherency for the summary cache
  • Audit all eligible cast votes for the provided tokens
  • Verifies the coherency of the submissions cache for every RFP parent
  • Rebuilds the ticketvote inventory

Part of #1511

@thi4go thi4go marked this pull request as ready for review October 8, 2021 18:53
@thi4go
Copy link
Member Author

thi4go commented Oct 8, 2021

@lukebp ready for a review mate 👍

Copy link
Member

@lukebp lukebp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I left a couple comments, but overall, this is really nice. The quality of your code has dramitically improved this year. This PR clean, well documented, and reads well. Good job.

@thi4go
Copy link
Member Author

thi4go commented Oct 11, 2021

Hey @lukebp appreciate it mate. You've been an excellent team lead, so I also have you to thank for. This is ready for another look 👍

@thi4go
Copy link
Member Author

thi4go commented Oct 11, 2021

Actually still fixing one thing @lukebp will push in a bit

@thi4go
Copy link
Member Author

thi4go commented Oct 11, 2021

Good to go now @lukebp

Copy link
Member

@lukebp lukebp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It doesn't look like you've tested this against all record status.

Populate your backend with the seedproposals command to get proposals for all record statuses.
$ pictl seedproposals --comments=0 --commentvotes=0 [adminEmail] [adminPass]

The pictl voteinv response should be the same before and after the fsck.

lukebp and others added 4 commits October 11, 2021 21:19
This fixes a bug that was causing the vote status of non-public
proposals to be returned incorrectly from the summary plugin command.
The vote status was being returned as `unauthorized` when it should be
`ineligible`.
Copy link
Member

@lukebp lukebp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tACK

@lukebp lukebp merged commit 9fe1507 into decred:master Oct 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants