-
Notifications
You must be signed in to change notification settings - Fork 790
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
[sd-reverse-delegation] new strategy: sd reverse delegation #1341
base: master
Are you sure you want to change the base?
Conversation
|
||
export const author = 'pierremarsotlyon1'; | ||
export const version = '0.1.0'; | ||
export const dependOnOtherAddress = true; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @pierremarsotlyon1 Right now we are not accepting strategies that depend on other addresses to calculate voting power. these types of strategies are usually not scalable, you see some other way to handle this without depending on other voters
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @ChaituVR
I didn't really understand the issue here
I'm just calculating the voting power of each voters to calculate the voting power of another voter
Which is basically like calculate the voting power of each voters like all the other strategies
For example, if we have these voters : [0x1, 0x2, 0x3] and the strategy will want to calculate the voting power of 0x3 (based on strategy parameters), I will calculate the voting power of 0x1 and 0x2 to assign the voting power of 0x3
What's the issue here ?
and you already have few strategies with dependOnOtherAddress set at true like 'src/strategies/delegation/index.ts'
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes we do have other 15 old strategies that depend on other addresses, but we stopped accepting new ones as they are not scalable and causing lot of trouble, one alternative way is running seperate server to return the voting power of addresses and using the strategy api-v2-override
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But there is something that i don't understand
Currently, with your current default delegation strategy, how you reduce the delegation address voting power if there are some voters who delegated to the delegation address ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Currently, with your current default delegation strategy, how you reduce the delegation address voting power if there are some voters who delegated to the delegation address?
We calculate voting power for all addresses again (that's the pain problem 🙈 ), and then we will just ignore the voting power of the delegator who voted from the delegate's voting power
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible to calculate in a external server the voting power of each user and then compute the delegation address voting power in the strategy ?
the delegation address voting power will still be based on the voter addresses but at least the user voting power will be compute externally
So basically, the strategy will just fetch voting powers with an endpoint and then do plus/minus stuff
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Your strategy can do anything within limits mentioned here https://github.com/snapshot-labs/snapshot-strategies#code just that depending on other addresses is not scalable for us
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, we're blocked with what we want to achieve and your requirements.
Is it really not possible to push this strat ?
Otherwise, is it possible to use your delegation strategy (like currently we have) but use a custom delegation contract address by the strategy settings ?
Or is it possible to add this logic on your side ?
Basically, our "custom" delegation contract will be the same as yours but with new functions
Create a reverse delegation strategy
Changes proposed in this pull request: