From 79bafdcb0ab089f076a1209bb2163c7cb3503254 Mon Sep 17 00:00:00 2001 From: Corantin Date: Sun, 27 Aug 2023 18:36:23 -0400 Subject: [PATCH] New subggraph --- .../hardhat/scripts/deploy-govern_queue.ts | 1 - .../govern-subgraph/manifest/data/gnosis.json | 8 +- .../subgraphs/govern-subgraph/package.json | 11 +- .../subgraphs/govern-subgraph/src/Govern.ts | 6 +- .../govern-subgraph/src/GovernQueue.ts | 331 +++++++++--------- .../govern-subgraph/src/GovernRegistry.ts | 65 ---- .../subgraphs/govern-subgraph/subgraph.yaml | 44 +++ 7 files changed, 236 insertions(+), 230 deletions(-) delete mode 100644 packages/subgraphs/govern-subgraph/src/GovernRegistry.ts diff --git a/packages/hardhat/scripts/deploy-govern_queue.ts b/packages/hardhat/scripts/deploy-govern_queue.ts index a10008bc..baf8d31b 100644 --- a/packages/hardhat/scripts/deploy-govern_queue.ts +++ b/packages/hardhat/scripts/deploy-govern_queue.ts @@ -67,7 +67,6 @@ export default async function deployGovernQueue( }), ethers.constants.HashZero, { - // from:"0x91B0d67D3F47A30FBEeB159E67209Ad6cb2cE22E", gasPrice: "110000000", gasLimit: "10000000", } diff --git a/packages/subgraphs/govern-subgraph/manifest/data/gnosis.json b/packages/subgraphs/govern-subgraph/manifest/data/gnosis.json index e6b255c0..e443158f 100644 --- a/packages/subgraphs/govern-subgraph/manifest/data/gnosis.json +++ b/packages/subgraphs/govern-subgraph/manifest/data/gnosis.json @@ -17,6 +17,12 @@ "startBlock": 25719047, "address": "0x6D8189C979bBB6768395A78E2AB8A15133459600", "customTemplate": "GovernQueueV2" + }, + { + "name": "GovernQueueV3", + "startBlock": 29612408, + "address": "0x8A33E3015F1a9aBdFd6822E218Eb725021D73EaC", + "customTemplate": "GovernQueueV2" } ] -} +} \ No newline at end of file diff --git a/packages/subgraphs/govern-subgraph/package.json b/packages/subgraphs/govern-subgraph/package.json index e530f3ff..76cf03b1 100644 --- a/packages/subgraphs/govern-subgraph/package.json +++ b/packages/subgraphs/govern-subgraph/package.json @@ -8,13 +8,15 @@ "prepare:gnosis": "node ./scripts/sync-with-last-deploy.js xdai", "manifest:goerli": "node ./scripts/mustache goerli", "manifest:gnosis": "node ./scripts/mustache gnosis", - "build": "graph codegen && graph build", + "build": "graph build", + "codegen": "graph codegen", "deploy:goerli": "dotenv -- cross-var yarn manifest:goerli && graph deploy corantin/govern-goerli --ipfs https://api.thegraph.com/ipfs/ --node https://api.thegraph.com/deploy/ --access-token %THE_GRAPH_ACCESS_TOKEN%", "deploy:goerli-staging": "dotenv -- cross-var yarn manifest:goerli && graph deploy corantin/govern-goerli-staging --ipfs https://api.thegraph.com/ipfs/ --node https://api.thegraph.com/deploy/ --access-token %THE_GRAPH_ACCESS_TOKEN%", "deploy:gnosis": "dotenv -- cross-var yarn manifest:gnosis && graph deploy corantin/govern-1hive-xdai --ipfs https://api.thegraph.com/ipfs/ --node https://api.thegraph.com/deploy/ --access-token %THE_GRAPH_ACCESS_TOKEN%", "deploy:gnosis-staging": "dotenv -- cross-var yarn manifest:gnosis && graph deploy corantin/govern-1hive-gnosis-staging --ipfs https://api.thegraph.com/ipfs/ --node https://api.thegraph.com/deploy/ --access-token %THE_GRAPH_ACCESS_TOKEN%", "create:local": "graph create corantin/govern-1hive-local --node http://localhost:8020", - "deploy:local": "graph deploy corantin/govern-1hive-local --ipfs http://0.0.0.0:5001 --node http://0.0.0.0:8020" + "deploy:local": "graph deploy corantin/govern-1hive-local --ipfs http://0.0.0.0:5001 --node http://0.0.0.0:8020", + "graph": "graph" }, "devDependencies": { "@graphprotocol/graph-cli": "^0.19.0", @@ -32,5 +34,8 @@ "inquirer": "^8.2.4", "js-yaml": "^4.1.0" }, + "resolutions": { + "concat-stream": "maxogden/concat-stream#2.0.0" + }, "gitHead": "aabbf6bd2dac11872ba9bb1f1dc8fffb6044aa7c" -} +} \ No newline at end of file diff --git a/packages/subgraphs/govern-subgraph/src/Govern.ts b/packages/subgraphs/govern-subgraph/src/Govern.ts index af5b36c5..14a03ee1 100644 --- a/packages/subgraphs/govern-subgraph/src/Govern.ts +++ b/packages/subgraphs/govern-subgraph/src/Govern.ts @@ -1,4 +1,4 @@ -import { Address, BigDecimal, BigInt } from "@graphprotocol/graph-ts"; +import { Address } from "@graphprotocol/graph-ts"; import { Executed as ExecutedEvent, Frozen as FrozenEvent, @@ -10,14 +10,14 @@ import { } from "../generated/Govern/Govern"; import { Govern, Deposit, Withdraw } from "../generated/schema"; import { frozenRoles, roleGranted, roleRevoked } from "./lib/MiniACL"; -import { loadOrCreateContainer } from "./GovernQueue"; +import { loadOrThrowContainer } from "./GovernQueue"; import { handleContainerEventExecute } from "./utils/events"; import { buildId, buildIndexedId } from "./utils/ids"; import { ZERO_ADDRESS } from "./utils/constants"; export function handleExecuted(event: ExecutedEvent): void { let govern = loadOrCreateGovern(event.address); - let container = loadOrCreateContainer(event.params.memo); + let container = loadOrThrowContainer(event.params.memo); handleContainerEventExecute(container, event); diff --git a/packages/subgraphs/govern-subgraph/src/GovernQueue.ts b/packages/subgraphs/govern-subgraph/src/GovernQueue.ts index eb63e993..94e78796 100644 --- a/packages/subgraphs/govern-subgraph/src/GovernQueue.ts +++ b/packages/subgraphs/govern-subgraph/src/GovernQueue.ts @@ -1,4 +1,11 @@ -import { Address, Bytes, BigInt, ipfs, json, log } from '@graphprotocol/graph-ts' +import { + Address, + Bytes, + BigInt, + ipfs, + json, + log, +} from "@graphprotocol/graph-ts"; import { Challenged as ChallengedEvent, Configured as ConfiguredEvent, @@ -8,11 +15,11 @@ import { Resolved as ResolvedEvent, Revoked as RevokedEvent, Scheduled as ScheduledEvent, - Vetoed as VetoedEvent -} from '../generated/GovernQueue/GovernQueue' + Vetoed as VetoedEvent, +} from "../generated/GovernQueue/GovernQueue"; -import { GovernQueue as GovernQueueContract } from '../generated/GovernQueue/GovernQueue' -import { getERC20Info } from './utils/tokens'; +import { GovernQueue as GovernQueueContract } from "../generated/GovernQueue/GovernQueue"; +import { getERC20Info } from "./utils/tokens"; import { Action, @@ -20,10 +27,10 @@ import { Config, Container, Payload, - GovernQueue -} from '../generated/schema' -import { frozenRoles, roleGranted, roleRevoked } from './lib/MiniACL' -import { buildId, buildIndexedId } from './utils/ids' + GovernQueue, +} from "../generated/schema"; +import { frozenRoles, roleGranted, roleRevoked } from "./lib/MiniACL"; +import { buildId, buildIndexedId } from "./utils/ids"; import { ZERO_ADDRESS, APPROVED_STATUS, @@ -32,288 +39,298 @@ import { EXECUTED_STATUS, NONE_STATUS, REJECTED_STATUS, - SCHEDULED_STATUS -} from './utils/constants' + SCHEDULED_STATUS, +} from "./utils/constants"; import { handleContainerEventChallenge, handleContainerEventResolve, handleContainerEventSchedule, - handleContainerEventVeto -} from './utils/events' + handleContainerEventVeto, +} from "./utils/events"; -import { loadOrCreateGovern } from './Govern' +import { loadOrCreateGovern } from "./Govern"; export function handleScheduled(event: ScheduledEvent): void { - let queue = loadOrCreateQueue(event.address) - let payload = loadOrCreatePayload(event.params.containerHash) - let container = loadOrCreateContainer(event.params.containerHash) - let executor = loadOrCreateGovern(event.params.payload.executor) + let queue = loadOrCreateQueue(event.address); + let payload = createPayload(event.params.containerHash); + let container = createContainer(event.params.containerHash); + let executor = loadOrCreateGovern(event.params.payload.executor); // Builds each of the actions bundled in the payload, // and saves them to the DB. - buildActions(event) + buildActions(event); + + payload.nonce = event.params.payload.nonce; + payload.executionTime = event.params.payload.executionTime; + payload.submitter = event.params.payload.submitter; + payload.executor = executor.id; + payload.allowFailuresMap = event.params.payload.allowFailuresMap; + payload.proof = event.params.payload.proof; - payload.nonce = event.params.payload.nonce - payload.executionTime = event.params.payload.executionTime - payload.submitter = event.params.payload.submitter - payload.executor = executor.id - payload.allowFailuresMap = event.params.payload.allowFailuresMap - payload.proof = event.params.payload.proof + let proofIpfsHex = event.params.payload.proof.toHexString().substring(2); - let proofIpfsHex = event.params.payload.proof.toHexString().substring(2) - // if cidString is ipfs v1 version hex from the cid's raw bytes and // we add `f` as a multibase prefix and remove `0x` - let result = ipfs.cat('f' + proofIpfsHex + "/metadata.json") + let result = ipfs.cat("f" + proofIpfsHex + "/metadata.json"); if (!result) { // if cidString is ipfs v0 version hex from the cid's raw bytes, // we add: // 1. 112 (0x70 in hex) which is dag-pb format. // 2. 01 because we want to use v1 version // 3. f since cidString is already hex, we only add `f` without converting anything. - result = ipfs.cat('f0170' + proofIpfsHex + '/metadata.json') + result = ipfs.cat("f0170" + proofIpfsHex + "/metadata.json"); } if (result) { // log.debug('title {}', [result.toHex()]) // let data = json.fromBytes(result as Bytes) // payload.title = data.toObject().get('title').toString() - payload.title = result.toHex() + payload.title = result.toHex(); } - container.payload = payload.id - container.state = SCHEDULED_STATUS - container.createdAt = event.block.timestamp + container.payload = payload.id; + container.state = SCHEDULED_STATUS; + container.createdAt = event.block.timestamp; // This should always be possible, as a queue without a config // should be impossible to get at this stage - container.config = queue.config - container.queue = queue.id - let config = loadConfig(queue.config) - let scheduleDeposit = loadCollateral(config.scheduleDeposit) + container.config = queue.config; + container.queue = queue.id; + let config = loadConfig(queue.config); + let scheduleDeposit = loadCollateral(config.scheduleDeposit); - handleContainerEventSchedule(container, event, scheduleDeposit as Collateral) + handleContainerEventSchedule(container, event, scheduleDeposit as Collateral); - executor.save() - payload.save() - container.save() - queue.save() + executor.save(); + payload.save(); + container.save(); + queue.save(); } export function handleExecuted(event: ExecutedEvent): void { - let container = loadOrCreateContainer(event.params.containerHash) - container.state = EXECUTED_STATUS - container.save() + let container = loadOrThrowContainer(event.params.containerHash); + container.state = EXECUTED_STATUS; + container.save(); } export function handleChallenged(event: ChallengedEvent): void { - let queue = loadOrCreateQueue(event.address) - let container = loadOrCreateContainer(event.params.containerHash) + let queue = loadOrCreateQueue(event.address); + let container = loadOrThrowContainer(event.params.containerHash); - container.state = CHALLENGED_STATUS + container.state = CHALLENGED_STATUS; - let resolver = Config.load(queue.config).resolver - let containerEvent = handleContainerEventChallenge(container, event, resolver) + let resolver = loadConfig(queue.config).resolver; + let containerEvent = handleContainerEventChallenge( + container, + event, + resolver + ); - containerEvent.save() - container.save() - queue.save() + containerEvent.save(); + container.save(); + queue.save(); } export function handleResolved(event: ResolvedEvent): void { - let container = loadOrCreateContainer(event.params.containerHash) + let container = loadOrThrowContainer(event.params.containerHash); - container.state = event.params.approved ? APPROVED_STATUS : REJECTED_STATUS + container.state = event.params.approved ? APPROVED_STATUS : REJECTED_STATUS; - handleContainerEventResolve(container, event) + handleContainerEventResolve(container, event); - container.save() + container.save(); } export function handleVetoed(event: VetoedEvent): void { - let queue = loadOrCreateQueue(event.address) - let container = loadOrCreateContainer(event.params.containerHash) + let queue = loadOrCreateQueue(event.address); + let container = loadOrThrowContainer(event.params.containerHash); - container.state = VETOED_STATUS + container.state = VETOED_STATUS; - handleContainerEventVeto(container, event) + handleContainerEventVeto(container, event); - container.save() - queue.save() + container.save(); + queue.save(); } export function handleConfigured(event: ConfiguredEvent): void { - let queue = loadOrCreateQueue(event.address) + let queue = loadOrCreateQueue(event.address); - let configId = buildId(event) - let config = new Config(configId) + let configId = buildId(event); + let config = new Config(configId); let scheduleDeposit = new Collateral( buildIndexedId(event.transaction.hash.toHex(), 1) - ) - scheduleDeposit.token = event.params.config.scheduleDeposit.token - scheduleDeposit.amount = event.params.config.scheduleDeposit.amount + ); + scheduleDeposit.token = event.params.config.scheduleDeposit.token; + scheduleDeposit.amount = event.params.config.scheduleDeposit.amount; let challengeDeposit = new Collateral( buildIndexedId(event.transaction.hash.toHex(), 2) - ) - challengeDeposit.token = event.params.config.challengeDeposit.token - challengeDeposit.amount = event.params.config.challengeDeposit.amount + ); + challengeDeposit.token = event.params.config.challengeDeposit.token; + challengeDeposit.amount = event.params.config.challengeDeposit.amount; // Grab Schedule Token info - let data = getERC20Info(event.params.config.scheduleDeposit.token) + let data = getERC20Info(event.params.config.scheduleDeposit.token); scheduleDeposit.decimals = data.decimals; scheduleDeposit.name = data.name; scheduleDeposit.symbol = data.symbol; // Grab challenge Token info - data = getERC20Info(event.params.config.challengeDeposit.token) + data = getERC20Info(event.params.config.challengeDeposit.token); challengeDeposit.decimals = data.decimals; challengeDeposit.name = data.name; challengeDeposit.symbol = data.symbol; - config.executionDelay = event.params.config.executionDelay - config.scheduleDeposit = scheduleDeposit.id - config.challengeDeposit = challengeDeposit.id - config.resolver = event.params.config.resolver - config.rules = event.params.config.rules - config.maxCalldataSize = event.params.config.maxCalldataSize + config.executionDelay = event.params.config.executionDelay; + config.scheduleDeposit = scheduleDeposit.id; + config.challengeDeposit = challengeDeposit.id; + config.resolver = event.params.config.resolver; + config.rules = event.params.config.rules; + config.maxCalldataSize = event.params.config.maxCalldataSize; - queue.config = config.id + queue.config = config.id; - scheduleDeposit.save() - challengeDeposit.save() - config.save() - queue.save() + scheduleDeposit.save(); + challengeDeposit.save(); + config.save(); + queue.save(); } // MiniACL Events export function handleFrozen(event: FrozenEvent): void { - let queue = loadOrCreateQueue(event.address) + let queue = loadOrCreateQueue(event.address); - let roles = queue.roles! + let roles = queue.roles!; - frozenRoles(roles, event.params.role) + frozenRoles(roles, event.params.role); } export function handleGranted(event: GrantedEvent): void { - let queue = loadOrCreateQueue(event.address) + let queue = loadOrCreateQueue(event.address); - let role = roleGranted(event.address, event.params.role, event.params.who) + let role = roleGranted(event.address, event.params.role, event.params.who); // add the role - let currentRoles = queue.roles - currentRoles.push(role.id) - queue.roles = currentRoles + let currentRoles = queue.roles; + currentRoles.push(role.id); + queue.roles = currentRoles; - queue.save() + queue.save(); } export function handleRevoked(event: RevokedEvent): void { - let queue = loadOrCreateQueue(event.address) + let queue = loadOrCreateQueue(event.address); - let role = roleRevoked(event.address, event.params.role, event.params.who) + let role = roleRevoked(event.address, event.params.role, event.params.who); // add the role - let currentRoles = queue.roles - currentRoles.push(role.id) - queue.roles = currentRoles + let currentRoles = queue.roles; + currentRoles.push(role.id); + queue.roles = currentRoles; - queue.save() + queue.save(); } // create a dummy config when creating queue to avoid not-null error export function createDummyConfig(queueId: string): string { - let ZERO = BigInt.fromI32(0) - - let configId = queueId - let config = new Config(configId) - - let scheduleDeposit = new Collateral(buildIndexedId(configId, 1)) - scheduleDeposit.token = ZERO_ADDRESS - scheduleDeposit.amount = ZERO - - let challengeDeposit = new Collateral(buildIndexedId(configId, 2)) - challengeDeposit.token = ZERO_ADDRESS - challengeDeposit.amount = ZERO - - config.executionDelay = ZERO - config.scheduleDeposit = scheduleDeposit.id - config.challengeDeposit = challengeDeposit.id - config.resolver = ZERO_ADDRESS - config.rules = Bytes.fromI32(0) as Bytes - config.maxCalldataSize = BigInt.fromI32(0) - scheduleDeposit.save() - challengeDeposit.save() - config.save() - - return config.id! + let ZERO = BigInt.fromI32(0); + + let configId = queueId; + let config = new Config(configId); + + let scheduleDeposit = new Collateral(buildIndexedId(configId, 1)); + scheduleDeposit.token = ZERO_ADDRESS; + scheduleDeposit.amount = ZERO; + + let challengeDeposit = new Collateral(buildIndexedId(configId, 2)); + challengeDeposit.token = ZERO_ADDRESS; + challengeDeposit.amount = ZERO; + + config.executionDelay = ZERO; + config.scheduleDeposit = scheduleDeposit.id; + config.challengeDeposit = challengeDeposit.id; + config.resolver = ZERO_ADDRESS; + config.rules = Bytes.fromI32(0) as Bytes; + config.maxCalldataSize = BigInt.fromI32(0); + scheduleDeposit.save(); + challengeDeposit.save(); + config.save(); + + return config.id!; } export function loadOrCreateQueue(queueAddress: Address): GovernQueue { - let queueId = queueAddress.toHex() + let queueId = queueAddress.toHex(); // Create queue - let queue = GovernQueue.load(queueId) + let queue = GovernQueue.load(queueId); if (queue === null) { - queue = new GovernQueue(queueId) - queue.address = queueAddress - queue.config = createDummyConfig(queueId) - queue.roles = [] + queue = new GovernQueue(queueId); + queue.address = queueAddress; + queue.config = createDummyConfig(queueId); + queue.roles = []; } - queue.nonce = GovernQueueContract.bind(queueAddress).nonce() + queue.nonce = GovernQueueContract.bind(queueAddress).nonce(); + + return queue!; +} - return queue! +export function createContainer(containerHash: Bytes): Container { + let ContainerId = containerHash.toHex(); + let container = new Container(ContainerId); + container.state = NONE_STATUS; + return container; } -export function loadOrCreateContainer(containerHash: Bytes): Container { - let ContainerId = containerHash.toHex() +export function loadOrThrowContainer(containerHash: Bytes): Container { + let ContainerId = containerHash.toHex(); // Create container - let container = Container.load(ContainerId) + let container = Container.load(ContainerId); if (container === null) { - container = new Container(ContainerId) - container.state = NONE_STATUS + throw new Error("Container not found with hash :" + containerHash); } - return container! + return container!; } -function loadOrCreatePayload(containerHash: Bytes): Payload { - let PayloadId = containerHash.toHex() +function createPayload(containerHash: Bytes): Payload { + let PayloadId = containerHash.toHex(); // Create payload - let payload = Payload.load(PayloadId) + let payload = Payload.load(PayloadId); if (payload === null) { - payload = new Payload(PayloadId) + payload = new Payload(PayloadId); } - return payload! + return payload!; } function loadConfig(configAddress: string): Config { - let config = Config.load(configAddress) + let config = Config.load(configAddress); if (config === null) { - throw new Error('Config not found.') + throw new Error("Config not found."); } - return config! + return config!; } function loadCollateral(collateralAddress: string): Collateral { - let collateral = Collateral.load(collateralAddress) + let collateral = Collateral.load(collateralAddress); if (collateral === null) { - throw new Error('Collateral not found.') + throw new Error("Collateral not found."); } - return collateral! + return collateral!; } function buildActions(event: ScheduledEvent): void { - let actions = event.params.payload.actions + let actions = event.params.payload.actions; for (let index = 0; index < actions.length; index++) { - let actionId = buildIndexedId(event.params.containerHash.toHex(), index) - let action = new Action(actionId) + let actionId = buildIndexedId(event.params.containerHash.toHex(), index); + let action = new Action(actionId); - action.to = actions[index].to - action.value = actions[index].value - action.data = actions[index].data - action.payload = event.params.containerHash.toHex() + action.to = actions[index].to; + action.value = actions[index].value; + action.data = actions[index].data; + action.payload = event.params.containerHash.toHex(); - action.save() + action.save(); } } diff --git a/packages/subgraphs/govern-subgraph/src/GovernRegistry.ts b/packages/subgraphs/govern-subgraph/src/GovernRegistry.ts deleted file mode 100644 index 16617967..00000000 --- a/packages/subgraphs/govern-subgraph/src/GovernRegistry.ts +++ /dev/null @@ -1,65 +0,0 @@ -import { Address } from '@graphprotocol/graph-ts' -import { - Registered as RegisteredEvent, - SetMetadata as SetMetadataEvent, -} from '../generated/GovernRegistry/GovernRegistry' -import { - Govern as GovernTemplate, - GovernQueue as GovernQueueTemplate, -} from '../generated/templates' -import { GovernRegistry, Dao } from '../generated/schema' -import { loadOrCreateGovern } from './Govern' -import { loadOrCreateQueue } from './GovernQueue' - -export function handleRegistered(event: RegisteredEvent): void { - let registry = loadOrCreateRegistry(event.address) - - let queue = loadOrCreateQueue(event.params.queue) - let govern = loadOrCreateGovern(event.params.executor) - - queue.save() - govern.save() - let dao = new Dao(event.params.name) - - dao.name = event.params.name - dao.executor = event.params.executor.toHex() - dao.queue = event.params.queue.toHex() - dao.token = event.params.token.toHex() - dao.minter = event.params.minter.toHex() - dao.registrant = event.params.registrant.toHex() - dao.createdAt = event.block.timestamp - - // add dao to the registry - let currentDAOs = registry.daos - currentDAOs.push(dao.id) - registry.daos = currentDAOs - - registry.count += 1 - - dao.save() - registry.save() - - // Create datasource templates - GovernTemplate.create(event.params.executor) - GovernQueueTemplate.create(event.params.queue) -} - -export function handleSetMetadata(event: SetMetadataEvent): void { - let govern = loadOrCreateGovern(event.params.executor) - govern.metadata = event.params.metadata - - govern.save() -} - -export function loadOrCreateRegistry(registryAddress: Address): GovernRegistry { - let registryId = registryAddress.toHex() - let registry = GovernRegistry.load(registryId) - - if (registry === null) { - registry = new GovernRegistry(registryId) - registry.address = registryAddress - registry.count = 0 - registry.daos = [] - } - return registry! -} diff --git a/packages/subgraphs/govern-subgraph/subgraph.yaml b/packages/subgraphs/govern-subgraph/subgraph.yaml index 933161a0..e1475c5c 100644 --- a/packages/subgraphs/govern-subgraph/subgraph.yaml +++ b/packages/subgraphs/govern-subgraph/subgraph.yaml @@ -91,6 +91,50 @@ dataSources: abi: GovernQueue address: "0x6D8189C979bBB6768395A78E2AB8A15133459600" startBlock: 25719047 + mapping: + kind: ethereum/events + apiVersion: 0.0.4 + language: wasm/assemblyscript + entities: + - Collateral + - Config + - Container + - ContainerEvent + - Payload + - Role + abis: + - name: GovernQueue + file: ./govern-core/abi/contracts/pipelines/GovernQueue.sol/GovernQueue.json + - name: ERC20 + file: ./govern-contract-utils/abi/contracts/erc20/ERC20.sol/ERC20.json + eventHandlers: + - event: Configured(indexed bytes32,indexed address,(uint256,(address,uint256),(address,uint256),address,bytes,uint256)) + handler: handleConfigured + - event: Frozen(indexed bytes4,indexed address) + handler: handleFrozen + - event: Granted(indexed bytes4,indexed address,indexed address,address) + handler: handleGranted + - event: Scheduled(indexed bytes32,(uint256,uint256,address,address,(address,uint256,bytes)[],bytes32,bytes)) + handler: handleScheduled + - event: Executed(indexed bytes32,indexed address) + handler: handleExecuted + - event: Challenged(indexed bytes32,indexed address,bytes,uint256,(address,uint256)) + handler: handleChallenged + - event: Vetoed(indexed bytes32,indexed address,bytes) + handler: handleVetoed + - event: Resolved(indexed bytes32,indexed address,bool) + handler: handleResolved + - event: Revoked(indexed bytes4,indexed address,indexed address) + handler: handleRevoked + file: ./src/GovernQueue.ts + # Only deployed for contract verification purpose + - kind: ethereum/contract + name: GovernQueueV3 + network: gnosis + source: + abi: GovernQueue + address: "0x8A33E3015F1a9aBdFd6822E218Eb725021D73EaC" + startBlock: 29612408 mapping: kind: ethereum/events apiVersion: 0.0.4