@reality.eth/contracts 3.0.35 → 3.0.37

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,6 @@
1
+ {
2
+ "address": "0x569Dcc6d797265Da700926fe8D10c0DA01717386",
3
+ "block": 1281264,
4
+ "notes": null,
5
+ "arbitrators": {}
6
+ }
@@ -0,0 +1,8 @@
1
+ {
2
+ "address": "0x83d3f4769a19f1b43337888b0290f5473cf508b2",
3
+ "block": 42899867 ,
4
+ "token_address": "0x996F19d4b1cE6D5AD72CEaaa53152CEB1B187fD0",
5
+ "notes": null,
6
+ "arbitrators": {
7
+ }
8
+ }
@@ -32,10 +32,6 @@
32
32
  "explorerURL": "https://optimistic.etherscan.io",
33
33
  "graphURL": "https://api.thegraph.com/subgraphs/name/realityeth/realityeth-optimism"
34
34
  },
35
- "42": {
36
- "explorerURL": "https://kovan.etherscan.io",
37
- "graphURL": "https://api.thegraph.com/subgraphs/name/realityeth/realityeth-kovan"
38
- },
39
35
  "56": {
40
36
  "explorerURL": "https://www.bscscan.com",
41
37
  "graphURL": "https://api.thegraph.com/subgraphs/name/realityeth/realityeth-bsc",
@@ -81,6 +77,11 @@
81
77
  "explorerURL": "https://zksync2-testnet.zkscan.io",
82
78
  "network_name": "zkSync2-testnet"
83
79
  },
80
+ "1101": {
81
+ "hostedRPC": "https://zkevm-rpc.com",
82
+ "explorerURL": "https://zkevm.polygonscan.com/",
83
+ "network_name": "polygon-zkevm"
84
+ },
84
85
  "80001": {
85
86
  "hostedRPC": "https://rpc.ankr.com/polygon_mumbai",
86
87
  "graphURL": "https://api.thegraph.com/subgraphs/name/realityeth/realityeth-mumbai",
@@ -105,25 +105,6 @@
105
105
  "https://optimistic.etherscan.io"
106
106
  ]
107
107
  },
108
- "42": {
109
- "chainId": "0x2a",
110
- "chainName": "Kovan",
111
- "nativeCurrency": {
112
- "name": "Kovan Ether",
113
- "symbol": "ETH",
114
- "decimals": 18
115
- },
116
- "rpcUrls": [
117
- "https://kovan.poa.network",
118
- "http://kovan.poa.network:8545",
119
- "ws://kovan.poa.network:8546"
120
- ],
121
- "hostedRPC": "https://kovan.poa.network",
122
- "graphURL": "https://api.thegraph.com/subgraphs/name/realityeth/realityeth-kovan",
123
- "blockExplorerUrls": [
124
- "https://kovan.etherscan.io"
125
- ]
126
- },
127
108
  "56": {
128
109
  "chainId": "0x38",
129
110
  "chainName": "Binance Smart Chain Mainnet",
@@ -222,15 +203,19 @@
222
203
  "chainName": "Gnosis",
223
204
  "nativeCurrency": {
224
205
  "name": "xDAI",
225
- "symbol": "xDAI",
206
+ "symbol": "XDAI",
226
207
  "decimals": 18
227
208
  },
228
209
  "network_name": "gnosis",
229
210
  "rpcUrls": [
230
211
  "https://rpc.gnosischain.com",
212
+ "https://rpc.gnosis.gateway.fm",
231
213
  "https://rpc.ankr.com/gnosis",
232
214
  "https://gnosischain-rpc.gateway.pokt.network",
233
215
  "https://gnosis-mainnet.public.blastapi.io",
216
+ "https://gnosis.api.onfinality.io/public",
217
+ "https://gnosis.blockpi.network/v1/rpc/public",
218
+ "https://web3endpoints.com/gnosischain-mainnet",
234
219
  "wss://rpc.gnosischain.com/wss"
235
220
  ],
236
221
  "hostedRPC": "https://rpc.gnosischain.com",
@@ -320,6 +305,24 @@
320
305
  "https://explore.cheapswap.io/"
321
306
  ]
322
307
  },
