Skip to content

Commit

Permalink
fix: add nouns proposal options (#591)
Browse files Browse the repository at this point in the history
  • Loading branch information
brucexc authored Oct 17, 2024
1 parent 7cbf1a9 commit 570d506
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 10 deletions.
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ require (
github.com/mitchellh/mapstructure v1.5.0
github.com/redis/rueidis v1.0.45
github.com/redis/rueidis/rueidiscompat v1.0.45
github.com/rss3-network/protocol-go v0.5.12
github.com/rss3-network/protocol-go v0.5.13
github.com/spf13/afero v1.11.0
github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7
github.com/tidwall/sjson v1.2.5
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -390,8 +390,8 @@ github.com/rogpeppe/go-internal v1.12.0 h1:exVL4IDcn6na9z1rAb56Vxr+CgyK3nn3O+epU
github.com/rogpeppe/go-internal v1.12.0/go.mod h1:E+RYuTGaKKdloAfM02xzb0FW3Paa99yedzYV+kq4uf4=
github.com/rs/cors v1.7.0 h1:+88SsELBHx5r+hZ8TCkggzSstaWNbDvThkVK8H6f9ik=
github.com/rs/cors v1.7.0/go.mod h1:gFx+x8UowdsKA9AchylcLynDq+nNFfI8FkUZdN/jGCU=
github.com/rss3-network/protocol-go v0.5.12 h1:hDqTa3Ft0PDM6/IhXGC0kOY4Ogig7TuM3UvQ7U9cM2A=
github.com/rss3-network/protocol-go v0.5.12/go.mod h1:npcyduWt86uVbIi77xQaYk8eqltI9XNjk1FMGpjyIq0=
github.com/rss3-network/protocol-go v0.5.13 h1:/rUfdGfWyg9p1NnwCJEkGYIv/eLBvQlL/c91IFCIbNc=
github.com/rss3-network/protocol-go v0.5.13/go.mod h1:npcyduWt86uVbIi77xQaYk8eqltI9XNjk1FMGpjyIq0=
github.com/russross/blackfriday v1.6.0 h1:KqfZb0pUVN2lYqZUYRddxF4OR8ZMURnJIG5Y3VRLtww=
github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk=
github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
Expand Down
12 changes: 7 additions & 5 deletions internal/engine/worker/decentralized/contract/nouns/worker.go
Original file line number Diff line number Diff line change
Expand Up @@ -134,8 +134,6 @@ func (w *worker) Transform(ctx context.Context, task engine.Task) (*activityx.Ac
activity.Actions = append(activity.Actions, actions...)
}

// zap.L().Info("Processing task", zap.Any("task", ethereumTask))

return activity, nil
}

Expand Down Expand Up @@ -287,9 +285,13 @@ func (w *worker) buildGovernanceProposalAction(from, to common.Address, id *big.
From: from.String(),
To: to.String(),
Metadata: metadata.GovernanceProposal{
ID: id.String(),
Body: description,
Options: []string{},
ID: id.String(),
Body: description,
Options: []string{
metadata.ActionGovernanceVoteFor.String(),
metadata.ActionGovernanceVoteAgainst.String(),
metadata.ActionGovernanceVoteAbstain.String(),
},
StartBlock: decimal.NewFromBigInt(start, 0).String(),
EndBlock: decimal.NewFromBigInt(end, 0).String(),
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -381,8 +381,11 @@ func TestWorker_Ethereum(t *testing.T) {
Body: "# Increase Voting Delay and Voting Period\n\nAs the number of nouners and nouns sub-communities increase, we will see more proposals appear on-chain without prior off-chain coordination. This is a proposal to increase the ‘Voting Delay’ to 4 days, and the ‘Voting Period’ to 5 days, so that nouners have more time to diligence proposals and to decide how they will vote.",
StartBlock: "14597722",
EndBlock: "14617432",
Options: []string{},
Link: "",
Options: []string{
metadata.ActionGovernanceVoteFor.String(),
metadata.ActionGovernanceVoteAgainst.String(),
metadata.ActionGovernanceVoteAbstain.String(),
},
},
},
},
Expand Down

0 comments on commit 570d506

Please # to comment.