@rhinestone/shared-configs 1.14.0 → 1.16.0
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.
- package/dist/configs/chains.json +0 -81
- package/dist/configs/contracts.dev.json +181 -0
- package/dist/configs/contracts.json +181 -0
- package/dist/configs/mainnets.json +0 -6
- package/dist/configs/oft.json +0 -3
- package/dist/configs/providers.json +0 -3
- package/dist/scripts/__tests__/hoistUniform.test.d.ts +1 -0
- package/dist/scripts/__tests__/hoistUniform.test.js +84 -0
- package/dist/scripts/generate.js +5 -2
- package/dist/scripts/hoistUniform.d.ts +30 -0
- package/dist/scripts/hoistUniform.js +62 -0
- package/dist/src/__tests__/chainFactsClient.test.js +46 -0
- package/dist/src/chainFactsClient.d.ts +26 -2
- package/dist/src/chainFactsClient.js +43 -1
- package/dist/src/chains.js +0 -85
- package/dist/src/generated/contracts.dev.js +34 -270
- package/dist/src/generated/contracts.js +34 -270
- package/dist/src/generated/networks.d.ts +718 -1362
- package/dist/src/generated/networks.js +1 -3
- package/dist/src/generated/packageVersion.d.ts +1 -1
- package/dist/src/generated/packageVersion.js +1 -1
- package/package.json +1 -1
package/dist/configs/chains.json
CHANGED
|
@@ -1209,87 +1209,6 @@
|
|
|
1209
1209
|
"symbol": "WAVAX"
|
|
1210
1210
|
}
|
|
1211
1211
|
},
|
|
1212
|
-
"57073": {
|
|
1213
|
-
"caip2": "eip155:57073",
|
|
1214
|
-
"explorer": {
|
|
1215
|
-
"url": "https://explorer.inkonchain.com",
|
|
1216
|
-
"addressPath": "/address/",
|
|
1217
|
-
"txPath": "/tx/"
|
|
1218
|
-
},
|
|
1219
|
-
"iconSlug": "ink",
|
|
1220
|
-
"name": "Ink",
|
|
1221
|
-
"nativeToken": {
|
|
1222
|
-
"address": "0x0000000000000000000000000000000000000000",
|
|
1223
|
-
"decimals": 18,
|
|
1224
|
-
"symbol": "ETH"
|
|
1225
|
-
},
|
|
1226
|
-
"network": "mainnet",
|
|
1227
|
-
"publicRpcUrl": "https://rpc-gel.inkonchain.com",
|
|
1228
|
-
"settlementLayers": [
|
|
1229
|
-
"ACROSS",
|
|
1230
|
-
"ECO",
|
|
1231
|
-
"RELAY",
|
|
1232
|
-
"OFT"
|
|
1233
|
-
],
|
|
1234
|
-
"stack": "op-stack",
|
|
1235
|
-
"swapQuoters": [
|
|
1236
|
-
"0x"
|
|
1237
|
-
],
|
|
1238
|
-
"tokens": [
|
|
1239
|
-
{
|
|
1240
|
-
"address": "0x0000000000000000000000000000000000000000",
|
|
1241
|
-
"approvalSlot": null,
|
|
1242
|
-
"balanceSlot": null,
|
|
1243
|
-
"decimals": 18,
|
|
1244
|
-
"pegGroup": "ETH",
|
|
1245
|
-
"settlementLayers": [
|
|
1246
|
-
"ACROSS"
|
|
1247
|
-
],
|
|
1248
|
-
"symbol": "ETH"
|
|
1249
|
-
},
|
|
1250
|
-
{
|
|
1251
|
-
"address": "0x4200000000000000000000000000000000000006",
|
|
1252
|
-
"approvalSlot": 1,
|
|
1253
|
-
"balanceSlot": 0,
|
|
1254
|
-
"decimals": 18,
|
|
1255
|
-
"pegGroup": "ETH",
|
|
1256
|
-
"priceSymbol": "ETH",
|
|
1257
|
-
"settlementLayers": [
|
|
1258
|
-
"ACROSS"
|
|
1259
|
-
],
|
|
1260
|
-
"symbol": "WETH"
|
|
1261
|
-
},
|
|
1262
|
-
{
|
|
1263
|
-
"address": "0x2d270e6886d130d724215a266106e6832161eaed",
|
|
1264
|
-
"approvalSlot": 10,
|
|
1265
|
-
"balanceSlot": 9,
|
|
1266
|
-
"decimals": 6,
|
|
1267
|
-
"pegGroup": "USD",
|
|
1268
|
-
"settlementLayers": [
|
|
1269
|
-
"ACROSS"
|
|
1270
|
-
],
|
|
1271
|
-
"symbol": "USDC"
|
|
1272
|
-
},
|
|
1273
|
-
{
|
|
1274
|
-
"address": "0x0200c29006150606b650577bbe7b6248f58470c1",
|
|
1275
|
-
"approvalSlot": 52,
|
|
1276
|
-
"balanceSlot": 51,
|
|
1277
|
-
"decimals": 6,
|
|
1278
|
-
"pegGroup": "USD",
|
|
1279
|
-
"priceSymbol": "USDT",
|
|
1280
|
-
"settlementLayers": [
|
|
1281
|
-
"ACROSS"
|
|
1282
|
-
],
|
|
1283
|
-
"symbol": "USDT0"
|
|
1284
|
-
}
|
|
1285
|
-
],
|
|
1286
|
-
"vmType": "evm",
|
|
1287
|
-
"wrappedNativeToken": {
|
|
1288
|
-
"address": "0x4200000000000000000000000000000000000006",
|
|
1289
|
-
"decimals": 18,
|
|
1290
|
-
"symbol": "WETH"
|
|
1291
|
-
}
|
|
1292
|
-
},
|
|
1293
1212
|
"84532": {
|
|
1294
1213
|
"caip2": "eip155:84532",
|
|
1295
1214
|
"explorer": {
|
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
{
|
|
2
|
+
"1": {
|
|
3
|
+
"ecoArbiter": "0x1BeBAfb3D05d84A5Bfd94800c88d1342f755d8AB",
|
|
4
|
+
"acrossBridge": "0x5c7BCd6E7De5423a257D81B442095A1a6ced35C5",
|
|
5
|
+
"spokepool": "0x5c7BCd6E7De5423a257D81B442095A1a6ced35C5",
|
|
6
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
7
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
8
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9",
|
|
9
|
+
"oftProxy": "0xd6ac32d80975195aF535faE83c67EA1d36486321"
|
|
10
|
+
},
|
|
11
|
+
"10": {
|
|
12
|
+
"ecoArbiter": "0x1BeBAfb3D05d84A5Bfd94800c88d1342f755d8AB",
|
|
13
|
+
"acrossBridge": "0x6f26Bf09B1C792e3228e5467807a900A503c0281",
|
|
14
|
+
"spokepool": "0x6f26Bf09B1C792e3228e5467807a900A503c0281",
|
|
15
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
16
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
17
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9",
|
|
18
|
+
"oftProxy": "0x5B64E414f4dEA97062D6B552852FFbAcaf6d462b"
|
|
19
|
+
},
|
|
20
|
+
"56": {
|
|
21
|
+
"ecoArbiter": "0x1BeBAfb3D05d84A5Bfd94800c88d1342f755d8AB",
|
|
22
|
+
"acrossBridge": "0x4e8E101924eDE233C13e2D8622DC8aED2872d505",
|
|
23
|
+
"spokepool": "0x4e8E101924eDE233C13e2D8622DC8aED2872d505",
|
|
24
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
25
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
26
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9"
|
|
27
|
+
},
|
|
28
|
+
"100": {},
|
|
29
|
+
"130": {
|
|
30
|
+
"ecoArbiter": "0x1BeBAfb3D05d84A5Bfd94800c88d1342f755d8AB",
|
|
31
|
+
"acrossBridge": "0x09aea4b2242abC8bb4BB78D537A67a245A7bEC64",
|
|
32
|
+
"spokepool": "0x09aea4b2242abC8bb4BB78D537A67a245A7bEC64",
|
|
33
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
34
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
35
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9",
|
|
36
|
+
"oftProxy": "0x0c9365ACEB4788F2f2D21823fbd0ff44542c6B54"
|
|
37
|
+
},
|
|
38
|
+
"137": {
|
|
39
|
+
"ecoArbiter": "0x1BeBAfb3D05d84A5Bfd94800c88d1342f755d8AB",
|
|
40
|
+
"acrossBridge": "0x9295ee1d8C5b022Be115A2AD3c30C72E34e7F096",
|
|
41
|
+
"spokepool": "0x9295ee1d8C5b022Be115A2AD3c30C72E34e7F096",
|
|
42
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
43
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
44
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9",
|
|
45
|
+
"oftProxy": "0x81E23Ed7B30780dd7DFc1F1641D255906280934a"
|
|
46
|
+
},
|
|
47
|
+
"143": {
|
|
48
|
+
"acrossBridge": "0xd2ecb3afe598b746F8123CaE365a598DA831A449",
|
|
49
|
+
"spokepool": "0xd2ecb3afe598b746F8123CaE365a598DA831A449"
|
|
50
|
+
},
|
|
51
|
+
"146": {
|
|
52
|
+
"ecoArbiter": "0x1BeBAfb3D05d84A5Bfd94800c88d1342f755d8AB",
|
|
53
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
54
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
55
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9"
|
|
56
|
+
},
|
|
57
|
+
"999": {
|
|
58
|
+
"ecoArbiter": "0x1BeBAfb3D05d84A5Bfd94800c88d1342f755d8AB",
|
|
59
|
+
"acrossBridge": "0x35E63eA3eb0fb7A3bc543C71FB66412e1F6B0E04",
|
|
60
|
+
"spokepool": "0x35E63eA3eb0fb7A3bc543C71FB66412e1F6B0E04",
|
|
61
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
62
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
63
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9"
|
|
64
|
+
},
|
|
65
|
+
"1868": {
|
|
66
|
+
"acrossBridge": "0x3baD7AD0728f9917d1Bf08af5782dCbD516cDd96",
|
|
67
|
+
"spokepool": "0x3baD7AD0728f9917d1Bf08af5782dCbD516cDd96"
|
|
68
|
+
},
|
|
69
|
+
"4663": {
|
|
70
|
+
"acrossBridge": "0xD29C85F15DF544bA632C9E25829fd29d767d7978",
|
|
71
|
+
"spokepool": "0xD29C85F15DF544bA632C9E25829fd29d767d7978"
|
|
72
|
+
},
|
|
73
|
+
"8453": {
|
|
74
|
+
"ecoArbiter": "0x1BeBAfb3D05d84A5Bfd94800c88d1342f755d8AB",
|
|
75
|
+
"acrossBridge": "0x09aea4b2242abC8bb4BB78D537A67a245A7bEC64",
|
|
76
|
+
"spokepool": "0x09aea4b2242abC8bb4BB78D537A67a245A7bEC64",
|
|
77
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
78
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
79
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9"
|
|
80
|
+
},
|
|
81
|
+
"9745": {
|
|
82
|
+
"ecoArbiter": "0x1BeBAfb3D05d84A5Bfd94800c88d1342f755d8AB",
|
|
83
|
+
"acrossBridge": "0x50039fAEfebef707cFD94D6d462fE6D10B39207a",
|
|
84
|
+
"spokepool": "0x50039fAEfebef707cFD94D6d462fE6D10B39207a",
|
|
85
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
86
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
87
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9",
|
|
88
|
+
"oftProxy": "0xB01c27A13Ac8044ACB2315C3c9b877bc8C83ce27"
|
|
89
|
+
},
|
|
90
|
+
"9746": {
|
|
91
|
+
"ecoArbiter": "0x8A061029AE4c5Cf69b5368119B3b0C80B31F55fE",
|
|
92
|
+
"ecoPortal": "0x06EFdb68dbF245ECb49E3aE10Cd0f893B674443c",
|
|
93
|
+
"ecoHyperProver": "0xe2d2562779550Ef6C3C9D7D59E0FaC1851fDA178",
|
|
94
|
+
"ecoVaultAddress": "0xfc6695ed50c06ac1102371168c33b3cfab7c884b"
|
|
95
|
+
},
|
|
96
|
+
"42161": {
|
|
97
|
+
"ecoArbiter": "0x1BeBAfb3D05d84A5Bfd94800c88d1342f755d8AB",
|
|
98
|
+
"acrossBridge": "0xe35e9842fceaCA96570B734083f4a58e8F7C5f2A",
|
|
99
|
+
"spokepool": "0xe35e9842fceaCA96570B734083f4a58e8F7C5f2A",
|
|
100
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
101
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
102
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9",
|
|
103
|
+
"oftProxy": "0x8886505Fc68b53B0D5156DbB68CFAdA878c89f89"
|
|
104
|
+
},
|
|
105
|
+
"43114": {
|
|
106
|
+
"acrossBridge": "0xFE9D541c92E4e90437C7152A00244886dE37a658",
|
|
107
|
+
"spokepool": "0xFE9D541c92E4e90437C7152A00244886dE37a658"
|
|
108
|
+
},
|
|
109
|
+
"84532": {
|
|
110
|
+
"ecoArbiter": "0x8A061029AE4c5Cf69b5368119B3b0C80B31F55fE",
|
|
111
|
+
"acrossBridge": "0x82B564983aE7274c86695917BBf8C99ECb6F0F8F",
|
|
112
|
+
"spokepool": "0x82B564983aE7274c86695917BBf8C99ECb6F0F8F",
|
|
113
|
+
"ecoPortal": "0x06EFdb68dbF245ECb49E3aE10Cd0f893B674443c",
|
|
114
|
+
"ecoHyperProver": "0xad707D5756B534d55Fc2e96F61a95Fc03E4C0A0e",
|
|
115
|
+
"ecoVaultAddress": "0xfc6695ed50c06ac1102371168c33b3cfab7c884b"
|
|
116
|
+
},
|
|
117
|
+
"421614": {
|
|
118
|
+
"ecoArbiter": "0x8A061029AE4c5Cf69b5368119B3b0C80B31F55fE",
|
|
119
|
+
"acrossBridge": "0x7E63A5f1a8F0B4d0934B2f2327DAED3F6bb2ee75",
|
|
120
|
+
"spokepool": "0x7E63A5f1a8F0B4d0934B2f2327DAED3F6bb2ee75",
|
|
121
|
+
"ecoPortal": "0x06EFdb68dbF245ECb49E3aE10Cd0f893B674443c",
|
|
122
|
+
"ecoHyperProver": "0xad707D5756B534d55Fc2e96F61a95Fc03E4C0A0e",
|
|
123
|
+
"ecoVaultAddress": "0xfc6695ed50c06ac1102371168c33b3cfab7c884b"
|
|
124
|
+
},
|
|
125
|
+
"747474": {},
|
|
126
|
+
"11155111": {
|
|
127
|
+
"ecoArbiter": "0x8A061029AE4c5Cf69b5368119B3b0C80B31F55fE",
|
|
128
|
+
"acrossBridge": "0x5ef6C01E11889d86803e0B23e3cB3F9E9d97B662",
|
|
129
|
+
"spokepool": "0x5ef6C01E11889d86803e0B23e3cB3F9E9d97B662",
|
|
130
|
+
"ecoPortal": "0x06EFdb68dbF245ECb49E3aE10Cd0f893B674443c",
|
|
131
|
+
"ecoHyperProver": "0xad707D5756B534d55Fc2e96F61a95Fc03E4C0A0e",
|
|
132
|
+
"ecoVaultAddress": "0xfc6695ed50c06ac1102371168c33b3cfab7c884b"
|
|
133
|
+
},
|
|
134
|
+
"11155420": {
|
|
135
|
+
"ecoArbiter": "0x8A061029AE4c5Cf69b5368119B3b0C80B31F55fE",
|
|
136
|
+
"acrossBridge": "0x4e8E101924eDE233C13e2D8622DC8aED2872d505",
|
|
137
|
+
"spokepool": "0x4e8E101924eDE233C13e2D8622DC8aED2872d505",
|
|
138
|
+
"ecoPortal": "0x06EFdb68dbF245ECb49E3aE10Cd0f893B674443c",
|
|
139
|
+
"ecoHyperProver": "0xad707D5756B534d55Fc2e96F61a95Fc03E4C0A0e",
|
|
140
|
+
"ecoVaultAddress": "0xfc6695ed50c06ac1102371168c33b3cfab7c884b"
|
|
141
|
+
},
|
|
142
|
+
"*": {
|
|
143
|
+
"addressBook": "0xb7Eed4f2c3c3EE7349f80414ffb04dA6c247924E",
|
|
144
|
+
"allocator": "0xC7732071e3a1be6cfCE6D13bb05699A31a457679",
|
|
145
|
+
"caller": "0xcBb2af2EAc15Fd261c542aBd65DE33eF653A7dc7",
|
|
146
|
+
"multiCaller": "0xcBb2af2EAc15Fd261c542aBd65DE33eF653A7dc7",
|
|
147
|
+
"emissary": "0x1c61d49eef44eF278D2fd8Ae7d2C6806A8Ac4263",
|
|
148
|
+
"emissaryImpl": "0xE183EA1693556b85E8243Ed60184feCc9B4Cff6f",
|
|
149
|
+
"intentExecutor": "0xbF9b5b917a83f8adaC17B0752846D41D8D7b7E17",
|
|
150
|
+
"intentExecutorImpl": "0x97ddB09859AC7a38C69A84cB7d22Cd01EE0efBB5",
|
|
151
|
+
"intentExecutorAdapter": "0xd244839c3f90deC5a21c03DAd5d1695Fcc991807",
|
|
152
|
+
"intentExecutorAdapterGasRefund": "0x1CF61dd99558088bc6d33464Fdc3A50158d96671",
|
|
153
|
+
"multicallAdapter": "0x2033BAf793ece4a38f0CBae47AF8435620E296c6",
|
|
154
|
+
"oftFeeAdapter": "0xBE6cB8e0aC7cd44c0E364DD9cFeD45Fa2E717426",
|
|
155
|
+
"multicallHandler": "0xcc57378369bbC7B5bFD2b2F3E8A9f733c16c5F63",
|
|
156
|
+
"singlecallAdapter": "0xa4fC159E93F3D3E08b67D1228D57d5769B3Bff92",
|
|
157
|
+
"ecoHandler": "0xcc57378369bbC7B5bFD2b2F3E8A9f733c16c5F63",
|
|
158
|
+
"paymaster": "0xf2d0A6572252931a685dd4a64db3198eBdC7a4b6",
|
|
159
|
+
"relayerPot": "0xDD6430ad62de02cF8d37Fc3Bc34c6855F34BCbE8",
|
|
160
|
+
"router": "0x8a525Dc484f893Ca64fef507746EBd5036eeC256",
|
|
161
|
+
"routerImpl": "0xb59E7Df2B636a66Bff03CA554407B920bB150109",
|
|
162
|
+
"safeRelayExecutor": "0x781388759EacB9892f60D77D9A99c9BE2F7F4ada",
|
|
163
|
+
"samechainArbiter": "0x8fA7720Eee299223f25De8DC03C68A28541dCD10",
|
|
164
|
+
"samechainAdapter": "0xca9f2c72e9DDa98a5286607f8693744396851C34",
|
|
165
|
+
"smartSessionEmissary": "0x60731dE80D78548875f8A67C4FeC2a8660194e0c",
|
|
166
|
+
"smartSessionLens": "0xE1B629162B08b8Baefa2B30Ee34D6cAB63580320",
|
|
167
|
+
"swapper": "0x8206052a213AA7cafB18ec7898e8D1D421C02100",
|
|
168
|
+
"acrossHandler": "0xF6fC9aa0DA8621f5596024f34E277032E5A80AE8",
|
|
169
|
+
"across7579Arbiter": "0x1b19973F7a29E950ad4FaF8872745B6378005517",
|
|
170
|
+
"acrossMulticallArbiter": "0x8343FBBA0526deC1c952A098057021027648bcf9",
|
|
171
|
+
"relayArbiter": "0xf50962E8f230D83c67002597992ce0f9EBDD49c0",
|
|
172
|
+
"relayDepository": "0x4cd00e387622c35bddb9b4c962c136462338bc31",
|
|
173
|
+
"relayRouter": "0xb92fe925dc43a0ecde6c8b1a2709c170ec4fff4f",
|
|
174
|
+
"compact": "0x00000000000000171ede64904551eeDF3C6C9788",
|
|
175
|
+
"permit2": "0x000000000022D473030F116dDEE9F6B43aC78BA3",
|
|
176
|
+
"feeCollector": "0xfeebabe17996b3346cf80f04a1f072102a90cf09",
|
|
177
|
+
"appFeeCollector": "0xc9dc20145135368d5184dB9Ee6598c885a7f03e1",
|
|
178
|
+
"appFeePot": "0xb83E1d9C267e1f99529f8cE4CE20899f1FCAdBCc",
|
|
179
|
+
"tokenTransferProxy": "0x21416a06e81fe115a5c8bf554b2b01383bd9b9f3"
|
|
180
|
+
}
|
|
181
|
+
}
|
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
{
|
|
2
|
+
"1": {
|
|
3
|
+
"ecoArbiter": "0x2e7627CCfAe4eDb336eEb5a70f08415B0F1a2b8C",
|
|
4
|
+
"acrossBridge": "0x5c7BCd6E7De5423a257D81B442095A1a6ced35C5",
|
|
5
|
+
"spokepool": "0x5c7BCd6E7De5423a257D81B442095A1a6ced35C5",
|
|
6
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
7
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
8
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9",
|
|
9
|
+
"oftProxy": "0x7cbcf2E2B6e29e539326bf5730353D6106D6DA0a"
|
|
10
|
+
},
|
|
11
|
+
"10": {
|
|
12
|
+
"ecoArbiter": "0x2e7627CCfAe4eDb336eEb5a70f08415B0F1a2b8C",
|
|
13
|
+
"acrossBridge": "0x6f26Bf09B1C792e3228e5467807a900A503c0281",
|
|
14
|
+
"spokepool": "0x6f26Bf09B1C792e3228e5467807a900A503c0281",
|
|
15
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
16
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
17
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9",
|
|
18
|
+
"oftProxy": "0x4a16B761367f8545cbF0dcFb90c6a190D53d5A4B"
|
|
19
|
+
},
|
|
20
|
+
"56": {
|
|
21
|
+
"ecoArbiter": "0x2e7627CCfAe4eDb336eEb5a70f08415B0F1a2b8C",
|
|
22
|
+
"acrossBridge": "0x4e8E101924eDE233C13e2D8622DC8aED2872d505",
|
|
23
|
+
"spokepool": "0x4e8E101924eDE233C13e2D8622DC8aED2872d505",
|
|
24
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
25
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
26
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9"
|
|
27
|
+
},
|
|
28
|
+
"100": {},
|
|
29
|
+
"130": {
|
|
30
|
+
"ecoArbiter": "0x2e7627CCfAe4eDb336eEb5a70f08415B0F1a2b8C",
|
|
31
|
+
"acrossBridge": "0x09aea4b2242abC8bb4BB78D537A67a245A7bEC64",
|
|
32
|
+
"spokepool": "0x09aea4b2242abC8bb4BB78D537A67a245A7bEC64",
|
|
33
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
34
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
35
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9",
|
|
36
|
+
"oftProxy": "0xB3bAE89d1F4FbDD56708c3aDc92d54F3e5B2C47e"
|
|
37
|
+
},
|
|
38
|
+
"137": {
|
|
39
|
+
"ecoArbiter": "0x2e7627CCfAe4eDb336eEb5a70f08415B0F1a2b8C",
|
|
40
|
+
"acrossBridge": "0x9295ee1d8C5b022Be115A2AD3c30C72E34e7F096",
|
|
41
|
+
"spokepool": "0x9295ee1d8C5b022Be115A2AD3c30C72E34e7F096",
|
|
42
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
43
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
44
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9",
|
|
45
|
+
"oftProxy": "0xcaee1Bf3C17B128985C808ed4055Fd83C32EcC71"
|
|
46
|
+
},
|
|
47
|
+
"143": {
|
|
48
|
+
"acrossBridge": "0xd2ecb3afe598b746F8123CaE365a598DA831A449",
|
|
49
|
+
"spokepool": "0xd2ecb3afe598b746F8123CaE365a598DA831A449"
|
|
50
|
+
},
|
|
51
|
+
"146": {
|
|
52
|
+
"ecoArbiter": "0x2e7627CCfAe4eDb336eEb5a70f08415B0F1a2b8C",
|
|
53
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
54
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
55
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9"
|
|
56
|
+
},
|
|
57
|
+
"999": {
|
|
58
|
+
"ecoArbiter": "0x2e7627CCfAe4eDb336eEb5a70f08415B0F1a2b8C",
|
|
59
|
+
"acrossBridge": "0x35E63eA3eb0fb7A3bc543C71FB66412e1F6B0E04",
|
|
60
|
+
"spokepool": "0x35E63eA3eb0fb7A3bc543C71FB66412e1F6B0E04",
|
|
61
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
62
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
63
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9"
|
|
64
|
+
},
|
|
65
|
+
"1868": {
|
|
66
|
+
"acrossBridge": "0x3baD7AD0728f9917d1Bf08af5782dCbD516cDd96",
|
|
67
|
+
"spokepool": "0x3baD7AD0728f9917d1Bf08af5782dCbD516cDd96"
|
|
68
|
+
},
|
|
69
|
+
"4663": {
|
|
70
|
+
"acrossBridge": "0xD29C85F15DF544bA632C9E25829fd29d767d7978",
|
|
71
|
+
"spokepool": "0xD29C85F15DF544bA632C9E25829fd29d767d7978"
|
|
72
|
+
},
|
|
73
|
+
"8453": {
|
|
74
|
+
"ecoArbiter": "0x2e7627CCfAe4eDb336eEb5a70f08415B0F1a2b8C",
|
|
75
|
+
"acrossBridge": "0x09aea4b2242abC8bb4BB78D537A67a245A7bEC64",
|
|
76
|
+
"spokepool": "0x09aea4b2242abC8bb4BB78D537A67a245A7bEC64",
|
|
77
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
78
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
79
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9"
|
|
80
|
+
},
|
|
81
|
+
"9745": {
|
|
82
|
+
"ecoArbiter": "0x2e7627CCfAe4eDb336eEb5a70f08415B0F1a2b8C",
|
|
83
|
+
"acrossBridge": "0x50039fAEfebef707cFD94D6d462fE6D10B39207a",
|
|
84
|
+
"spokepool": "0x50039fAEfebef707cFD94D6d462fE6D10B39207a",
|
|
85
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
86
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
87
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9",
|
|
88
|
+
"oftProxy": "0x2C8d441698332996C754402c35273b6566C8701d"
|
|
89
|
+
},
|
|
90
|
+
"9746": {
|
|
91
|
+
"ecoArbiter": "0xA212A6ACCC8db0e4cdf4394D0A851c70Fc27A8F0",
|
|
92
|
+
"ecoPortal": "0x06EFdb68dbF245ECb49E3aE10Cd0f893B674443c",
|
|
93
|
+
"ecoHyperProver": "0xe2d2562779550Ef6C3C9D7D59E0FaC1851fDA178",
|
|
94
|
+
"ecoVaultAddress": "0xfc6695ed50c06ac1102371168c33b3cfab7c884b"
|
|
95
|
+
},
|
|
96
|
+
"42161": {
|
|
97
|
+
"ecoArbiter": "0x2e7627CCfAe4eDb336eEb5a70f08415B0F1a2b8C",
|
|
98
|
+
"acrossBridge": "0xe35e9842fceaCA96570B734083f4a58e8F7C5f2A",
|
|
99
|
+
"spokepool": "0xe35e9842fceaCA96570B734083f4a58e8F7C5f2A",
|
|
100
|
+
"ecoPortal": "0xEC000064576f9C95a8623Bc0eff3db6d296ea6df",
|
|
101
|
+
"ecoHyperProver": "0xeC0008acc34d3D0CAa6758Ce788091e473812e28",
|
|
102
|
+
"ecoVaultAddress": "0x9f70b0c839fe2D7190A09Ae87ED658b6D1CbA4F9",
|
|
103
|
+
"oftProxy": "0x4a263e771D73489e15a62e56FD49Dee6A26885A1"
|
|
104
|
+
},
|
|
105
|
+
"43114": {
|
|
106
|
+
"acrossBridge": "0xFE9D541c92E4e90437C7152A00244886dE37a658",
|
|
107
|
+
"spokepool": "0xFE9D541c92E4e90437C7152A00244886dE37a658"
|
|
108
|
+
},
|
|
109
|
+
"84532": {
|
|
110
|
+
"ecoArbiter": "0xA212A6ACCC8db0e4cdf4394D0A851c70Fc27A8F0",
|
|
111
|
+
"acrossBridge": "0x82B564983aE7274c86695917BBf8C99ECb6F0F8F",
|
|
112
|
+
"spokepool": "0x82B564983aE7274c86695917BBf8C99ECb6F0F8F",
|
|
113
|
+
"ecoPortal": "0x06EFdb68dbF245ECb49E3aE10Cd0f893B674443c",
|
|
114
|
+
"ecoHyperProver": "0xad707D5756B534d55Fc2e96F61a95Fc03E4C0A0e",
|
|
115
|
+
"ecoVaultAddress": "0xfc6695ed50c06ac1102371168c33b3cfab7c884b"
|
|
116
|
+
},
|
|
117
|
+
"421614": {
|
|
118
|
+
"ecoArbiter": "0xA212A6ACCC8db0e4cdf4394D0A851c70Fc27A8F0",
|
|
119
|
+
"acrossBridge": "0x7E63A5f1a8F0B4d0934B2f2327DAED3F6bb2ee75",
|
|
120
|
+
"spokepool": "0x7E63A5f1a8F0B4d0934B2f2327DAED3F6bb2ee75",
|
|
121
|
+
"ecoPortal": "0x06EFdb68dbF245ECb49E3aE10Cd0f893B674443c",
|
|
122
|
+
"ecoHyperProver": "0xad707D5756B534d55Fc2e96F61a95Fc03E4C0A0e",
|
|
123
|
+
"ecoVaultAddress": "0xfc6695ed50c06ac1102371168c33b3cfab7c884b"
|
|
124
|
+
},
|
|
125
|
+
"747474": {},
|
|
126
|
+
"11155111": {
|
|
127
|
+
"ecoArbiter": "0xA212A6ACCC8db0e4cdf4394D0A851c70Fc27A8F0",
|
|
128
|
+
"acrossBridge": "0x5ef6C01E11889d86803e0B23e3cB3F9E9d97B662",
|
|
129
|
+
"spokepool": "0x5ef6C01E11889d86803e0B23e3cB3F9E9d97B662",
|
|
130
|
+
"ecoPortal": "0x06EFdb68dbF245ECb49E3aE10Cd0f893B674443c",
|
|
131
|
+
"ecoHyperProver": "0xad707D5756B534d55Fc2e96F61a95Fc03E4C0A0e",
|
|
132
|
+
"ecoVaultAddress": "0xfc6695ed50c06ac1102371168c33b3cfab7c884b"
|
|
133
|
+
},
|
|
134
|
+
"11155420": {
|
|
135
|
+
"ecoArbiter": "0xA212A6ACCC8db0e4cdf4394D0A851c70Fc27A8F0",
|
|
136
|
+
"acrossBridge": "0x4e8E101924eDE233C13e2D8622DC8aED2872d505",
|
|
137
|
+
"spokepool": "0x4e8E101924eDE233C13e2D8622DC8aED2872d505",
|
|
138
|
+
"ecoPortal": "0x06EFdb68dbF245ECb49E3aE10Cd0f893B674443c",
|
|
139
|
+
"ecoHyperProver": "0xad707D5756B534d55Fc2e96F61a95Fc03E4C0A0e",
|
|
140
|
+
"ecoVaultAddress": "0xfc6695ed50c06ac1102371168c33b3cfab7c884b"
|
|
141
|
+
},
|
|
142
|
+
"*": {
|
|
143
|
+
"addressBook": "0x4b9e821f89F0952efe6A60719dcA953eCF980D4D",
|
|
144
|
+
"allocator": "0x22376d253286450b3622270345Cccc564C2a5C9B",
|
|
145
|
+
"caller": "0xFdaD21fFcd9f08D7feaA7A76D8133565502Ec350",
|
|
146
|
+
"multiCaller": "0xFdaD21fFcd9f08D7feaA7A76D8133565502Ec350",
|
|
147
|
+
"emissary": "0x00000000000191E0ffEca3835B693Aa1DDeE8d40",
|
|
148
|
+
"emissaryImpl": "0x4A150C45657E4C33879a29aA133277f32757Ec4e",
|
|
149
|
+
"intentExecutor": "0x00000000005aD9ce1f5035FD62CA96CEf16AdAAF",
|
|
150
|
+
"intentExecutorImpl": "0x194DE341d4791e9b8922eE1bC018DFd1fD1b115A",
|
|
151
|
+
"intentExecutorAdapter": "0xa5DAC04a6cCF0eb19cE091b6B400Fc4FCD13Da1e",
|
|
152
|
+
"intentExecutorAdapterGasRefund": "0xA36E04937BE2C53fA97396b3D254d6cCE6680dc8",
|
|
153
|
+
"multicallAdapter": "0x4cf546ed0F6a4EC4155449686257f698D5044B1F",
|
|
154
|
+
"oftFeeAdapter": "0xf97FF38ad127b32233aF500a40eCc6cd202E16d7",
|
|
155
|
+
"multicallHandler": "0x200FAb4dEA0388FF9056B3B61f82F981B1de0244",
|
|
156
|
+
"singlecallAdapter": "0xAc373dCFA558C78853D0C09A019e44b2f7410bfE",
|
|
157
|
+
"ecoHandler": "0x200FAb4dEA0388FF9056B3B61f82F981B1de0244",
|
|
158
|
+
"paymaster": "0x1d7df6Ddc7328Ac827EB4D7f171C60AFB7f9A599",
|
|
159
|
+
"relayerPot": "0x000000000050a4BbBc2e57804395A0C209353E1c",
|
|
160
|
+
"router": "0x000000000004598D17aaD017bF0734a364c5588b",
|
|
161
|
+
"routerImpl": "0xB8722E9F60c3d021cb84d150E85cBc52C3Bfd4b9",
|
|
162
|
+
"safeRelayExecutor": "0x781388759EacB9892f60D77D9A99c9BE2F7F4ada",
|
|
163
|
+
"samechainArbiter": "0x000000000006e2569CaF8Ff021810790e0A0D740",
|
|
164
|
+
"samechainAdapter": "0x63ff8Da121e51BC4f4f67df9c37eD2587A119Aeb",
|
|
165
|
+
"smartSessionEmissary": "0xad568B3F825A8d5FFc06DD3253526B64D810Ae89",
|
|
166
|
+
"smartSessionLens": "0xE1B629162B08b8Baefa2B30Ee34D6cAB63580320",
|
|
167
|
+
"swapper": "0x40CE38e0cbB8ec54a601256E4FacfED5679bccD0",
|
|
168
|
+
"acrossHandler": "0x505549590d0F107C65a61FD9f71f8dd3f92C393E",
|
|
169
|
+
"across7579Arbiter": "0x28a4D41776968c1201A807ec51fFB405362B8882",
|
|
170
|
+
"acrossMulticallArbiter": "0xA162fabb9a0EeF2736485A587aAAB3d015e14224",
|
|
171
|
+
"relayArbiter": "0xad549C787B8C00B4E880e327c3Ad3965275cEdfd",
|
|
172
|
+
"relayDepository": "0x4cd00e387622c35bddb9b4c962c136462338bc31",
|
|
173
|
+
"relayRouter": "0xb92fe925dc43a0ecde6c8b1a2709c170ec4fff4f",
|
|
174
|
+
"compact": "0x00000000000000171ede64904551eeDF3C6C9788",
|
|
175
|
+
"permit2": "0x000000000022D473030F116dDEE9F6B43aC78BA3",
|
|
176
|
+
"feeCollector": "0xfeebabe17996b3346cf80f04a1f072102a90cf09",
|
|
177
|
+
"appFeeCollector": "0xdcc703c0E500B653Ca82273B7BFAd8045D85a470",
|
|
178
|
+
"appFeePot": "0x134760a4cC835c4031d772B10D639004443D2A1c",
|
|
179
|
+
"tokenTransferProxy": "0x5afce415b4370e5efd8b9be784d21c331beab965"
|
|
180
|
+
}
|
|
181
|
+
}
|
package/dist/configs/oft.json
CHANGED
|
@@ -7,7 +7,6 @@
|
|
|
7
7
|
"137": "0x6BA10300f0DC58B7a1e4c0e41f5daBb7D7829e13",
|
|
8
8
|
"9745": "0x02ca37966753bDdDf11216B73B16C1dE756A7CF9",
|
|
9
9
|
"42161": "0x14E4A1B13bf7F943c8ff7C51fb60FA964A298D92",
|
|
10
|
-
"57073": "0x1cB6De532588fCA4a21B7209DE7C456AF8434A65",
|
|
11
10
|
"728126428": "TFG4wBaDQ8sHWWP1ACeSGnoNR6RRzevLPt",
|
|
12
11
|
"792703809": "HyXJcgYpURfDhgzuyRL7zxP4FhLg7LZQMeDrR4MXZcMN"
|
|
13
12
|
},
|
|
@@ -18,7 +17,6 @@
|
|
|
18
17
|
"137": 30109,
|
|
19
18
|
"9745": 30383,
|
|
20
19
|
"42161": 30110,
|
|
21
|
-
"57073": 30339,
|
|
22
20
|
"421614": 40231,
|
|
23
21
|
"11155111": 40161,
|
|
24
22
|
"728126428": 30420,
|
|
@@ -32,7 +30,6 @@
|
|
|
32
30
|
"137": "0xc2132D05D31c914a87C6611C10748AEb04B58e8F",
|
|
33
31
|
"9745": "0xB8CE59FC3717ada4C02eaDF9682A9e934F625ebb",
|
|
34
32
|
"42161": "0xFd086bC7CD5C481DCC9C85ebE478A1C0b69FCbb9",
|
|
35
|
-
"57073": "0x0200C29006150606B650577BBE7B6248F58470c1",
|
|
36
33
|
"728126428": "TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t",
|
|
37
34
|
"792703809": "Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB"
|
|
38
35
|
}
|
|
@@ -17,7 +17,6 @@
|
|
|
17
17
|
"9746": "plasma-testnet",
|
|
18
18
|
"42161": "arb-mainnet",
|
|
19
19
|
"43114": "avax-mainnet",
|
|
20
|
-
"57073": "ink-mainnet",
|
|
21
20
|
"84532": "base-sepolia",
|
|
22
21
|
"421614": "arb-sepolia",
|
|
23
22
|
"747474": "katana-mainnet",
|
|
@@ -44,7 +43,6 @@
|
|
|
44
43
|
"9746": "plasma-testnet",
|
|
45
44
|
"42161": "arbitrum",
|
|
46
45
|
"43114": "avalanche",
|
|
47
|
-
"57073": "ink",
|
|
48
46
|
"84532": "base-sepolia",
|
|
49
47
|
"421614": "arbitrum-sepolia",
|
|
50
48
|
"747474": "katana",
|
|
@@ -71,7 +69,6 @@
|
|
|
71
69
|
"9746": "9746",
|
|
72
70
|
"42161": "42161",
|
|
73
71
|
"43114": "43114",
|
|
74
|
-
"57073": "57073",
|
|
75
72
|
"84532": "84532",
|
|
76
73
|
"421614": "421614",
|
|
77
74
|
"747474": "747474",
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const bun_test_1 = require("bun:test");
|
|
4
|
+
const hoistUniform_1 = require("../hoistUniform");
|
|
5
|
+
const resolve = (contracts, chainId) => ({
|
|
6
|
+
...(contracts["*"] ?? {}),
|
|
7
|
+
...(contracts[chainId] ?? {}),
|
|
8
|
+
});
|
|
9
|
+
(0, bun_test_1.describe)("hoistUniformAddresses", () => {
|
|
10
|
+
(0, bun_test_1.test)("hoists an address that is identical on every chain carrying it", () => {
|
|
11
|
+
const out = (0, hoistUniform_1.hoistUniformAddresses)({
|
|
12
|
+
"1": { permit2: "0xAA", spokepool: "0x11" },
|
|
13
|
+
"10": { permit2: "0xAA", spokepool: "0x22" },
|
|
14
|
+
});
|
|
15
|
+
(0, bun_test_1.expect)(out["*"].permit2).toBe("0xAA");
|
|
16
|
+
(0, bun_test_1.expect)(out["1"].permit2).toBeUndefined();
|
|
17
|
+
(0, bun_test_1.expect)(out["10"].permit2).toBeUndefined();
|
|
18
|
+
});
|
|
19
|
+
(0, bun_test_1.test)("leaves an address that differs between chains", () => {
|
|
20
|
+
const out = (0, hoistUniform_1.hoistUniformAddresses)({
|
|
21
|
+
"1": { spokepool: "0x11" },
|
|
22
|
+
"10": { spokepool: "0x22" },
|
|
23
|
+
});
|
|
24
|
+
// No wildcard is created when there is nothing to hoist, so read through it.
|
|
25
|
+
(0, bun_test_1.expect)(out["*"]?.spokepool).toBeUndefined();
|
|
26
|
+
(0, bun_test_1.expect)(out["1"].spokepool).toBe("0x11");
|
|
27
|
+
(0, bun_test_1.expect)(out["10"].spokepool).toBe("0x22");
|
|
28
|
+
});
|
|
29
|
+
(0, bun_test_1.test)("does not hoist a key seen on only one chain", () => {
|
|
30
|
+
// One chain is no evidence of uniformity — oftProxy looks uniform on a
|
|
31
|
+
// single-chain sample and has a different address on all seven.
|
|
32
|
+
const out = (0, hoistUniform_1.hoistUniformAddresses)({
|
|
33
|
+
"1": { oftProxy: "0x11" },
|
|
34
|
+
"10": { permit2: "0xAA" },
|
|
35
|
+
"56": { permit2: "0xAA" },
|
|
36
|
+
});
|
|
37
|
+
(0, bun_test_1.expect)(out["*"].oftProxy).toBeUndefined();
|
|
38
|
+
(0, bun_test_1.expect)(out["1"].oftProxy).toBe("0x11");
|
|
39
|
+
(0, bun_test_1.expect)(out["*"].permit2).toBe("0xAA");
|
|
40
|
+
});
|
|
41
|
+
(0, bun_test_1.test)("resolution is unchanged for every chain that already had the key", () => {
|
|
42
|
+
const before = {
|
|
43
|
+
"*": { router: "0xRR" },
|
|
44
|
+
"1": { permit2: "0xAA", spokepool: "0x11" },
|
|
45
|
+
"10": { permit2: "0xAA", spokepool: "0x22" },
|
|
46
|
+
};
|
|
47
|
+
const after = (0, hoistUniform_1.hoistUniformAddresses)(before);
|
|
48
|
+
for (const chain of ["1", "10"]) {
|
|
49
|
+
(0, bun_test_1.expect)(resolve(after, chain)).toEqual(resolve(before, chain));
|
|
50
|
+
}
|
|
51
|
+
});
|
|
52
|
+
(0, bun_test_1.test)("a chain the map has never seen resolves the uniform addresses", () => {
|
|
53
|
+
// The reason this exists: chains arrive at runtime via facts while this map
|
|
54
|
+
// is baked into the image, so an unknown chain gets the bare wildcard.
|
|
55
|
+
const out = (0, hoistUniform_1.hoistUniformAddresses)({
|
|
56
|
+
"1": { permit2: "0xAA" },
|
|
57
|
+
"10": { permit2: "0xAA" },
|
|
58
|
+
});
|
|
59
|
+
(0, bun_test_1.expect)(out["*"].permit2).toBe("0xAA");
|
|
60
|
+
});
|
|
61
|
+
(0, bun_test_1.test)("preserves pre-existing wildcard entries", () => {
|
|
62
|
+
const out = (0, hoistUniform_1.hoistUniformAddresses)({
|
|
63
|
+
"*": { router: "0xRR" },
|
|
64
|
+
"1": { permit2: "0xAA" },
|
|
65
|
+
"10": { permit2: "0xAA" },
|
|
66
|
+
});
|
|
67
|
+
(0, bun_test_1.expect)(out["*"].router).toBe("0xRR");
|
|
68
|
+
(0, bun_test_1.expect)(out["*"].permit2).toBe("0xAA");
|
|
69
|
+
});
|
|
70
|
+
(0, bun_test_1.test)("is a no-op when nothing is uniform", () => {
|
|
71
|
+
const input = { "1": { spokepool: "0x11" } };
|
|
72
|
+
(0, bun_test_1.expect)((0, hoistUniform_1.hoistUniformAddresses)(input)).toEqual(input);
|
|
73
|
+
});
|
|
74
|
+
(0, bun_test_1.test)("compares addresses case-insensitively", () => {
|
|
75
|
+
const out = (0, hoistUniform_1.hoistUniformAddresses)({
|
|
76
|
+
"1": { permit2: "0xAA" },
|
|
77
|
+
"10": { permit2: "0xaa" },
|
|
78
|
+
});
|
|
79
|
+
// Same address, different casing: uniform, so it hoists and neither chain
|
|
80
|
+
// keeps a redundant entry.
|
|
81
|
+
(0, bun_test_1.expect)(out["*"].permit2).toBeDefined();
|
|
82
|
+
(0, bun_test_1.expect)(Object.keys(out["1"])).not.toContain("permit2");
|
|
83
|
+
});
|
|
84
|
+
});
|
package/dist/scripts/generate.js
CHANGED
|
@@ -9,6 +9,7 @@ const promises_1 = require("node:fs/promises");
|
|
|
9
9
|
const node_os_1 = __importDefault(require("node:os"));
|
|
10
10
|
const node_path_1 = __importDefault(require("node:path"));
|
|
11
11
|
const validation_1 = require("./validation");
|
|
12
|
+
const hoistUniform_1 = require("./hoistUniform");
|
|
12
13
|
function renderNetworkEnum(name, entries) {
|
|
13
14
|
const lines = entries.map((entry) => entry.viemChain
|
|
14
15
|
? ` ${entry.enumKey} = ${entry.viemChain}.id,`
|
|
@@ -473,9 +474,11 @@ async function generate() {
|
|
|
473
474
|
throw new Error("ABI signatures are empty. yeet-orchestrator-file likely failed silently.");
|
|
474
475
|
}
|
|
475
476
|
const overrides = loadContractOverrides(sharedConfigsRoot);
|
|
476
|
-
const prodContractsMerged = mergeContracts(prodContracts, overrides.prod ?? {});
|
|
477
477
|
const devOverrides = overrides.dev ?? overrides.staging ?? {};
|
|
478
|
-
|
|
478
|
+
// Hoist after merging overrides, so an override that makes an address uniform
|
|
479
|
+
// (or breaks its uniformity) is reflected in what lands in the wildcard.
|
|
480
|
+
const prodContractsMerged = (0, hoistUniform_1.hoistUniformAddresses)(mergeContracts(prodContracts, overrides.prod ?? {}));
|
|
481
|
+
const stagingContractsMerged = (0, hoistUniform_1.hoistUniformAddresses)(mergeContracts(stagingContracts, devOverrides));
|
|
479
482
|
await (0, promises_1.writeFile)(node_path_1.default.join(generatedDir, "contracts.ts"), `${renderContracts(prodContractsMerged)}\n`);
|
|
480
483
|
await (0, promises_1.writeFile)(node_path_1.default.join(configsDir, "contracts.json"), `${JSON.stringify(prodContractsMerged, null, 2)}\n`);
|
|
481
484
|
await (0, promises_1.writeFile)(node_path_1.default.join(generatedDir, "contracts.dev.ts"), `${renderContracts(stagingContractsMerged)}\n`);
|