-
Notifications
You must be signed in to change notification settings - Fork 46
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
Store passed x/gov TextResolutions on chain #669
Comments
I am not sure if I understand. When a proposal with a message of type Even if the above is true, in order to execute stored |
Yes, this is the current state (which was how it worked before in gov as well before my Executor changes). I just want to do something there when executing this message. Store the proposal text in some bucket. The tally works the same as always, just the text of the resolution is currently not stored in any easy way. You can search all Proposals, filter by which succeeded, then parse all those vote types, extract those that were TextResolutionMsg and grab the messages. That doesn't make it easy to build a simple UI to show past passed resolutions (which should be easy to keep memory of our decisions) Does it make sense now? |
Makes sense.
|
I dunna, just trying to collect all references. The resolution was part of a Proposal, accepted by an Electorate, according to some ElectionRules. I am happy not to store the direct ElectionRules there. |
Is your feature request related to a problem? Please describe.
When a text resolution passes governance, it is currently a no-op. I guess one can query transactions to discover this, but it would be nice to actually store the successful proposals in a bucket on chain. For easy queryability.
Resolves last point here: #633
And #613
Describe the solution you'd like
Create a new ResolutionBucket, which is only writen by TextResolutionMsg https://github.com/iov-one/weave/blob/master/cmd/bnsd/app/codec.proto#L115 (The message contents can be updated as needed).
A Resolution model can use an IDGenBucket for primary key. Stored content should be:
We should ensure that these numbers are all correct (pulled from "context"). Note that this Msg/Handler can only be executed in the context of a governance vote.
Secondary index on electorate (id without version) would be good (all proposals accepted by this group). The other references don't need to be indexes
There should also be a query handler in the x/gov module for this bucket for easy queries by the clients to show past resolutions
Describe alternatives you've considered
Just search by indexed tx tags. But it seems much weaker and less user-friendly. Especially if such resolutions are important and should be binding.
The text was updated successfully, but these errors were encountered: