forked from graphprotocol/graph-network-subgraph
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bug fixes to get deployed subgraph to not crash
- Loading branch information
Showing
14 changed files
with
174 additions
and
86 deletions.
There are no files selected for viewing
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,14 @@ | ||
{ | ||
"graphToken": "0x45650e899F2b25844d5ad7f0020159729341Cf27", | ||
"epochManager": "0x6CAfB9BFf2a3a2c4CEE43E9D32273254823eE8D1", | ||
"disputeManager": "0xecFaddaA75de349F85a7998E3F3b0C85E24c14a3", | ||
"staking": "0x65c72ab13Ba6805414c1eCBeA34bb95e1e58515F", | ||
"curation": "0xF4061Af18E397B05909098E1895184d7049e115C", | ||
"rewardsManager": "0x023E5A34A4b569Ec655c2dE429945E703Af2aE2a", | ||
"serviceRegistry": "0x0AD791CBC700eAecd34f017A6e40E3516daC61fE", | ||
"gns": "0x8CAB8e3ccf1Dca2d4173272E516D8981a5833238", | ||
"ens": "0xB66B2f307B6e46a6D038a85997B401aE87455772", | ||
"graphToken": "0xa887a968BDb0e42D3Ffc2d6ff253568c6d2CaF34", | ||
"epochManager": "0xFd12A3ee8Bf3C417e0cedbc591BA10156724C069", | ||
"disputeManager": "0x449B394836881CA995d4db4313064a66aF5Ca0b0", | ||
"staking": "0xFC6CCBa00ceA43512cC50f6f8CC029E782c5AC96", | ||
"curation": "0x17F93B680C293308C1bA4C647a2823e175E32818", | ||
"rewardsManager": "0x20AbE3B457e510EEF66D2518212A6f862E1ebfA9", | ||
"serviceRegistry": "0x3f721A12d82A5A8a5132e93d6f0707031E4810E4", | ||
"gns": "0x497609273754d77F354B26f7CCbb30a78468B00c", | ||
"ens": "0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e", | ||
"ensPublicResolver": "0xc30F6CCc48F1eA5374aC618dfe5243ddD1e264E7", | ||
"blockNumber": "19750000", | ||
"network": "kovan" | ||
"blockNumber": "6900000", | ||
"network": "rinkeby" | ||
} |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
import * as fs from 'fs' | ||
|
||
import * as networkAddresses from '@graphprotocol/contracts/addresses.json' | ||
import * as mustache from 'mustache' | ||
|
||
// mustache doesn't like numbered object keys | ||
// TODO - get the contracts to not import with number from npm package | ||
let renameAddresses: any = networkAddresses | ||
renameAddresses['ourRinkeby'] = networkAddresses['4'] | ||
|
||
export interface Addresses { | ||
graphToken: string | ||
epochManager: string | ||
disputeManager: string | ||
staking: string | ||
curation: string | ||
rewardsManager: string | ||
serviceRegistry: string | ||
gns: string | ||
ens: string | ||
ensPublicResolver: string | ||
} | ||
|
||
export let addresses: Addresses = { | ||
graphToken: '{{ourRinkeby.GraphToken.address}}', | ||
epochManager: '{{ourRinkeby.EpochManager.address}}', | ||
disputeManager: '{{ourRinkeby.DisputeManager.address}}', | ||
staking: '{{ourRinkeby.Staking.address}}', | ||
curation: '{{ourRinkeby.Curation.address}}', | ||
rewardsManager: '{{ourRinkeby.RewardsManager.address}}', | ||
serviceRegistry: '{{ourRinkeby.ServiceRegistry.address}}', | ||
gns: '{{ourRinkeby.GNS.address}}', | ||
ens: '{{rinkeby.ens}}', | ||
ensPublicResolver: '{{rinkeby.ensPublicResolver}}', | ||
} | ||
|
||
const main = (): void => { | ||
try { | ||
let output = JSON.parse(mustache.render(JSON.stringify(addresses), renameAddresses)) | ||
output.blockNumber = '6900000' | ||
output.network = 'rinkeby' // Todo - make dynamic | ||
fs.writeFileSync(__dirname + '/generatedAddresses.json', JSON.stringify(output, null, 2)) | ||
} catch (e) { | ||
console.log(`Error saving artifacts: ${e.message}`) | ||
} | ||
} | ||
|
||
main() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.