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

Feat/nico/likes sync #12

Open
wants to merge 8 commits into
base: main
Choose a base branch
from
Open

Feat/nico/likes sync #12

wants to merge 8 commits into from

Conversation

NicoSerranoP
Copy link
Contributor

This PR covers a couple of things:

  1. syncs the likes (user related such as likedContent and content related such as likes) directly with each user or content object.
  2. standarizes some data naming
  3. fixes tags and likes EIP signatures (and its tests) so they cover timestamp as well

@NicoSerranoP NicoSerranoP self-assigned this Oct 31, 2023
@NicoSerranoP NicoSerranoP requested a review from jp4g October 31, 2023 06:14
@jp4g
Copy link
Contributor

jp4g commented Oct 31, 2023

Is there an explicit reason only the backend can "charge the vault"? It is unlikely people will randomly donate but if they wanted to fund the vault, is there a downside to allowing them?

@jp4g
Copy link
Contributor

jp4g commented Oct 31, 2023

When syncing, is it the responsibility of the backend to make sure the # of likes for some content has parity with the actual likes stored by each user? Is there a way to litigate a discrepancy in likes between these two sources of truth/ is one THE source of truth?

@NicoSerranoP
Copy link
Contributor Author

Is there an explicit reason only the backend can "charge the vault"? It is unlikely people will randomly donate but if they wanted to fund the vault, is there a downside to allowing them?

The slashing vault is only rechargable by the backend because it is the staked value that the backend puts as a guarantee. If a user proves a receipt was not included in the contract, the user would get rewarded from this slashing vault.

@NicoSerranoP
Copy link
Contributor Author

When syncing, is it the responsibility of the backend to make sure the # of likes for some content has parity with the actual likes stored by each user? Is there a way to litigate a discrepancy in likes between these two sources of truth/ is one THE source of truth?

It is the backend responsibility to keep the number of likes in each content and the user likes align. There is one litigation function that any user could call that would perform a check on a specific content likes vs which users have liked the content. The function name is litigateNumberOfLikes

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