@paraswap/dex-lib 2.28.12-ramses.2 → 2.29.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.
Files changed (35) hide show
  1. package/build/dex/index.js +0 -2
  2. package/build/dex/index.js.map +1 -1
  3. package/build/dex/solidly/config.js +1 -11
  4. package/build/dex/solidly/config.js.map +1 -1
  5. package/build/dex/solidly/forks-override/ramses.js +2 -2
  6. package/build/dex/solidly/forks-override/ramses.js.map +1 -1
  7. package/build/dex/solidly/solidly.js +0 -1
  8. package/build/dex/solidly/solidly.js.map +1 -1
  9. package/build/dex/uniswap-v3/config.js +22 -0
  10. package/build/dex/uniswap-v3/config.js.map +1 -1
  11. package/build/dex/uniswap-v3/types.d.ts +6 -1
  12. package/build/dex/uniswap-v3/types.js.map +1 -1
  13. package/build/dex/uniswap-v3/uniswap-v3-pool.d.ts +3 -2
  14. package/build/dex/uniswap-v3/uniswap-v3-pool.js +5 -2
  15. package/build/dex/uniswap-v3/uniswap-v3-pool.js.map +1 -1
  16. package/build/dex/uniswap-v3/uniswap-v3.js +7 -3
  17. package/build/dex/uniswap-v3/uniswap-v3.js.map +1 -1
  18. package/package.json +1 -1
  19. package/src/abi/RamsesV2Pool.abi.json +1554 -0
  20. package/src/abi/RamsesV2Quoter.abi.json +274 -0
  21. package/src/abi/RamsesV2StateMulticall.abi.json +891 -0
  22. package/src/dex/index.ts +0 -2
  23. package/src/dex/solidly/config.ts +1 -13
  24. package/src/dex/solidly/solidly-e2e.test.ts +0 -95
  25. package/src/dex/solidly/solidly-integration.test.ts +1 -141
  26. package/src/dex/solidly/solidly.ts +0 -2
  27. package/src/dex/uniswap-v3/config.ts +22 -0
  28. package/src/dex/uniswap-v3/forks/ramses-v2/utils.ts +72 -0
  29. package/src/dex/uniswap-v3/types.ts +7 -1
  30. package/src/dex/uniswap-v3/uniswap-v3-e2e.test.ts +445 -354
  31. package/src/dex/uniswap-v3/uniswap-v3-integration.test.ts +171 -13
  32. package/src/dex/uniswap-v3/uniswap-v3-pool.ts +7 -2
  33. package/src/dex/uniswap-v3/uniswap-v3.ts +7 -2
  34. package/tests/constants-e2e.ts +1 -1
  35. package/src/dex/solidly/forks-override/ramses.ts +0 -224
