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

Gauge Add Reporting: Check for Preferential Gauge #1257

Closed
Tritium-VLK opened this issue Aug 19, 2024 · 1 comment · Fixed by #1317
Closed

Gauge Add Reporting: Check for Preferential Gauge #1257

Tritium-VLK opened this issue Aug 19, 2024 · 1 comment · Fixed by #1317
Assignees

Comments

@Tritium-VLK
Copy link
Member

Motivation

By improving our gauge add reporting in multi-sig ops, we guarantee that always the correct gauge is set as "preferential" in the subgraph and ultimately in the front-end

Problem statement

Let's say an entity creates a gauge on Arbitrum, then wants to apply for a BAL gauge and re-creates a new one. In the subgraph and the front-end, the first gauge is automatically set as preferential. One needs to emit an event to set it correctly. Ideally, if this is the case, one should do it before the gauge goes live / is added to the gauge controller so we guarantee frictionless operations

Implementation details

After checking that root and child-chain gauges are correctly set, do the following:

  1. check the root gauge
  2. check the getrecipient field
  3. on target chain, check subgraph and check preferential gauge field by calling following query:
{
  pool(id: "POOL_ADDRESS_LOWERCASE") {
    preferentialGauge {
      id
    }
    gauges {
      id
    }
  }
}
  1. if getrecipient in root gauge != preferential on target chain, throw error / warning

Details: balancer/gauges-subgraph#91

@Tritium-VLK
Copy link
Member Author

Tritium-VLK commented Aug 19, 2024

Relates too BalancerMaxis/bal_addresses#399

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 a pull request may close this issue.

2 participants