308
+ "1101": {
309
+ "chainId": "0x44d",
310
+ "chainName": "Polygon zkEVM",
311
+ "nativeCurrency": {
312
+ "name": "Ether",
313
+ "symbol": "ETH",
314
+ "decimals": 18
315
+ },
316
+ "network_name": "polygon-zkevm",
317
+ "rpcUrls": [
318
+ "https://zkevm-rpc.com"
319
+ ],
320
+ "hostedRPC": "https://zkevm-rpc.com",
321
+ "blockExplorerUrls": [
322
+ "https://zkevm.polygonscan.com",
323
+ "https://zkevm.polygonscan.com/"
324
+ ]
325
+ },
323
326
  "42161": {
324
327
  "chainId": "0xa4b1",
325
328
  "chainName": "Arbitrum One",
@@ -429,7 +432,7 @@
429
432
  "hostedRPC": "https://alpha-rpc.scroll.io/l2",
430
433
  "blockExplorerUrls": [
431
434
  "https://blockscout.scroll.io",
432
- "https://scrollexplorer.unifra.io"
435
+ "https://scrollscan.co"
433
436
  ]
434
437
  },
435
438
  "1337702": {
@@ -184,52 +184,6 @@
184
184
  }
185
185
  }
186
186
  },
187
- "42": {
188
- "ETH": {
189
- "RealityETH-2.0": {
190
- "address": "0x50e35a1ed424ab9c0b8c7095b3d9ec2fb791a168",
191
- "block": 0,
192
- "token_address": null,
193
- "notes": null,
194
- "arbitrators": {
195
- "0xB4683794998215B59a429e86c3A33F796F9aeb0f": "Reality.eth Team (dev)",
196
- "0xDEd12537dA82C1019b3CA1714A5d58B7c5c19A04": "Kleros"
197
- }
198
- },
199
- "RealityETH-3.0": {
200
- "address": "0xcB71745d032E16ec838430731282ff6c10D29Dea",
201
- "block": 27103177,
202
- "notes": null,
203
- "arbitrators": {
204
- "0x99489d7bb33539f3d1a401741e56e8f02b9ae0cf": "Kleros (General Court)",
205
- "0xb9fdd2904cbcc5543F02DB948B2CE59Ef10A950E": "Kleros DAO Governance (Technical Court)"
206
- }
207
- }
208
- },
209
- "POLK": {
210
- "Arbitrator": {
211
- "address": "0x9046D057D7957A2A93d55C711EBC5B62d812a5b8",
212
- "block": 25399305,
213
- "reality_eth_address": "0x1346800BC8915536B9eaa388fa9A6B93398E5999"
214
- },
215
- "RealityETH_ERC20-2.0": {
216
- "address": "0x1346800BC8915536B9eaa388fa9A6B93398E5999",
217
- "block": 25355307,
218
- "token_address": "0x222E11E134F9AB3750812b37F0DA51B4467EaA7a",
219
- "notes": null,
220
- "arbitrators": {
221
- "0x9046D057D7957A2A93d55C711EBC5B62d812a5b8": "Test POLK arbitrator (reality.eth)"
222
- }
223
- },
224
- "RealityETH_ERC20-3.0": {
225
- "address": "0xe9CF05F9F664b88160D5658619c028D1EEb00fc7",
226
- "block": 27103188,
227
- "token_address": "0x222E11E134F9AB3750812b37F0DA51B4467EaA7a",
228
- "notes": null,
229
- "arbitrators": {}
230
- }
231
- }
232
- },
233
187
  "56": {
234
188
  "BNB": {
235
189
  "Arbitrator": {
@@ -373,6 +327,15 @@
373
327
  "0x5AFa42b30955f137e10f89dfb5EF1542a186F90e": "Kleros"
374
328
  }
375
329
  }
330
+ },
331
+ "POLK": {
332
+ "RealityETH_ERC20-3.0": {
333
+ "address": "0x83d3f4769a19f1b43337888b0290f5473cf508b2",
334
+ "block": 42899867,
335
+ "token_address": "0x996F19d4b1cE6D5AD72CEaaa53152CEB1B187fD0",
336
+ "notes": null,
337
+ "arbitrators": {}
338
+ }
376
339
  }
377
340
  },
378
341
  "280": {
@@ -405,6 +368,16 @@
405
368
  }
406
369
  }
407
370
  },
