Skip to content

Commit 4827631

Browse files
authored
Merge pull request #910 from graphprotocol/pcv/graphgovernance-cleanup
fix: remove remaining usage of the removed GraphGovernance contract
2 parents 23ad89c + 8d92009 commit 4827631

File tree

7 files changed

+7
-129
lines changed

7 files changed

+7
-129
lines changed

packages/contracts/cli/commands/contracts/governance.ts

Lines changed: 0 additions & 121 deletions
This file was deleted.

packages/contracts/cli/commands/contracts/index.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ import { gnsCommand } from './gns'
77
import { graphTokenCommand } from './graphToken'
88
import { stakingCommand } from './staking'
99
import { anyCommand } from './any'
10-
import { governanceCommand } from './governance'
1110

1211
import { disputeManagerCommand } from './disputeManager'
1312

@@ -24,7 +23,6 @@ export const contractsCommand = {
2423
.command(stakingCommand)
2524
.command(anyCommand)
2625
.command(disputeManagerCommand)
27-
.command(governanceCommand)
2826
},
2927
handler: (): void => {
3028
yargs.showHelp()

packages/contracts/cli/contracts.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@ import { GraphToken } from '../build/types/GraphToken'
3131
import { Controller } from '../build/types/Controller'
3232
import { BancorFormula } from '../build/types/BancorFormula'
3333
import { IENS } from '../build/types/IENS'
34-
import { GraphGovernance } from '../build/types/GraphGovernance'
3534
import { AllocationExchange } from '../build/types/AllocationExchange'
3635
import { SubgraphNFT } from '../build/types/SubgraphNFT'
3736
import { GraphCurationToken } from '../build/types/GraphCurationToken'
@@ -60,7 +59,6 @@ export interface NetworkContracts {
6059
Controller: Controller
6160
BancorFormula: BancorFormula
6261
IENS: IENS
63-
GraphGovernance: GraphGovernance
6462
AllocationExchange: AllocationExchange
6563
SubgraphNFT: SubgraphNFT
6664
SubgraphNFTDescriptor: SubgraphNFTDescriptor

packages/contracts/e2e/scenarios/open-allocations.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ describe('Open allocations', () => {
3535
})
3636

3737
describe('Allocations', () => {
38-
it(`allocatons should be open`, async function () {
38+
it(`allocations should be open`, async function () {
3939
const allocations = indexerFixtures.map((i) => i.allocations).flat()
4040
for (const allocation of allocations) {
4141
const state = await Staking.getAllocationState(allocation.signer.address)

packages/contracts/scripts/clean

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ echo "Cleaning flattened contracts..."
88

99
FLATTENED_FILES=(
1010
"$OUT_DIR/Controller.sol"
11-
"$OUT_DIR/GraphGovernance.sol"
1211
"$OUT_DIR/GNS.sol"
1312
"$OUT_DIR/ServiceRegistry.sol"
1413
"$OUT_DIR/Curation.sol"
@@ -27,4 +26,4 @@ for path in ${FLATTENED_FILES[@]}; do
2726
-e "s|// SPDX-License-Identifier:.*||g" \
2827
-e 's|pragma abicoder v2;|//pragma abicoder v2;|g' \
2928
-e '1s|^|pragma abicoder v2;\n|' $path
30-
done
29+
done

packages/contracts/scripts/flatten

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ echo "Flattening contracts..."
88

99
FILES=(
1010
"contracts/governance/Controller.sol"
11-
"contracts/governance/GraphGovernance.sol"
1211
"contracts/discovery/GNS.sol"
1312
"contracts/discovery/ServiceRegistry.sol"
1413
"contracts/curation/Curation.sol"

packages/sdk/src/deployments/network/actions/staking.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,13 +48,18 @@ export const allocateFrom: GraphNetworkAction<{
4848
const metadata = ethers.constants.HashZero
4949

5050
console.log(`\nAllocating ${amount} tokens on ${allocationId}...`)
51+
let extraArgs: ethers.Overrides = {}
52+
if (process.env.CI) {
53+
extraArgs.gasLimit = BigNumber.from('400000')
54+
}
5155
const tx = await contracts.Staking.connect(indexer).allocateFrom(
5256
indexer.address,
5357
subgraphDeploymentID,
5458
amount,
5559
allocationId,
5660
metadata,
5761
proof,
62+
extraArgs
5863
)
5964
await tx.wait()
6065
}

0 commit comments

Comments
 (0)