@@ -0,0 +1,274 @@
1
+ [
2
+ {
3
+ "inputs": [],
4
+ "stateMutability": "nonpayable",
5
+ "type": "constructor"
6
+ },
7
+ {
8
+ "inputs": [],
9
+ "name": "WETH9",
10
+ "outputs": [
11
+ {
12
+ "internalType": "address",
13
+ "name": "",
14
+ "type": "address"
15
+ }
16
+ ],
17
+ "stateMutability": "view",
18
+ "type": "function"
19
+ },
20
+ {
21
+ "inputs": [],
22
+ "name": "factory",
23
+ "outputs": [
24
+ {
25
+ "internalType": "address",
26
+ "name": "",
27
+ "type": "address"
28
+ }
29
+ ],
30
+ "stateMutability": "view",
31
+ "type": "function"
32
+ },
33
+ {
34
+ "inputs": [
35
+ {
36
+ "internalType": "address",
37
+ "name": "_factory",
38
+ "type": "address"
39
+ },
40
+ {
41
+ "internalType": "address",
42
+ "name": "_WETH9",
43
+ "type": "address"
44
+ }
45
+ ],
46
+ "name": "initialize",
47
+ "outputs": [],
48
+ "stateMutability": "nonpayable",
49
+ "type": "function"
50
+ },
51
+ {
52
+ "inputs": [
53
+ {
54
+ "internalType": "bytes",
55
+ "name": "path",
56
+ "type": "bytes"
57
+ },
58
+ {
59
+ "internalType": "uint256",
60
+ "name": "amountIn",
61
+ "type": "uint256"
62
+ }
63
+ ],
64
+ "name": "quoteExactInput",
65
+ "outputs": [
66
+ {
67
+ "internalType": "uint256",
68
+ "name": "amountOut",
69
+ "type": "uint256"
70
+ },
71
+ {
72
+ "internalType": "uint160[]",
73
+ "name": "sqrtPriceX96AfterList",
74
+ "type": "uint160[]"
75
+ },
76
+ {
77
+ "internalType": "uint32[]",
78
+ "name": "initializedTicksCrossedList",
79
+ "type": "uint32[]"
80
+ },
81
+ {
82
+ "internalType": "uint256",
83
+ "name": "gasEstimate",
84
+ "type": "uint256"
85
+ }
86
+ ],
87
+ "stateMutability": "nonpayable",
88
+ "type": "function"
89
+ },
90
+ {
91
+ "inputs": [
92
+ {
93
+ "components": [
94
+ {
95
+ "internalType": "address",
96
+ "name": "tokenIn",
97
+ "type": "address"
98
+ },
99
+ {
100
+ "internalType": "address",
101
+ "name": "tokenOut",
102
+ "type": "address"
103
+ },
104
+ {
105
+ "internalType": "uint256",
106
+ "name": "amountIn",
107
+ "type": "uint256"
108
+ },
109
+ {
110
+ "internalType": "uint24",
111
+ "name": "fee",
112
+ "type": "uint24"
113
+ },
114
+ {
115
+ "internalType": "uint160",
116
+ "name": "sqrtPriceLimitX96",
117
+ "type": "uint160"
118
+ }
119
+ ],
120
+ "internalType": "struct IQuoterV2.QuoteExactInputSingleParams",
121
+ "name": "params",
122
+ "type": "tuple"
123
+ }
124
+ ],
125
+ "name": "quoteExactInputSingle",
126
+ "outputs": [
127
+ {
128
+ "internalType": "uint256",
129
+ "name": "amountOut",
130
+ "type": "uint256"
131
+ },
132
+ {
133
+ "internalType": "uint160",
134
+ "name": "sqrtPriceX96After",
135
+ "type": "uint160"
136
+ },
137
+ {
138
+ "internalType": "uint32",
139
+ "name": "initializedTicksCrossed",
140
+ "type": "uint32"
141
+ },
142
+ {
143
+ "internalType": "uint256",
144
+ "name": "gasEstimate",
145
+ "type": "uint256"
146
+ }
147
+ ],
148
+ "stateMutability": "nonpayable",
149
+ "type": "function"
150
+ },
151
+ {
152
+ "inputs": [
153
+ {
154
+ "internalType": "bytes",
155
+ "name": "path",
156
+ "type": "bytes"
157
+ },
158
+ {
159
+ "internalType": "uint256",
160
+ "name": "amountOut",
161
+ "type": "uint256"
162
+ }
163
+ ],
164
+ "name": "quoteExactOutput",
165
+ "outputs": [
166
+ {
167
+ "internalType": "uint256",
168
+ "name": "amountIn",
169
+ "type": "uint256"
170
+ },
171
+ {
172
+ "internalType": "uint160[]",
173
+ "name": "sqrtPriceX96AfterList",
174
+ "type": "uint160[]"
175
+ },
176
+ {
177
+ "internalType": "uint32[]",
178
+ "name": "initializedTicksCrossedList",
179
+ "type": "uint32[]"
180
+ },
181
+ {
182
+ "internalType": "uint256",
183
+ "name": "gasEstimate",
184
+ "type": "uint256"
185
+ }
186
+ ],
187
+ "stateMutability": "nonpayable",
188
+ "type": "function"
189
+ },
190
+ {
191
+ "inputs": [
192
+ {
193
+ "components": [
194
+ {
195
+ "internalType": "address",
196
+ "name": "tokenIn",
197
+ "type": "address"
198
+ },
199
+ {
200
+ "internalType": "address",
201
+ "name": "tokenOut",
202
+ "type": "address"
203
+ },
204
+ {
205
+ "internalType": "uint256",
206
+ "name": "amount",
207
+ "type": "uint256"
208
+ },
209
+ {
210
+ "internalType": "uint24",
211
+ "name": "fee",
212
+ "type": "uint24"
213
+ },
214
+ {
215
+ "internalType": "uint160",
216
+ "name": "sqrtPriceLimitX96",
217
+ "type": "uint160"
218
+ }
219
+ ],
220
+ "internalType": "struct IQuoterV2.QuoteExactOutputSingleParams",
221
+ "name": "params",
222
+ "type": "tuple"
223
+ }
224
+ ],
225
+ "name": "quoteExactOutputSingle",
226
+ "outputs": [
227
+ {
228
+ "internalType": "uint256",
229
+ "name": "amountIn",
230
+ "type": "uint256"
231
+ },
232
+ {
233
+ "internalType": "uint160",
234
+ "name": "sqrtPriceX96After",
235
+ "type": "uint160"
236
+ },
237
+ {
238
+ "internalType": "uint32",
239
+ "name": "initializedTicksCrossed",
240
+ "type": "uint32"
241
+ },
242
+ {
243
+ "internalType": "uint256",
244
+ "name": "gasEstimate",
245
+ "type": "uint256"
246
+ }
247
+ ],
248
+ "stateMutability": "nonpayable",
249
+ "type": "function"
250
+ },
251
+ {
252
+ "inputs": [
253
+ {
254
+ "internalType": "int256",
255
+ "name": "amount0Delta",
256
+ "type": "int256"
257
+ },
258
+ {
259
+ "internalType": "int256",
260
+ "name": "amount1Delta",
261
+ "type": "int256"
262
+ },
263
+ {
264
+ "internalType": "bytes",
265
+ "name": "path",
266
+ "type": "bytes"
267
+ }
268
+ ],
269
+ "name": "ramsesV2SwapCallback",
270
+ "outputs": [],
271
+ "stateMutability": "view",
272
+ "type": "function"
273
+ }
274
+ ]