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

V1 Update Metrics Exporter and deprecate SnapshotDelegation #708

Merged
merged 5 commits into from
Dec 1, 2024

Conversation

thomaspanf
Copy link
Member

  • Removed all traces of SnapshotDelegation
  • Updated the metrics-exporter.go and snapshot-collector.go to support the new voting system.

These are the values passed into Grafana:

	channel <- collector.activeProposals
	channel <- collector.closedProposals
	channel <- collector.votesActiveProposals
	channel <- collector.votesClosedProposals
	channel <- collector.nodeVotingPower
	channel <- collector.delegateVotingPower

No changes were needed for activeProposals and closedProposals. votesActiveProposals and votesClosedProposals should display the correct info now that collector.delegateAddress is replaced with collector.signallingAddress.

We use propMgr.GetArtifactsForVoting(blockNumber, address) and pass the node address or on-chain delegate address to grab nodeVotingPower and delegateVotingPower, similarly to how it's done in rp pdao status

One thing we could do is remove the if time.Since(timestamp)>= hoursToWait check on the voting power calls and have it run every 5 minutes alongside the task loop. It doesn't make calls to the Snapshot API so I think this is okay.

@0xfornax
Copy link
Member

One thing we could do is remove the if time.Since(timestamp)>= hoursToWait check on the voting power calls and have it run every 5 minutes alongside the task loop. It doesn't make calls to the Snapshot API so I think this is okay.

I think it could be confusing to have a few fields of the Governance tab update faster and others take hours. Think it's ok to keep it as it is.

@0xfornax 0xfornax merged commit baa42e3 into master Dec 1, 2024
4 checks passed
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