371
+ "1101": {
372
+ "ETH": {
373
+ "RealityETH-3.0": {
374
+ "address": "0x569Dcc6d797265Da700926fe8D10c0DA01717386",
375
+ "block": 1281264,
376
+ "notes": null,
377
+ "arbitrators": {}
378
+ }
379
+ }
380
+ },
408
381
  "42161": {
409
382
  "ARETH": {
410
383
  "Arbitrator": {
@@ -40,6 +40,7 @@
40
40
  "42": true,
41
41
  "280": true,
42
42
  "324": true,
43
+ "1101": true,
43
44
  "534353": true,
44
45
  "1337702": true,
45
46
  "11155111": true
@@ -110,6 +111,7 @@
110
111
  "small_number": 1000000000000000000,
111
112
  "erc20_chains": {
112
113
  "42": "0x222E11E134F9AB3750812b37F0DA51B4467EaA7a",
114
+ "137": "0x996F19d4b1cE6D5AD72CEaaa53152CEB1B187fD0",
113
115
  "80001": "0x935f82d011ee37e8870c435417ac58407a9863f7"
114
116
  }
115
117
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@reality.eth/contracts",
3
- "version": "3.0.35",
3
+ "version": "3.0.37",
4
4
  "description": "Collection of smart contracts for the Realitio fact verification platform",
5
5
  "scripts": {
6
6
  "generate-chains": "node scripts/generate_chains_json.js",
@@ -30,7 +30,7 @@
30
30
  "url": "https://github.com/RealityETH/monorepo/issues"
31
31
  },
32
32
  "homepage": "https://reality.eth.link",
33
- "gitHead": "29623f7c2b40f2415018f4cb40054582fb9876a0",
33
+ "gitHead": "08756ff6e9dfae871e63dfa1f66fcdc39c75d658",
34
34
  "dependencies": {
35
35
  "ethers": "^5.6.8"
36
36
  }
@@ -0,0 +1,81 @@
1
+ if (process.argv.length < 3) {
2
+ throw new Error("Usage: node add_chain_token.js <chain_id> <chain_name> [<token_ticker>] [<token_address_or_native>] [<small_amount_of_token>]");
3
+ }
4
+
5
+ const project_base = __dirname + '/../';
6
+
7
+ const fs = require('fs');
8
+
9
+ const chain_id = process.argv[2];
10
+
11
+ // These may be empty
12
+ const chain_name = process.argv[3];
13
+ const token_ticker = process.argv[4];
14
+ const token_address = process.argv[5];
15
+ const small_number = process.argv[6];
16
+
17
+ console.log('chain id is', chain_id);
18
+
19
+ const supported_file = 'chains/supported.json'
20
+
21
+ const chains_file = 'chains/chainid.network.json';
22
+ const chains_local_file = 'chains/chainid.network.local.json';
23
+
24
+ const chain_id_list = require(project_base + chains_file);
25
+ const chain_id_list_local = require(project_base + chains_local_file);
26
+
27
+ let supported_data = require(project_base + supported_file);
28
+
29
+ for(var cl = 0; cl<chain_id_list_local.length; cl++) {
30
+ chain_id_list.push(chain_id_list_local[cl]);
31
+ }
32
+
33
+ let found = false;
34
+ for(var cl = 0; cl<chain_id_list.length; cl++) {
35
+ if (chain_id == chain_id_list[cl].chainId) {
36
+ found = true;
37
+ break;
38
+ }
39
+ }
40
+
41
+ if (!found) {
42
+ throw new Error("The chain ID "+chain_id+" was not found in the chainid list. Run node fetch_and_reformat_chains_json.js to update the list, or add your settings to chainid.network.local.json.");
43
+ }
44
+ if (""+chain_id in supported_data) {
45
+ console.log('Using existing config for chain '+chain_id);
46
+ console.log(supported_data[""+chain_id]);
47
+ } else {
48
+ console.log('Creating new supported entry for chain '+chain_id);
49
+ supported_data[""+chain_id] = {"network_name": chain_name};
50
+ }
51
+
52
+ const out = JSON.stringify(supported_data, null, 4);
53
+ fs.writeFileSync(project_base+supported_file, out);
54
+
55
+ if (token_ticker != '') {
56
+
57
+ let token_config = {};
58
+ const token_file = project_base + 'tokens/' + token_ticker + '.json';
59
+ try {
60
+ token_config = JSON.parse(fs.readFileSync(token_file));
61
+ console.log(token_config);
62
+ } catch (e) {
63
+ token_config = {
64
+ "decimals": 18,
65
+ "small_number": small_number ? small_number : 10000000000000000
66
+ }
67
+ }
68
+ if (token_address == 'native') {
69
+ token_config['native_chains'] = 'native_chains' in token_config ? token_config['native_chains'] : {};
70
+ token_config['native_chains'][""+chain_id] = true;
71
+ } else {
72
+ token_config['erc20_chains'] = 'erc20_chains' in token_config ? token_config['erc20_chains'] : {};
73
+ token_config['erc20_chains'][""+chain_id] = token_address;
74
+ }
75
+
76
+ console.log(token_config);
77
+
78
+ const out2 = JSON.stringify(token_config, null, 4);
79
+ fs.writeFileSync(token_file, out2);
80
+
81
+ }
package/scripts/deploy.js CHANGED
@@ -56,7 +56,7 @@ const chains = {
56
56
  'gnosis': 100,
57
57
  'scroll-alpha-testnet': 534353,
58
58
  'polygon': 137,
59
- 'hermez': 1101,
59
+ 'polygon-zkevm': 1101,
60
60
  'mumbai': 80001,
61
61
  'ava': 43114,
62
62
  'arbitrum': 42161,
@@ -73,7 +73,7 @@ const non_infura_chains = {
73
73
  'bsc': 'https://bsc-dataseed.binance.org',
74
74
  'chapel': 'https://bsc-testnet.public.blastapi.io',
75
75
  'polygon': 'https://rpc-mainnet.maticvigil.com',
76
- 'hermez': 'https://rpc.ankr.com/polygon_zkevm',
76
+ 'polygon-zkevm': 'https://zkevm-rpc.com',
77
77
  'ava': 'https://api.avax.network/ext/bc/C/rpc',
78
78
  'arbitrum': 'https://arb1.arbitrum.io/rpc',
79
79
  'arbitrum-rinkeby': 'https://rinkeby.arbitrum.io/rpc',
package/tokens/ETH.json CHANGED
@@ -8,6 +8,7 @@
8
8
  "42": true,
9
9
  "280": true,
10
10
  "324": true,
11
+ "1101": true,
11
12
  "534353": true,
12
13
  "1337702": true,
13
14
  "11155111": true
package/tokens/POLK.json CHANGED
@@ -3,6 +3,7 @@
3
3
  "small_number": 1000000000000000000,
4
4
  "erc20_chains": {
5
5
  "42": "0x222E11E134F9AB3750812b37F0DA51B4467EaA7a",
6
+ "137": "0x996F19d4b1cE6D5AD72CEaaa53152CEB1B187fD0",
6
7
  "80001": "0x935f82d011ee37e8870c435417ac58407a9863f7"
7
8
  }
8
9
  }
@@ -1,10 +0,0 @@
1
- {
2
- "address": "0x50e35a1ed424ab9c0b8c7095b3d9ec2fb791a168",
3
- "block": 0,
4
- "token_address": null,
5
- "notes": null,
6
- "arbitrators": {
7
- "0xB4683794998215B59a429e86c3A33F796F9aeb0f": "Reality.eth Team (dev)",
8
- "0xDEd12537dA82C1019b3CA1714A5d58B7c5c19A04": "Kleros"
9
- }
10
- }
@@ -1,9 +0,0 @@
1
- {
2
- "address": "0xcB71745d032E16ec838430731282ff6c10D29Dea",
3
- "block": 27103177,
4
- "notes": null,
5
- "arbitrators": {
6
- "0x99489d7bb33539f3d1a401741e56e8f02b9ae0cf": "Kleros (General Court)",
7
- "0xb9fdd2904cbcc5543F02DB948B2CE59Ef10A950E": "Kleros DAO Governance (Technical Court)"
8
- }
9
- }
@@ -1,5 +0,0 @@
1
- {
2
- "address": "0x9046D057D7957A2A93d55C711EBC5B62d812a5b8",
3
- "block": 25399305,
4
- "reality_eth_address": "0x1346800BC8915536B9eaa388fa9A6B93398E5999"
5
- }
@@ -1,9 +0,0 @@
1
- {
2
- "address": "0x1346800BC8915536B9eaa388fa9A6B93398E5999",
3
- "block": 25355307,
4
- "token_address": "0x222E11E134F9AB3750812b37F0DA51B4467EaA7a",
5
- "notes": null,
6
- "arbitrators": {
7
- "0x9046D057D7957A2A93d55C711EBC5B62d812a5b8": "Test POLK arbitrator (reality.eth)"
8
- }
9
- }
@@ -1,7 +0,0 @@
1
- {
2
- "address": "0xe9CF05F9F664b88160D5658619c028D1EEb00fc7",
3
- "block": 27103188,
4
- "token_address": "0x222E11E134F9AB3750812b37F0DA51B4467EaA7a",
5
- "notes": null,
6
- "arbitrators": {}
7
- }