@orca-so/whirlpools-automation 0.4.0 → 0.5.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/README.md +1 -5
- package/dist/generated/errors/whirlpoolsAutomationProgram.d.ts +2 -4
- package/dist/generated/instructions/harvestSwapAndReinvestPost.d.ts +1 -1
- package/dist/generated/instructions/harvestSwapAndReinvestPre.d.ts +1 -1
- package/dist/generated/instructions/index.d.ts +0 -1
- package/dist/generated/programs/whirlpoolsAutomationProgram.d.ts +2 -7
- package/dist/generated/types/action.d.ts +1 -2
- package/dist/index.browser.js +1631 -1798
- package/dist/index.node.js +1534 -1701
- package/package.json +1 -1
package/dist/index.browser.js
CHANGED
|
@@ -1,234 +1,234 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
t in e ?
|
|
4
|
-
var
|
|
5
|
-
var
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
1
|
+
var Fn = Object.defineProperty;
|
|
2
|
+
var zn = (e, t, n) =>
|
|
3
|
+
t in e ? Fn(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : (e[t] = n);
|
|
4
|
+
var g = (e, t, n) => zn(e, typeof t != 'symbol' ? t + '' : t, n);
|
|
5
|
+
var Hn = 1,
|
|
6
|
+
Wn = 2,
|
|
7
|
+
$n = 3,
|
|
8
|
+
Xn = 4,
|
|
9
|
+
Yn = 5,
|
|
10
|
+
Kn = 6,
|
|
11
|
+
jn = 7,
|
|
12
|
+
Jn = 8,
|
|
13
|
+
qn = 9,
|
|
14
|
+
Zn = 10,
|
|
15
|
+
Qn = -32700,
|
|
16
|
+
er = -32603,
|
|
17
|
+
tr = -32602,
|
|
18
|
+
nr = -32601,
|
|
19
|
+
rr = -32600,
|
|
20
|
+
or = -32016,
|
|
21
|
+
ar = -32015,
|
|
22
|
+
ir = -32014,
|
|
23
|
+
sr = -32013,
|
|
24
|
+
_r = -32012,
|
|
25
|
+
cr = -32011,
|
|
26
|
+
Rr = -32010,
|
|
27
|
+
ur = -32009,
|
|
28
|
+
Ar = -32008,
|
|
29
|
+
dr = -32007,
|
|
30
|
+
Or = -32006,
|
|
31
|
+
lr = -32005,
|
|
32
|
+
Er = -32004,
|
|
33
|
+
Nr = -32003,
|
|
34
|
+
Tr = -32002,
|
|
35
|
+
Sr = -32001,
|
|
36
36
|
Je = 28e5,
|
|
37
37
|
qe = 2800001,
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
38
|
+
fr = 2800002,
|
|
39
|
+
Ir = 2800003,
|
|
40
|
+
gr = 2800004,
|
|
41
|
+
mr = 2800005,
|
|
42
42
|
Ze = 2800006,
|
|
43
43
|
Qe = 2800007,
|
|
44
|
-
|
|
44
|
+
Le = 2800008,
|
|
45
45
|
et = 2800009,
|
|
46
|
-
|
|
47
|
-
|
|
46
|
+
Cr = 2800010,
|
|
47
|
+
hr = 2800011,
|
|
48
48
|
tt = 323e4,
|
|
49
49
|
nt = 32300001,
|
|
50
50
|
rt = 3230002,
|
|
51
|
-
|
|
52
|
-
|
|
51
|
+
Lr = 3230003,
|
|
52
|
+
vr = 3230004,
|
|
53
53
|
ot = 361e4,
|
|
54
54
|
at = 3610001,
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
55
|
+
pr = 3610002,
|
|
56
|
+
Dr = 3610003,
|
|
57
|
+
br = 3610004,
|
|
58
|
+
Ur = 3610005,
|
|
59
|
+
Pr = 3610006,
|
|
60
|
+
wr = 3610007,
|
|
61
|
+
xr = 3611e3,
|
|
62
|
+
Mr = 3704e3,
|
|
63
|
+
yr = 3704001,
|
|
64
|
+
kr = 3704002,
|
|
65
|
+
Br = 3704003,
|
|
66
|
+
Gr = 3704004,
|
|
67
67
|
it = 4128e3,
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
68
|
+
Vr = 4128001,
|
|
69
|
+
Fr = 4128002,
|
|
70
|
+
zr = 4615e3,
|
|
71
|
+
Hr = 4615001,
|
|
72
|
+
Wr = 4615002,
|
|
73
|
+
$r = 4615003,
|
|
74
|
+
Xr = 4615004,
|
|
75
|
+
Yr = 4615005,
|
|
76
|
+
Kr = 4615006,
|
|
77
|
+
jr = 4615007,
|
|
78
|
+
Jr = 4615008,
|
|
79
|
+
qr = 4615009,
|
|
80
|
+
Zr = 4615010,
|
|
81
|
+
Qr = 4615011,
|
|
82
|
+
eo = 4615012,
|
|
83
|
+
to = 4615013,
|
|
84
|
+
no = 4615014,
|
|
85
|
+
ro = 4615015,
|
|
86
|
+
oo = 4615016,
|
|
87
|
+
ao = 4615017,
|
|
88
|
+
io = 4615018,
|
|
89
|
+
so = 4615019,
|
|
90
|
+
_o = 4615020,
|
|
91
|
+
co = 4615021,
|
|
92
|
+
Ro = 4615022,
|
|
93
|
+
uo = 4615023,
|
|
94
|
+
Ao = 4615024,
|
|
95
|
+
Oo = 4615025,
|
|
96
96
|
st = 4615026,
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
97
|
+
lo = 4615027,
|
|
98
|
+
Eo = 4615028,
|
|
99
|
+
No = 4615029,
|
|
100
|
+
To = 4615030,
|
|
101
|
+
So = 4615031,
|
|
102
|
+
fo = 4615032,
|
|
103
|
+
Io = 4615033,
|
|
104
|
+
go = 4615034,
|
|
105
|
+
mo = 4615035,
|
|
106
|
+
Co = 4615036,
|
|
107
|
+
ho = 4615037,
|
|
108
|
+
Lo = 4615038,
|
|
109
|
+
vo = 4615039,
|
|
110
|
+
po = 4615040,
|
|
111
|
+
Do = 4615041,
|
|
112
|
+
bo = 4615042,
|
|
113
|
+
Uo = 4615043,
|
|
114
|
+
Po = 4615044,
|
|
115
|
+
wo = 4615045,
|
|
116
|
+
xo = 4615046,
|
|
117
|
+
Mo = 4615047,
|
|
118
|
+
yo = 4615048,
|
|
119
|
+
ko = 4615049,
|
|
120
|
+
Bo = 4615050,
|
|
121
|
+
Go = 4615051,
|
|
122
|
+
Vo = 4615052,
|
|
123
|
+
Fo = 4615053,
|
|
124
|
+
zo = 4615054,
|
|
125
|
+
Ho = 5508e3,
|
|
126
|
+
Wo = 5508001,
|
|
127
|
+
$o = 5508002,
|
|
128
|
+
Xo = 5508003,
|
|
129
|
+
Yo = 5508004,
|
|
130
|
+
Ko = 5508005,
|
|
131
|
+
jo = 5508006,
|
|
132
|
+
Jo = 5508007,
|
|
133
|
+
qo = 5508008,
|
|
134
|
+
Zo = 5508009,
|
|
135
|
+
Qo = 5508010,
|
|
136
|
+
ea = 5508011,
|
|
137
|
+
ta = 5663e3,
|
|
138
|
+
na = 5663001,
|
|
139
|
+
ra = 5663002,
|
|
140
|
+
oa = 5663003,
|
|
141
|
+
aa = 5663004,
|
|
142
|
+
ia = 5663005,
|
|
143
|
+
sa = 5663006,
|
|
144
|
+
_a = 5663007,
|
|
145
|
+
ca = 5663008,
|
|
146
|
+
Ra = 5663009,
|
|
147
|
+
ua = 5663010,
|
|
148
|
+
Aa = 5663011,
|
|
149
|
+
da = 5663012,
|
|
150
|
+
Oa = 5663013,
|
|
151
|
+
la = 5663014,
|
|
152
|
+
Ea = 5663015,
|
|
153
|
+
Na = 5663016,
|
|
154
|
+
Ta = 5663017,
|
|
155
|
+
Sa = 5663018,
|
|
156
|
+
fa = 5663019,
|
|
157
|
+
Ia = 5663020,
|
|
158
|
+
ga = 705e4,
|
|
159
|
+
ma = 7050001,
|
|
160
|
+
Ca = 7050002,
|
|
161
|
+
ha = 7050003,
|
|
162
|
+
La = 7050004,
|
|
163
|
+
va = 7050005,
|
|
164
|
+
pa = 7050006,
|
|
165
|
+
Da = 7050007,
|
|
166
|
+
ba = 7050008,
|
|
167
|
+
Ua = 7050009,
|
|
168
|
+
Pa = 7050010,
|
|
169
|
+
wa = 7050011,
|
|
170
|
+
xa = 7050012,
|
|
171
|
+
Ma = 7050013,
|
|
172
|
+
ya = 7050014,
|
|
173
|
+
ka = 7050015,
|
|
174
|
+
Ba = 7050016,
|
|
175
|
+
Ga = 7050017,
|
|
176
|
+
Va = 7050018,
|
|
177
|
+
Fa = 7050019,
|
|
178
|
+
za = 7050020,
|
|
179
|
+
Ha = 7050021,
|
|
180
|
+
Wa = 7050022,
|
|
181
|
+
$a = 7050023,
|
|
182
|
+
Xa = 7050024,
|
|
183
|
+
Ya = 7050025,
|
|
184
|
+
Ka = 7050026,
|
|
185
|
+
ja = 7050027,
|
|
186
|
+
Ja = 7050028,
|
|
187
|
+
qa = 7050029,
|
|
188
|
+
Za = 7050030,
|
|
189
|
+
Qa = 7050031,
|
|
190
|
+
ei = 7050032,
|
|
191
|
+
ti = 7050033,
|
|
192
|
+
ni = 7050034,
|
|
193
|
+
ri = 7050035,
|
|
194
|
+
oi = 7050036,
|
|
195
195
|
_t = 8078e3,
|
|
196
196
|
ct = 8078001,
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
197
|
+
Rt = 8078002,
|
|
198
|
+
ai = 8078003,
|
|
199
|
+
ut = 8078004,
|
|
200
200
|
At = 8078005,
|
|
201
201
|
dt = 8078006,
|
|
202
|
-
|
|
203
|
-
|
|
202
|
+
Ot = 8078007,
|
|
203
|
+
lt = 8078008,
|
|
204
204
|
Et = 8078009,
|
|
205
205
|
Nt = 8078010,
|
|
206
206
|
Tt = 8078011,
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
207
|
+
Re = 8078012,
|
|
208
|
+
ii = 8078013,
|
|
209
|
+
si = 8078014,
|
|
210
|
+
_i = 8078015,
|
|
211
|
+
ci = 8078016,
|
|
212
212
|
St = 8078017,
|
|
213
213
|
ft = 8078018,
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
214
|
+
Ri = 8078019,
|
|
215
|
+
ui = 8078020,
|
|
216
|
+
Ai = 8078021,
|
|
217
|
+
ve = 8078022,
|
|
218
|
+
di = 81e5,
|
|
219
|
+
Oi = 8100001,
|
|
220
|
+
li = 8100002,
|
|
221
|
+
Ei = 8100003,
|
|
222
|
+
Ni = 819e4,
|
|
223
|
+
Ti = 8190001,
|
|
224
|
+
Si = 8190002,
|
|
225
|
+
fi = 8190003,
|
|
226
|
+
Ii = 8190004,
|
|
227
|
+
gi = 99e5,
|
|
228
|
+
mi = 9900001,
|
|
229
|
+
Ci = 9900002,
|
|
230
|
+
hi = 9900003,
|
|
231
|
+
Li = 9900004;
|
|
232
232
|
function It(e) {
|
|
233
233
|
return Array.isArray(e)
|
|
234
234
|
? '%5B' +
|
|
@@ -249,269 +249,269 @@ function It(e) {
|
|
|
249
249
|
)
|
|
250
250
|
);
|
|
251
251
|
}
|
|
252
|
-
function
|
|
252
|
+
function vi([e, t]) {
|
|
253
253
|
return `${e}=${It(t)}`;
|
|
254
254
|
}
|
|
255
|
-
function
|
|
256
|
-
const t = Object.entries(e).map(
|
|
255
|
+
function pi(e) {
|
|
256
|
+
const t = Object.entries(e).map(vi).join('&');
|
|
257
257
|
return btoa(t);
|
|
258
258
|
}
|
|
259
|
-
var
|
|
259
|
+
var Di = {
|
|
260
260
|
[tt]: 'Account not found at address: $address',
|
|
261
|
-
[
|
|
262
|
-
[
|
|
261
|
+
[vr]: 'Not all accounts were decoded. Encoded accounts found at addresses: $addresses.',
|
|
262
|
+
[Lr]: 'Expected decoded account at address: $address',
|
|
263
263
|
[rt]: 'Failed to decode account data at address: $address',
|
|
264
264
|
[nt]: 'Accounts not found at addresses: $addresses',
|
|
265
265
|
[et]: 'Unable to find a viable program address bump seed.',
|
|
266
|
-
[
|
|
266
|
+
[fr]: '$putativeAddress is not a base58-encoded address.',
|
|
267
267
|
[Je]: 'Expected base58 encoded address to decode to a byte array of length 32. Actual length: $actualLength.',
|
|
268
|
-
[
|
|
269
|
-
[
|
|
270
|
-
[
|
|
271
|
-
[
|
|
268
|
+
[Ir]: 'The `CryptoKey` must be an `Ed25519` public key.',
|
|
269
|
+
[hr]: '$putativeOffCurveAddress is not a base58-encoded off-curve address.',
|
|
270
|
+
[Le]: 'Invalid seeds; point must fall off the Ed25519 curve.',
|
|
271
|
+
[gr]: 'Expected given program derived address to have the following format: [Address, ProgramDerivedAddressBump].',
|
|
272
272
|
[Ze]: 'A maximum of $maxSeeds seeds, including the bump seed, may be supplied when creating an address. Received: $actual.',
|
|
273
273
|
[Qe]: 'The seed at index $index with length $actual exceeds the maximum length of $maxSeedLength bytes.',
|
|
274
|
-
[
|
|
275
|
-
[
|
|
274
|
+
[mr]: 'Expected program derived address bump to be in the range [0, 255], got: $bump.',
|
|
275
|
+
[Cr]: 'Program address cannot end with PDA marker.',
|
|
276
276
|
[qe]: 'Expected base58-encoded address string of length in the range [32, 44]. Actual length: $actualLength.',
|
|
277
|
-
[
|
|
278
|
-
[
|
|
277
|
+
[Xn]: 'Expected base58-encoded blockash string of length in the range [32, 44]. Actual length: $actualLength.',
|
|
278
|
+
[Hn]: 'The network has progressed past the last block for which this transaction could have been committed.',
|
|
279
279
|
[_t]: 'Codec [$codecDescription] cannot decode empty byte arrays.',
|
|
280
|
-
[
|
|
281
|
-
[
|
|
280
|
+
[ve]: 'Enum codec cannot use lexical values [$stringValues] as discriminators. Either remove all lexical values or set `useValuesAsDiscriminators` to `false`.',
|
|
281
|
+
[ui]: 'Sentinel [$hexSentinel] must not be present in encoded bytes [$hexEncodedBytes].',
|
|
282
282
|
[At]: 'Encoder and decoder must have the same fixed size, got [$encoderFixedSize] and [$decoderFixedSize].',
|
|
283
283
|
[dt]: 'Encoder and decoder must have the same max size, got [$encoderMaxSize] and [$decoderMaxSize].',
|
|
284
|
-
[
|
|
285
|
-
[
|
|
286
|
-
[
|
|
287
|
-
[
|
|
288
|
-
[
|
|
289
|
-
[
|
|
284
|
+
[ut]: 'Encoder and decoder must either both be fixed-size or variable-size.',
|
|
285
|
+
[lt]: 'Enum discriminator out of range. Expected a number in [$formattedValidDiscriminators], got $discriminator.',
|
|
286
|
+
[Rt]: 'Expected a fixed-size codec, got a variable-size one.',
|
|
287
|
+
[ii]: 'Codec [$codecDescription] expected a positive byte length, got $bytesLength.',
|
|
288
|
+
[ai]: 'Expected a variable-size codec, got a fixed-size one.',
|
|
289
|
+
[Ri]: 'Codec [$codecDescription] expected zero-value [$hexZeroValue] to have the same size as the provided fixed-size item [$expectedSize bytes].',
|
|
290
290
|
[ct]: 'Codec [$codecDescription] expected $expected bytes, got $bytesLength.',
|
|
291
291
|
[ft]: 'Expected byte array constant [$hexConstant] to be present in data [$hexData] at offset [$offset].',
|
|
292
292
|
[Et]: 'Invalid discriminated union variant. Expected one of [$variants], got $value.',
|
|
293
293
|
[Nt]: 'Invalid enum variant. Expected one of [$stringValues] or a number in [$formattedNumericalValues], got $variant.',
|
|
294
|
-
[
|
|
295
|
-
[
|
|
296
|
-
[
|
|
297
|
-
[
|
|
294
|
+
[_i]: 'Invalid literal union variant. Expected one of [$variants], got $value.',
|
|
295
|
+
[Ot]: 'Expected [$codecDescription] to have $expected items, got $actual.',
|
|
296
|
+
[Re]: 'Invalid value $value for base $base with alphabet $alphabet.',
|
|
297
|
+
[ci]: 'Literal union discriminator out of range. Expected a number between $minRange and $maxRange, got $discriminator.',
|
|
298
298
|
[Tt]: 'Codec [$codecDescription] expected number to be in the range [$min, $max], got $value.',
|
|
299
|
-
[
|
|
300
|
-
[
|
|
299
|
+
[si]: 'Codec [$codecDescription] expected offset to be in the range [0, $bytesLength], got $offset.',
|
|
300
|
+
[Ai]: 'Expected sentinel [$hexSentinel] to be present in decoded bytes [$hexDecodedBytes].',
|
|
301
301
|
[St]: 'Union variant out of range. Expected an index between $minRange and $maxRange, got $variant.',
|
|
302
|
-
[
|
|
303
|
-
[
|
|
304
|
-
[
|
|
305
|
-
[
|
|
306
|
-
[
|
|
307
|
-
[
|
|
308
|
-
[
|
|
309
|
-
[
|
|
310
|
-
[
|
|
311
|
-
[
|
|
312
|
-
[
|
|
313
|
-
[
|
|
314
|
-
[
|
|
302
|
+
[xr]: 'No random values implementation could be found.',
|
|
303
|
+
[qr]: 'instruction requires an uninitialized account',
|
|
304
|
+
[uo]: 'instruction tries to borrow reference for an account which is already borrowed',
|
|
305
|
+
[Ao]: 'instruction left account with an outstanding borrowed reference',
|
|
306
|
+
[co]: "program other than the account's owner changed the size of the account data",
|
|
307
|
+
[Yr]: 'account data too small for instruction',
|
|
308
|
+
[Ro]: 'instruction expected an executable account',
|
|
309
|
+
[xo]: 'An account does not have enough lamports to be rent-exempt',
|
|
310
|
+
[yo]: 'Program arithmetic overflowed',
|
|
311
|
+
[wo]: 'Failed to serialize or deserialize account data: $encodedData',
|
|
312
|
+
[zo]: 'Builtin programs must consume compute units',
|
|
313
|
+
[fo]: 'Cross-program invocation call depth too deep',
|
|
314
|
+
[Lo]: 'Computational budget exceeded',
|
|
315
315
|
[st]: 'custom program error: #$code',
|
|
316
|
-
[
|
|
317
|
-
[
|
|
318
|
-
[
|
|
319
|
-
[
|
|
320
|
-
[
|
|
321
|
-
[
|
|
322
|
-
[
|
|
323
|
-
[
|
|
324
|
-
[
|
|
325
|
-
[
|
|
326
|
-
[
|
|
327
|
-
[
|
|
328
|
-
[
|
|
329
|
-
[
|
|
330
|
-
[
|
|
331
|
-
[
|
|
332
|
-
[
|
|
333
|
-
[
|
|
334
|
-
[
|
|
335
|
-
[
|
|
336
|
-
[
|
|
337
|
-
[
|
|
338
|
-
[
|
|
339
|
-
[
|
|
340
|
-
[
|
|
341
|
-
[
|
|
342
|
-
[
|
|
343
|
-
[
|
|
344
|
-
[
|
|
345
|
-
[
|
|
346
|
-
[
|
|
347
|
-
[
|
|
348
|
-
[
|
|
349
|
-
[
|
|
350
|
-
[
|
|
351
|
-
[
|
|
352
|
-
[
|
|
353
|
-
[
|
|
354
|
-
[
|
|
355
|
-
[
|
|
356
|
-
[
|
|
357
|
-
[
|
|
316
|
+
[ao]: 'instruction contains duplicate accounts',
|
|
317
|
+
[Oo]: 'instruction modifications of multiply-passed account differ',
|
|
318
|
+
[To]: 'executable accounts must be rent exempt',
|
|
319
|
+
[Eo]: 'instruction changed executable accounts data',
|
|
320
|
+
[No]: 'instruction changed the balance of an executable account',
|
|
321
|
+
[io]: 'instruction changed executable bit of an account',
|
|
322
|
+
[no]: 'instruction modified data of an account it does not own',
|
|
323
|
+
[to]: 'instruction spent from the balance of an account it does not own',
|
|
324
|
+
[Hr]: 'generic instruction error',
|
|
325
|
+
[Bo]: 'Provided owner is not allowed',
|
|
326
|
+
[Uo]: 'Account is immutable',
|
|
327
|
+
[Po]: 'Incorrect authority provided',
|
|
328
|
+
[jr]: 'incorrect program id for instruction',
|
|
329
|
+
[Kr]: 'insufficient funds for instruction',
|
|
330
|
+
[Xr]: 'invalid account data for instruction',
|
|
331
|
+
[Mo]: 'Invalid account owner',
|
|
332
|
+
[Wr]: 'invalid program argument',
|
|
333
|
+
[lo]: 'program returned invalid error code',
|
|
334
|
+
[$r]: 'invalid instruction data',
|
|
335
|
+
[ho]: 'Failed to reallocate account data',
|
|
336
|
+
[Co]: 'Provided seeds do not result in a valid address',
|
|
337
|
+
[Go]: 'Accounts data allocations exceeded the maximum allowed per transaction',
|
|
338
|
+
[Vo]: 'Max accounts exceeded',
|
|
339
|
+
[Fo]: 'Max instruction trace length exceeded',
|
|
340
|
+
[mo]: 'Length of the seed is too long for address generation',
|
|
341
|
+
[Io]: 'An account required by the instruction is missing',
|
|
342
|
+
[Jr]: 'missing required signature for instruction',
|
|
343
|
+
[eo]: 'instruction illegally modified the program id of an account',
|
|
344
|
+
[_o]: 'insufficient account keys for instruction',
|
|
345
|
+
[vo]: 'Cross-program invocation with unauthorized signer or writable account',
|
|
346
|
+
[po]: 'Failed to create program execution environment',
|
|
347
|
+
[bo]: 'Program failed to compile',
|
|
348
|
+
[Do]: 'Program failed to complete',
|
|
349
|
+
[oo]: 'instruction modified data of a read-only account',
|
|
350
|
+
[ro]: 'instruction changed the balance of a read-only account',
|
|
351
|
+
[go]: 'Cross-program invocation reentrancy not allowed for this instruction',
|
|
352
|
+
[so]: 'instruction modified rent epoch of an account',
|
|
353
|
+
[Qr]: 'sum of account balances before and after instruction do not match',
|
|
354
|
+
[Zr]: 'instruction requires an initialized account',
|
|
355
|
+
[zr]: '',
|
|
356
|
+
[So]: 'Unsupported program id',
|
|
357
|
+
[ko]: 'Unsupported sysvar',
|
|
358
358
|
[it]: 'The instruction does not have any accounts.',
|
|
359
|
-
[
|
|
360
|
-
[
|
|
361
|
-
[
|
|
362
|
-
[
|
|
363
|
-
[
|
|
364
|
-
[
|
|
365
|
-
[
|
|
366
|
-
[
|
|
367
|
-
[
|
|
368
|
-
[
|
|
369
|
-
[
|
|
370
|
-
[
|
|
371
|
-
[
|
|
372
|
-
[
|
|
373
|
-
[
|
|
374
|
-
[mr]: '$__serverMessage',
|
|
359
|
+
[Vr]: 'The instruction does not have any data.',
|
|
360
|
+
[Fr]: 'Expected instruction to have progress address $expectedProgramAddress, got $actualProgramAddress.',
|
|
361
|
+
[Yn]: 'Expected base58 encoded blockhash to decode to a byte array of length 32. Actual length: $actualLength.',
|
|
362
|
+
[Wn]: 'The nonce `$expectedNonceValue` is no longer valid. It has advanced to `$actualNonceValue`',
|
|
363
|
+
[Ci]: 'Invariant violation: Found no abortable iterable cache entry for key `$cacheKey`. It should be impossible to hit this error; please file an issue at https://sola.na/web3invariant',
|
|
364
|
+
[Li]: 'Invariant violation: This data publisher does not publish to the channel named `$channelName`. Supported channels include $supportedChannelNames.',
|
|
365
|
+
[mi]: 'Invariant violation: WebSocket message iterator state is corrupt; iterated without first resolving existing message promise. It should be impossible to hit this error; please file an issue at https://sola.na/web3invariant',
|
|
366
|
+
[gi]: 'Invariant violation: WebSocket message iterator is missing state storage. It should be impossible to hit this error; please file an issue at https://sola.na/web3invariant',
|
|
367
|
+
[hi]: 'Invariant violation: Switch statement non-exhaustive. Received unexpected value `$unexpectedValue`. It should be impossible to hit this error; please file an issue at https://sola.na/web3invariant',
|
|
368
|
+
[er]: 'JSON-RPC error: Internal JSON-RPC error ($__serverMessage)',
|
|
369
|
+
[tr]: 'JSON-RPC error: Invalid method parameter(s) ($__serverMessage)',
|
|
370
|
+
[rr]: 'JSON-RPC error: The JSON sent is not a valid `Request` object ($__serverMessage)',
|
|
371
|
+
[nr]: 'JSON-RPC error: The method does not exist / is not available ($__serverMessage)',
|
|
372
|
+
[Qn]: 'JSON-RPC error: An error occurred on the server while parsing the JSON text ($__serverMessage)',
|
|
373
|
+
[_r]: '$__serverMessage',
|
|
375
374
|
[Sr]: '$__serverMessage',
|
|
376
|
-
[cr]: '$__serverMessage',
|
|
377
|
-
[dr]: '$__serverMessage',
|
|
378
|
-
[lr]: '$__serverMessage',
|
|
379
|
-
[sr]: 'Minimum context slot has not been reached',
|
|
380
|
-
[Tr]: 'Node is unhealthy; behind by $numSlotsBehind slots',
|
|
381
|
-
[Or]: 'No snapshot',
|
|
382
|
-
[Ir]: 'Transaction simulation failed',
|
|
383
375
|
[Er]: '$__serverMessage',
|
|
384
|
-
[
|
|
385
|
-
[
|
|
386
|
-
[ur]: '
|
|
387
|
-
[
|
|
388
|
-
[
|
|
389
|
-
[
|
|
390
|
-
[
|
|
391
|
-
[
|
|
392
|
-
[
|
|
393
|
-
[
|
|
394
|
-
[
|
|
395
|
-
[
|
|
396
|
-
[
|
|
397
|
-
[
|
|
398
|
-
[
|
|
399
|
-
[
|
|
400
|
-
[
|
|
401
|
-
[
|
|
402
|
-
[
|
|
403
|
-
[
|
|
404
|
-
[
|
|
405
|
-
[
|
|
406
|
-
[
|
|
407
|
-
[Ni]: '
|
|
408
|
-
[
|
|
409
|
-
[
|
|
410
|
-
[
|
|
411
|
-
[
|
|
412
|
-
[
|
|
413
|
-
[
|
|
414
|
-
[
|
|
415
|
-
[
|
|
416
|
-
[
|
|
417
|
-
[
|
|
418
|
-
[
|
|
419
|
-
[
|
|
420
|
-
[
|
|
376
|
+
[ir]: '$__serverMessage',
|
|
377
|
+
[Rr]: '$__serverMessage',
|
|
378
|
+
[ur]: '$__serverMessage',
|
|
379
|
+
[or]: 'Minimum context slot has not been reached',
|
|
380
|
+
[lr]: 'Node is unhealthy; behind by $numSlotsBehind slots',
|
|
381
|
+
[Ar]: 'No snapshot',
|
|
382
|
+
[Tr]: 'Transaction simulation failed',
|
|
383
|
+
[dr]: '$__serverMessage',
|
|
384
|
+
[cr]: 'Transaction history is not available from this node',
|
|
385
|
+
[Or]: '$__serverMessage',
|
|
386
|
+
[sr]: 'Transaction signature length mismatch',
|
|
387
|
+
[Nr]: 'Transaction signature verification failure',
|
|
388
|
+
[ar]: '$__serverMessage',
|
|
389
|
+
[Mr]: 'Key pair bytes must be of length 64, got $byteLength.',
|
|
390
|
+
[yr]: 'Expected private key bytes with length 32. Actual length: $actualLength.',
|
|
391
|
+
[kr]: 'Expected base58-encoded signature to decode to a byte array of length 64. Actual length: $actualLength.',
|
|
392
|
+
[Gr]: 'The provided private key does not match the provided public key.',
|
|
393
|
+
[Br]: 'Expected base58-encoded signature string of length in the range [64, 88]. Actual length: $actualLength.',
|
|
394
|
+
[Kn]: 'Lamports value must be in the range [0, 2e64-1]',
|
|
395
|
+
[jn]: '`$value` cannot be parsed as a `BigInt`',
|
|
396
|
+
[Zn]: '$message',
|
|
397
|
+
[Jn]: '`$value` cannot be parsed as a `Number`',
|
|
398
|
+
[$n]: 'No nonce account could be found at address `$nonceAccountAddress`',
|
|
399
|
+
[Ni]: "The notification name must end in 'Notifications' and the API must supply a subscription plan creator function for the notification '$notificationName'.",
|
|
400
|
+
[Si]: 'WebSocket was closed before payload could be added to the send buffer',
|
|
401
|
+
[fi]: 'WebSocket connection closed',
|
|
402
|
+
[Ii]: 'WebSocket failed to connect',
|
|
403
|
+
[Ti]: 'Failed to obtain a subscription id from the server',
|
|
404
|
+
[Ei]: 'Could not find an API plan for RPC method: `$method`',
|
|
405
|
+
[di]: 'The $argumentLabel argument to the `$methodName` RPC method$optionalPathLabel was `$value`. This number is unsafe for use with the Solana JSON-RPC because it exceeds `Number.MAX_SAFE_INTEGER`.',
|
|
406
|
+
[li]: 'HTTP error ($statusCode): $message',
|
|
407
|
+
[Oi]: 'HTTP header(s) forbidden: $headers. Learn more at https://developer.mozilla.org/en-US/docs/Glossary/Forbidden_header_name.',
|
|
408
|
+
[Ho]: 'Multiple distinct signers were identified for address `$address`. Please ensure that you are using the same signer instance for each address.',
|
|
409
|
+
[Wo]: 'The provided value does not implement the `KeyPairSigner` interface',
|
|
410
|
+
[Xo]: 'The provided value does not implement the `MessageModifyingSigner` interface',
|
|
411
|
+
[Yo]: 'The provided value does not implement the `MessagePartialSigner` interface',
|
|
412
|
+
[$o]: 'The provided value does not implement any of the `MessageSigner` interfaces',
|
|
413
|
+
[jo]: 'The provided value does not implement the `TransactionModifyingSigner` interface',
|
|
414
|
+
[Jo]: 'The provided value does not implement the `TransactionPartialSigner` interface',
|
|
415
|
+
[qo]: 'The provided value does not implement the `TransactionSendingSigner` interface',
|
|
416
|
+
[Ko]: 'The provided value does not implement any of the `TransactionSigner` interfaces',
|
|
417
|
+
[Zo]: 'More than one `TransactionSendingSigner` was identified.',
|
|
418
|
+
[Qo]: 'No `TransactionSendingSigner` was identified. Please provide a valid `TransactionWithSingleSendingSigner` transaction.',
|
|
419
|
+
[ea]: 'Wallet account signers do not support signing multiple messages/transactions in a single operation',
|
|
420
|
+
[wr]: 'Cannot export a non-extractable key.',
|
|
421
421
|
[at]: 'No digest implementation could be found.',
|
|
422
422
|
[ot]: 'Cryptographic operations are only allowed in secure browser contexts. Read more here: https://developer.mozilla.org/en-US/docs/Web/Security/Secure_Contexts.',
|
|
423
|
-
[
|
|
423
|
+
[pr]: `This runtime does not support the generation of Ed25519 key pairs.
|
|
424
424
|
|
|
425
425
|
Install @solana/webcrypto-ed25519-polyfill and call its \`install\` function before generating keys in environments that do not support Ed25519.
|
|
426
426
|
|
|
427
427
|
For a list of runtimes that currently support Ed25519 operations, visit https://github.com/WICG/webcrypto-secure-curves/issues/20.`,
|
|
428
|
-
[
|
|
429
|
-
[
|
|
430
|
-
[
|
|
431
|
-
[
|
|
432
|
-
[
|
|
433
|
-
[
|
|
434
|
-
[
|
|
435
|
-
[
|
|
436
|
-
[
|
|
437
|
-
[
|
|
438
|
-
[
|
|
439
|
-
[
|
|
440
|
-
[
|
|
441
|
-
[
|
|
442
|
-
[
|
|
443
|
-
[
|
|
444
|
-
[
|
|
445
|
-
[
|
|
446
|
-
[
|
|
447
|
-
[
|
|
448
|
-
[
|
|
449
|
-
[
|
|
450
|
-
[
|
|
451
|
-
[
|
|
452
|
-
[
|
|
453
|
-
[
|
|
454
|
-
[
|
|
455
|
-
[
|
|
456
|
-
[
|
|
457
|
-
[
|
|
458
|
-
[
|
|
459
|
-
[
|
|
460
|
-
[
|
|
461
|
-
[
|
|
462
|
-
[
|
|
463
|
-
[
|
|
464
|
-
[
|
|
465
|
-
[
|
|
466
|
-
[
|
|
467
|
-
[
|
|
468
|
-
[
|
|
469
|
-
[
|
|
470
|
-
[
|
|
471
|
-
[
|
|
472
|
-
[
|
|
473
|
-
[
|
|
474
|
-
[
|
|
475
|
-
[
|
|
476
|
-
[
|
|
477
|
-
[
|
|
478
|
-
[
|
|
479
|
-
[
|
|
480
|
-
[
|
|
481
|
-
[
|
|
482
|
-
[
|
|
483
|
-
[
|
|
484
|
-
[
|
|
485
|
-
[
|
|
486
|
-
[
|
|
487
|
-
[
|
|
488
|
-
[
|
|
489
|
-
[
|
|
490
|
-
[
|
|
428
|
+
[Dr]: 'No signature verification implementation could be found.',
|
|
429
|
+
[br]: 'No key generation implementation could be found.',
|
|
430
|
+
[Ur]: 'No signing implementation could be found.',
|
|
431
|
+
[Pr]: 'No key export implementation could be found.',
|
|
432
|
+
[qn]: 'Timestamp value must be in the range [-(2n ** 63n), (2n ** 63n) - 1]. `$value` given',
|
|
433
|
+
[Ba]: 'Transaction processing left an account with an outstanding borrowed reference',
|
|
434
|
+
[ma]: 'Account in use',
|
|
435
|
+
[Ca]: 'Account loaded twice',
|
|
436
|
+
[ha]: 'Attempt to debit an account but found no record of a prior credit.',
|
|
437
|
+
[$a]: "Transaction loads an address table account that doesn't exist",
|
|
438
|
+
[Da]: 'This transaction has already been processed',
|
|
439
|
+
[ba]: 'Blockhash not found',
|
|
440
|
+
[Ua]: 'Loader call chain is too deep',
|
|
441
|
+
[ka]: 'Transactions are currently disabled due to cluster maintenance',
|
|
442
|
+
[Za]: 'Transaction contains a duplicate instruction ($index) that is not allowed',
|
|
443
|
+
[va]: 'Insufficient funds for fee',
|
|
444
|
+
[Qa]: 'Transaction results in an account ($accountIndex) with insufficient funds for rent',
|
|
445
|
+
[pa]: 'This account may not be used to pay transaction fees',
|
|
446
|
+
[wa]: 'Transaction contains an invalid account reference',
|
|
447
|
+
[Ya]: 'Transaction loads an address table account with invalid data',
|
|
448
|
+
[Ka]: 'Transaction address table lookup uses an invalid index',
|
|
449
|
+
[Xa]: 'Transaction loads an address table account with an invalid owner',
|
|
450
|
+
[ti]: 'LoadedAccountsDataSizeLimit set for transaction must be greater than 0.',
|
|
451
|
+
[Ma]: 'This program may not be used for executing instructions',
|
|
452
|
+
[ja]: 'Transaction leaves an account with a lower balance than rent-exempt minimum',
|
|
453
|
+
[Fa]: 'Transaction loads a writable account that cannot be written',
|
|
454
|
+
[ei]: 'Transaction exceeded max loaded accounts data size cap',
|
|
455
|
+
[Pa]: 'Transaction requires a fee but has no signature present',
|
|
456
|
+
[La]: 'Attempt to load a program that does not exist',
|
|
457
|
+
[ri]: 'Execution of the program referenced by account at index $accountIndex is temporarily restricted.',
|
|
458
|
+
[ni]: 'ResanitizationNeeded',
|
|
459
|
+
[ya]: 'Transaction failed to sanitize accounts offsets correctly',
|
|
460
|
+
[xa]: 'Transaction did not pass signature verification',
|
|
461
|
+
[Wa]: 'Transaction locked too many accounts',
|
|
462
|
+
[oi]: 'Sum of account balances before and after transaction do not match',
|
|
463
|
+
[ga]: 'The transaction failed with the error `$errorName`',
|
|
464
|
+
[Va]: 'Transaction version is unsupported',
|
|
465
|
+
[Ha]: 'Transaction would exceed account data limit within the block',
|
|
466
|
+
[qa]: 'Transaction would exceed total account data limit',
|
|
467
|
+
[za]: 'Transaction would exceed max account limit within the block',
|
|
468
|
+
[Ga]: 'Transaction would exceed max Block Cost Limit',
|
|
469
|
+
[Ja]: 'Transaction would exceed max Vote Cost Limit',
|
|
470
|
+
[Ea]: 'Attempted to sign a transaction with an address that is not a signer for it',
|
|
471
|
+
[ua]: 'Transaction is missing an address at index: $index.',
|
|
472
|
+
[Na]: 'Transaction has no expected signers therefore it cannot be encoded',
|
|
473
|
+
[Ia]: 'Transaction size $transactionSize exceeds limit of $transactionSizeLimit bytes',
|
|
474
|
+
[ra]: 'Transaction does not have a blockhash lifetime',
|
|
475
|
+
[oa]: 'Transaction is not a durable nonce transaction',
|
|
476
|
+
[ia]: 'Contents of these address lookup tables unknown: $lookupTableAddresses',
|
|
477
|
+
[sa]: 'Lookup of address at index $highestRequestedIndex failed for lookup table `$lookupTableAddress`. Highest known index is $highestKnownIndex. The lookup table may have been extended since its contents were retrieved',
|
|
478
|
+
[ca]: 'No fee payer set in CompiledTransaction',
|
|
479
|
+
[_a]: 'Could not find program address at index $index',
|
|
480
|
+
[Sa]: 'Failed to estimate the compute unit consumption for this transaction message. This is likely because simulating the transaction failed. Inspect the `cause` property of this error to learn more',
|
|
481
|
+
[fa]: 'Transaction failed when it was simulated in order to estimate the compute unit consumption. The compute unit estimate provided is for a transaction that failed when simulated and may not be representative of the compute units this transaction would consume if successful. Inspect the `cause` property of this error to learn more',
|
|
482
|
+
[Aa]: 'Transaction is missing a fee payer.',
|
|
483
|
+
[da]: "Could not determine this transaction's signature. Make sure that the transaction has been signed by its fee payer.",
|
|
484
|
+
[la]: 'Transaction first instruction is not advance nonce account instruction.',
|
|
485
|
+
[Oa]: 'Transaction with no instructions cannot be durable nonce transaction.',
|
|
486
|
+
[ta]: 'This transaction includes an address (`$programAddress`) which is both invoked and set as the fee payer. Program addresses may not pay fees',
|
|
487
|
+
[na]: 'This transaction includes an address (`$programAddress`) which is both invoked and marked writable. Program addresses may not be writable',
|
|
488
|
+
[Ta]: 'The transaction message expected the transaction to have $signerAddressesLength signatures, got $signaturesLength.',
|
|
489
|
+
[Ra]: 'Transaction is missing signatures for addresses: $addresses.',
|
|
490
|
+
[aa]: 'Transaction version must be in the range [0, 127]. `$actualVersion` given',
|
|
491
491
|
},
|
|
492
|
-
|
|
492
|
+
z = 'i',
|
|
493
493
|
k = 't';
|
|
494
|
-
function
|
|
495
|
-
const n =
|
|
494
|
+
function bi(e, t = {}) {
|
|
495
|
+
const n = Di[e];
|
|
496
496
|
if (n.length === 0) return '';
|
|
497
497
|
let o;
|
|
498
|
-
function r(
|
|
498
|
+
function r(i) {
|
|
499
499
|
if (o[k] === 2) {
|
|
500
|
-
const s = n.slice(o[
|
|
501
|
-
|
|
500
|
+
const s = n.slice(o[z] + 1, i);
|
|
501
|
+
a.push(
|
|
502
502
|
s in t
|
|
503
503
|
? // eslint-disable-next-line @typescript-eslint/restrict-template-expressions
|
|
504
504
|
`${t[s]}`
|
|
505
505
|
: `$${s}`
|
|
506
506
|
);
|
|
507
|
-
} else o[k] === 1 &&
|
|
507
|
+
} else o[k] === 1 && a.push(n.slice(o[z], i));
|
|
508
508
|
}
|
|
509
|
-
const
|
|
509
|
+
const a = [];
|
|
510
510
|
return (
|
|
511
|
-
n.split('').forEach((
|
|
511
|
+
n.split('').forEach((i, s) => {
|
|
512
512
|
if (s === 0) {
|
|
513
513
|
o = {
|
|
514
|
-
[
|
|
514
|
+
[z]: 0,
|
|
515
515
|
[k]: n[0] === '\\' ? 0 : n[0] === '$' ? 2 : 1,
|
|
516
516
|
/* Text */
|
|
517
517
|
};
|
|
@@ -521,41 +521,41 @@ function wi(e, t = {}) {
|
|
|
521
521
|
switch (o[k]) {
|
|
522
522
|
case 0:
|
|
523
523
|
_ = {
|
|
524
|
-
[
|
|
524
|
+
[z]: s,
|
|
525
525
|
[k]: 1,
|
|
526
526
|
/* Text */
|
|
527
527
|
};
|
|
528
528
|
break;
|
|
529
529
|
case 1:
|
|
530
|
-
|
|
530
|
+
i === '\\'
|
|
531
531
|
? (_ = {
|
|
532
|
-
[
|
|
532
|
+
[z]: s,
|
|
533
533
|
[k]: 0,
|
|
534
534
|
/* EscapeSequence */
|
|
535
535
|
})
|
|
536
|
-
:
|
|
536
|
+
: i === '$' &&
|
|
537
537
|
(_ = {
|
|
538
|
-
[
|
|
538
|
+
[z]: s,
|
|
539
539
|
[k]: 2,
|
|
540
540
|
/* Variable */
|
|
541
541
|
});
|
|
542
542
|
break;
|
|
543
543
|
case 2:
|
|
544
|
-
|
|
544
|
+
i === '\\'
|
|
545
545
|
? (_ = {
|
|
546
|
-
[
|
|
546
|
+
[z]: s,
|
|
547
547
|
[k]: 0,
|
|
548
548
|
/* EscapeSequence */
|
|
549
549
|
})
|
|
550
|
-
:
|
|
550
|
+
: i === '$'
|
|
551
551
|
? (_ = {
|
|
552
|
-
[
|
|
552
|
+
[z]: s,
|
|
553
553
|
[k]: 2,
|
|
554
554
|
/* Variable */
|
|
555
555
|
})
|
|
556
|
-
:
|
|
556
|
+
: i.match(/\w/) ||
|
|
557
557
|
(_ = {
|
|
558
|
-
[
|
|
558
|
+
[z]: s,
|
|
559
559
|
[k]: 1,
|
|
560
560
|
/* Text */
|
|
561
561
|
});
|
|
@@ -564,17 +564,17 @@ function wi(e, t = {}) {
|
|
|
564
564
|
_ && (o !== _ && r(s), (o = _));
|
|
565
565
|
}),
|
|
566
566
|
r(),
|
|
567
|
-
|
|
567
|
+
a.join('')
|
|
568
568
|
);
|
|
569
569
|
}
|
|
570
|
-
function
|
|
571
|
-
if (process.env.NODE_ENV !== 'production') return
|
|
570
|
+
function Ui(e, t = {}) {
|
|
571
|
+
if (process.env.NODE_ENV !== 'production') return bi(e, t);
|
|
572
572
|
{
|
|
573
573
|
let n = `Solana error #${e}; Decode this error by running \`npx @solana/errors decode -- ${e}`;
|
|
574
|
-
return (Object.keys(t).length && (n += ` '${
|
|
574
|
+
return (Object.keys(t).length && (n += ` '${pi(t)}'`), `${n}\``);
|
|
575
575
|
}
|
|
576
576
|
}
|
|
577
|
-
function
|
|
577
|
+
function gt(e, t) {
|
|
578
578
|
return e instanceof Error && e.name === 'SolanaError'
|
|
579
579
|
? t !== void 0
|
|
580
580
|
? e.context.__code === t
|
|
@@ -585,22 +585,22 @@ var T = class extends Error {
|
|
|
585
585
|
constructor(...[t, n]) {
|
|
586
586
|
let o, r;
|
|
587
587
|
if (n) {
|
|
588
|
-
const { cause:
|
|
589
|
-
(
|
|
588
|
+
const { cause: i, ...s } = n;
|
|
589
|
+
(i && (r = { cause: i }), Object.keys(s).length > 0 && (o = s));
|
|
590
590
|
}
|
|
591
|
-
const
|
|
592
|
-
super(
|
|
591
|
+
const a = Ui(t, o);
|
|
592
|
+
super(a, r);
|
|
593
593
|
/**
|
|
594
594
|
* Indicates the root cause of this {@link SolanaError}, if any.
|
|
595
595
|
*
|
|
596
596
|
* For example, a transaction error might have an instruction error as its root cause. In this
|
|
597
597
|
* case, you will be able to access the instruction error on the transaction error as `cause`.
|
|
598
598
|
*/
|
|
599
|
-
|
|
599
|
+
g(this, 'cause', this.cause);
|
|
600
600
|
/**
|
|
601
601
|
* Contains context that can assist in understanding or recovering from a {@link SolanaError}.
|
|
602
602
|
*/
|
|
603
|
-
|
|
603
|
+
g(this, 'context');
|
|
604
604
|
((this.context = {
|
|
605
605
|
__code: t,
|
|
606
606
|
...o,
|
|
@@ -608,15 +608,15 @@ var T = class extends Error {
|
|
|
608
608
|
(this.name = 'SolanaError'));
|
|
609
609
|
}
|
|
610
610
|
},
|
|
611
|
-
|
|
611
|
+
Pi = (e, t) => {
|
|
612
612
|
if (e.length >= t) return e;
|
|
613
613
|
const n = new Uint8Array(t).fill(0);
|
|
614
614
|
return (n.set(e), n);
|
|
615
615
|
},
|
|
616
|
-
|
|
617
|
-
function
|
|
616
|
+
wi = (e, t) => Pi(e.length <= t ? e : e.slice(0, t), t);
|
|
617
|
+
function H(e, t, n) {
|
|
618
618
|
const o = n === 0 && e.length === t.length ? e : e.slice(n, n + t.length);
|
|
619
|
-
return o.length !== t.length ? !1 : t.every((r,
|
|
619
|
+
return o.length !== t.length ? !1 : t.every((r, a) => r === o[a]);
|
|
620
620
|
}
|
|
621
621
|
function ee(e, t) {
|
|
622
622
|
return 'fixedSize' in t ? t.fixedSize : t.getSizeFromValue(e);
|
|
@@ -630,29 +630,29 @@ function w(e) {
|
|
|
630
630
|
},
|
|
631
631
|
});
|
|
632
632
|
}
|
|
633
|
-
function
|
|
633
|
+
function x(e) {
|
|
634
634
|
return Object.freeze({
|
|
635
635
|
...e,
|
|
636
636
|
decode: (t, n = 0) => e.read(t, n)[0],
|
|
637
637
|
});
|
|
638
638
|
}
|
|
639
|
-
function
|
|
639
|
+
function P(e) {
|
|
640
640
|
return 'fixedSize' in e && typeof e.fixedSize == 'number';
|
|
641
641
|
}
|
|
642
|
-
function
|
|
643
|
-
if (!
|
|
642
|
+
function mt(e) {
|
|
643
|
+
if (!P(e)) throw new T(Rt);
|
|
644
644
|
}
|
|
645
|
-
function
|
|
646
|
-
return !
|
|
645
|
+
function xi(e) {
|
|
646
|
+
return !P(e);
|
|
647
647
|
}
|
|
648
648
|
function S(e, t) {
|
|
649
|
-
if (
|
|
650
|
-
if (
|
|
649
|
+
if (P(e) !== P(t)) throw new T(ut);
|
|
650
|
+
if (P(e) && P(t) && e.fixedSize !== t.fixedSize)
|
|
651
651
|
throw new T(At, {
|
|
652
652
|
decoderFixedSize: t.fixedSize,
|
|
653
653
|
encoderFixedSize: e.fixedSize,
|
|
654
654
|
});
|
|
655
|
-
if (!
|
|
655
|
+
if (!P(e) && !P(t) && e.maxSize !== t.maxSize)
|
|
656
656
|
throw new T(dt, {
|
|
657
657
|
decoderMaxSize: t.maxSize,
|
|
658
658
|
encoderMaxSize: e.maxSize,
|
|
@@ -666,7 +666,7 @@ function S(e, t) {
|
|
|
666
666
|
write: e.write,
|
|
667
667
|
};
|
|
668
668
|
}
|
|
669
|
-
function
|
|
669
|
+
function Mi(e, t, n = 0) {
|
|
670
670
|
if (t.length - n <= 0)
|
|
671
671
|
throw new T(_t, {
|
|
672
672
|
codecDescription: e,
|
|
@@ -681,23 +681,23 @@ function Ct(e, t, n, o = 0) {
|
|
|
681
681
|
expected: t,
|
|
682
682
|
});
|
|
683
683
|
}
|
|
684
|
-
function
|
|
684
|
+
function m(e, t) {
|
|
685
685
|
return w({
|
|
686
686
|
fixedSize: t,
|
|
687
687
|
write: (n, o, r) => {
|
|
688
|
-
const
|
|
689
|
-
|
|
690
|
-
return (o.set(
|
|
688
|
+
const a = e.encode(n),
|
|
689
|
+
i = a.length > t ? a.slice(0, t) : a;
|
|
690
|
+
return (o.set(i, r), r + t);
|
|
691
691
|
},
|
|
692
692
|
});
|
|
693
693
|
}
|
|
694
694
|
function C(e, t) {
|
|
695
|
-
return
|
|
695
|
+
return x({
|
|
696
696
|
fixedSize: t,
|
|
697
697
|
read: (n, o) => {
|
|
698
698
|
(Ct('fixCodecSize', t, n, o),
|
|
699
699
|
(o > 0 || n.length > t) && (n = n.slice(o, o + t)),
|
|
700
|
-
|
|
700
|
+
P(e) && (n = wi(n, e.fixedSize)));
|
|
701
701
|
const [r] = e.read(n, 0);
|
|
702
702
|
return [r, o + t];
|
|
703
703
|
},
|
|
@@ -705,28 +705,28 @@ function C(e, t) {
|
|
|
705
705
|
}
|
|
706
706
|
function b(e, t) {
|
|
707
707
|
return w({
|
|
708
|
-
...(
|
|
708
|
+
...(xi(e) ? { ...e, getSizeFromValue: (n) => e.getSizeFromValue(t(n)) } : e),
|
|
709
709
|
write: (n, o, r) => e.write(t(n), o, r),
|
|
710
710
|
});
|
|
711
711
|
}
|
|
712
712
|
function Q(e, t) {
|
|
713
|
-
return
|
|
713
|
+
return x({
|
|
714
714
|
...e,
|
|
715
715
|
read: (n, o) => {
|
|
716
|
-
const [r,
|
|
717
|
-
return [t(r, n, o),
|
|
716
|
+
const [r, a] = e.read(n, o);
|
|
717
|
+
return [t(r, n, o), a];
|
|
718
718
|
},
|
|
719
719
|
});
|
|
720
720
|
}
|
|
721
|
-
function
|
|
721
|
+
function yi(e, t, n = t) {
|
|
722
722
|
if (!t.match(new RegExp(`^[${e}]*$`)))
|
|
723
|
-
throw new T(
|
|
723
|
+
throw new T(Re, {
|
|
724
724
|
alphabet: e,
|
|
725
725
|
base: e.length,
|
|
726
726
|
value: n,
|
|
727
727
|
});
|
|
728
728
|
}
|
|
729
|
-
var
|
|
729
|
+
var ki = (e) =>
|
|
730
730
|
w({
|
|
731
731
|
getSizeFromValue: (t) => {
|
|
732
732
|
const [n, o] = Ge(t, e[0]);
|
|
@@ -735,28 +735,28 @@ var Vi = (e) =>
|
|
|
735
735
|
return n.length + Math.ceil(r.toString(16).length / 2);
|
|
736
736
|
},
|
|
737
737
|
write(t, n, o) {
|
|
738
|
-
if ((
|
|
739
|
-
const [r,
|
|
740
|
-
if (!
|
|
741
|
-
let
|
|
738
|
+
if ((yi(e, t), t === '')) return o;
|
|
739
|
+
const [r, a] = Ge(t, e[0]);
|
|
740
|
+
if (!a) return (n.set(new Uint8Array(r.length).fill(0), o), o + r.length);
|
|
741
|
+
let i = Ve(a, e);
|
|
742
742
|
const s = [];
|
|
743
|
-
for (;
|
|
743
|
+
for (; i > 0n; ) (s.unshift(Number(i % 256n)), (i /= 256n));
|
|
744
744
|
const _ = [...Array(r.length).fill(0), ...s];
|
|
745
745
|
return (n.set(_, o), o + _.length);
|
|
746
746
|
},
|
|
747
747
|
}),
|
|
748
|
-
|
|
749
|
-
|
|
748
|
+
Bi = (e) =>
|
|
749
|
+
x({
|
|
750
750
|
read(t, n) {
|
|
751
751
|
const o = n === 0 ? t : t.slice(n);
|
|
752
752
|
if (o.length === 0) return ['', 0];
|
|
753
753
|
let r = o.findIndex((_) => _ !== 0);
|
|
754
754
|
r = r === -1 ? o.length : r;
|
|
755
|
-
const
|
|
756
|
-
if (r === o.length) return [
|
|
757
|
-
const
|
|
758
|
-
s =
|
|
759
|
-
return [
|
|
755
|
+
const a = e[0].repeat(r);
|
|
756
|
+
if (r === o.length) return [a, t.length];
|
|
757
|
+
const i = o.slice(r).reduce((_, N) => _ * 256n + BigInt(N), 0n),
|
|
758
|
+
s = Gi(i, e);
|
|
759
|
+
return [a + s, t.length];
|
|
760
760
|
},
|
|
761
761
|
});
|
|
762
762
|
function Ge(e, t) {
|
|
@@ -769,23 +769,23 @@ function Ve(e, t) {
|
|
|
769
769
|
for (const r of e) ((o *= n), (o += BigInt(t.indexOf(r))));
|
|
770
770
|
return o;
|
|
771
771
|
}
|
|
772
|
-
function
|
|
772
|
+
function Gi(e, t) {
|
|
773
773
|
const n = BigInt(t.length),
|
|
774
774
|
o = [];
|
|
775
775
|
for (; e > 0n; ) (o.unshift(t[Number(e % n)]), (e /= n));
|
|
776
776
|
return o.join('');
|
|
777
777
|
}
|
|
778
778
|
var ht = '123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz',
|
|
779
|
-
|
|
780
|
-
|
|
779
|
+
Vi = () => ki(ht),
|
|
780
|
+
Fi = () => Bi(ht),
|
|
781
781
|
Fe = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/',
|
|
782
|
-
|
|
782
|
+
zi = () =>
|
|
783
783
|
w({
|
|
784
784
|
getSizeFromValue: (e) => {
|
|
785
785
|
try {
|
|
786
786
|
return atob(e).length;
|
|
787
787
|
} catch {
|
|
788
|
-
throw new T(
|
|
788
|
+
throw new T(Re, {
|
|
789
789
|
alphabet: Fe,
|
|
790
790
|
base: 64,
|
|
791
791
|
value: e,
|
|
@@ -799,7 +799,7 @@ var ht = '123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz',
|
|
|
799
799
|
.map((r) => r.charCodeAt(0));
|
|
800
800
|
return (t.set(o, n), o.length + n);
|
|
801
801
|
} catch {
|
|
802
|
-
throw new T(
|
|
802
|
+
throw new T(Re, {
|
|
803
803
|
alphabet: Fe,
|
|
804
804
|
base: 64,
|
|
805
805
|
value: e,
|
|
@@ -807,7 +807,7 @@ var ht = '123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz',
|
|
|
807
807
|
}
|
|
808
808
|
},
|
|
809
809
|
});
|
|
810
|
-
function
|
|
810
|
+
function Lt(e, t) {
|
|
811
811
|
try {
|
|
812
812
|
return 'exists' in e && !e.exists ? e : Object.freeze({ ...e, data: t.decode(e.data) });
|
|
813
813
|
} catch {
|
|
@@ -816,12 +816,12 @@ function vt(e, t) {
|
|
|
816
816
|
});
|
|
817
817
|
}
|
|
818
818
|
}
|
|
819
|
-
function
|
|
819
|
+
function vt(e, t) {
|
|
820
820
|
if (!t) return Object.freeze({ address: e, exists: !1 });
|
|
821
|
-
const n =
|
|
822
|
-
return Object.freeze({ ...
|
|
821
|
+
const n = zi().encode(t.data[0]);
|
|
822
|
+
return Object.freeze({ ...Hi(t), address: e, data: n, exists: !0 });
|
|
823
823
|
}
|
|
824
|
-
function
|
|
824
|
+
function Hi(e) {
|
|
825
825
|
return Object.freeze({
|
|
826
826
|
executable: e.executable,
|
|
827
827
|
lamports: e.lamports,
|
|
@@ -831,45 +831,45 @@ function Xi(e) {
|
|
|
831
831
|
}
|
|
832
832
|
async function pt(e, t, n = {}) {
|
|
833
833
|
const { abortSignal: o, ...r } = n,
|
|
834
|
-
|
|
835
|
-
return
|
|
834
|
+
a = await e.getAccountInfo(t, { ...r, encoding: 'base64' }).send({ abortSignal: o });
|
|
835
|
+
return vt(t, a.value);
|
|
836
836
|
}
|
|
837
837
|
async function Dt(e, t, n = {}) {
|
|
838
838
|
const { abortSignal: o, ...r } = n;
|
|
839
839
|
return (
|
|
840
840
|
await e.getMultipleAccounts(t, { ...r, encoding: 'base64' }).send({ abortSignal: o })
|
|
841
|
-
).value.map((
|
|
841
|
+
).value.map((i, s) => vt(t[s], i));
|
|
842
842
|
}
|
|
843
843
|
function bt(e) {
|
|
844
844
|
if (!e.exists) throw new T(tt, { address: e.address });
|
|
845
845
|
}
|
|
846
|
-
function
|
|
846
|
+
function Ut(e) {
|
|
847
847
|
const t = e.filter((n) => !n.exists);
|
|
848
848
|
if (t.length > 0) {
|
|
849
849
|
const n = t.map((o) => o.address);
|
|
850
850
|
throw new T(nt, { addresses: n });
|
|
851
851
|
}
|
|
852
852
|
}
|
|
853
|
-
function
|
|
853
|
+
function Wi() {
|
|
854
854
|
if (!globalThis.isSecureContext) throw new T(ot);
|
|
855
855
|
}
|
|
856
|
-
function
|
|
856
|
+
function $i() {
|
|
857
857
|
var e;
|
|
858
858
|
if (
|
|
859
|
-
(
|
|
859
|
+
(Wi(),
|
|
860
860
|
typeof globalThis.crypto > 'u' ||
|
|
861
861
|
typeof ((e = globalThis.crypto.subtle) == null ? void 0 : e.digest) != 'function')
|
|
862
862
|
)
|
|
863
863
|
throw new T(at);
|
|
864
864
|
}
|
|
865
|
-
var
|
|
866
|
-
function
|
|
867
|
-
return (
|
|
865
|
+
var le, Ee;
|
|
866
|
+
function Pt() {
|
|
867
|
+
return (le || (le = Vi()), le);
|
|
868
868
|
}
|
|
869
|
-
function
|
|
870
|
-
return (Ee || (Ee =
|
|
869
|
+
function Xi() {
|
|
870
|
+
return (Ee || (Ee = Fi()), Ee);
|
|
871
871
|
}
|
|
872
|
-
function
|
|
872
|
+
function Yi(e) {
|
|
873
873
|
if (
|
|
874
874
|
// Lowest address (32 bytes of zeroes)
|
|
875
875
|
e.length < 32 || // Highest address (32 bytes of 255)
|
|
@@ -878,122 +878,122 @@ function Ji(e) {
|
|
|
878
878
|
throw new T(qe, {
|
|
879
879
|
actualLength: e.length,
|
|
880
880
|
});
|
|
881
|
-
const o =
|
|
881
|
+
const o = Pt().encode(e).byteLength;
|
|
882
882
|
if (o !== 32)
|
|
883
883
|
throw new T(Je, {
|
|
884
884
|
actualLength: o,
|
|
885
885
|
});
|
|
886
886
|
}
|
|
887
|
-
function
|
|
888
|
-
return (
|
|
887
|
+
function Ki(e) {
|
|
888
|
+
return (Yi(e), e);
|
|
889
889
|
}
|
|
890
890
|
function c() {
|
|
891
|
-
return b(
|
|
891
|
+
return b(m(Pt(), 32), (e) => Ki(e));
|
|
892
892
|
}
|
|
893
|
-
function
|
|
894
|
-
return C(
|
|
893
|
+
function R() {
|
|
894
|
+
return C(Xi(), 32);
|
|
895
895
|
}
|
|
896
896
|
function pe() {
|
|
897
|
-
return S(c(),
|
|
897
|
+
return S(c(), R());
|
|
898
898
|
}
|
|
899
|
-
var
|
|
900
|
-
|
|
899
|
+
var ji = 37095705934669439343138083508754565189542113879843219016388785533085940283555n,
|
|
900
|
+
v = 57896044618658097711785492504343953926634992332820282019728792003956564819949n,
|
|
901
901
|
ze = 19681161376707505956807079304988542015446066515923890162744021073123829784752n;
|
|
902
|
-
function
|
|
903
|
-
const t = e %
|
|
904
|
-
return t >= 0n ? t :
|
|
902
|
+
function M(e) {
|
|
903
|
+
const t = e % v;
|
|
904
|
+
return t >= 0n ? t : v + t;
|
|
905
905
|
}
|
|
906
906
|
function B(e, t) {
|
|
907
907
|
let n = e;
|
|
908
|
-
for (; t-- > 0n; ) ((n *= n), (n %=
|
|
908
|
+
for (; t-- > 0n; ) ((n *= n), (n %= v));
|
|
909
909
|
return n;
|
|
910
910
|
}
|
|
911
|
-
function
|
|
912
|
-
const n = (((e * e) %
|
|
913
|
-
o = (B(n, 2n) * n) %
|
|
914
|
-
r = (B(o, 1n) * e) %
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
s = (B(
|
|
918
|
-
_ = (B(s, 40n) * s) %
|
|
919
|
-
N = (B(_, 80n) * _) %
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
return (B(
|
|
923
|
-
}
|
|
924
|
-
function
|
|
925
|
-
const n =
|
|
926
|
-
o =
|
|
927
|
-
r =
|
|
928
|
-
let
|
|
929
|
-
const
|
|
930
|
-
s =
|
|
931
|
-
_ =
|
|
932
|
-
N =
|
|
933
|
-
|
|
934
|
-
|
|
911
|
+
function Ji(e) {
|
|
912
|
+
const n = (((e * e) % v) * e) % v,
|
|
913
|
+
o = (B(n, 2n) * n) % v,
|
|
914
|
+
r = (B(o, 1n) * e) % v,
|
|
915
|
+
a = (B(r, 5n) * r) % v,
|
|
916
|
+
i = (B(a, 10n) * a) % v,
|
|
917
|
+
s = (B(i, 20n) * i) % v,
|
|
918
|
+
_ = (B(s, 40n) * s) % v,
|
|
919
|
+
N = (B(_, 80n) * _) % v,
|
|
920
|
+
f = (B(N, 80n) * _) % v,
|
|
921
|
+
d = (B(f, 10n) * a) % v;
|
|
922
|
+
return (B(d, 2n) * e) % v;
|
|
923
|
+
}
|
|
924
|
+
function qi(e, t) {
|
|
925
|
+
const n = M(t * t * t),
|
|
926
|
+
o = M(n * n * t),
|
|
927
|
+
r = Ji(e * o);
|
|
928
|
+
let a = M(e * n * r);
|
|
929
|
+
const i = M(t * a * a),
|
|
930
|
+
s = a,
|
|
931
|
+
_ = M(a * ze),
|
|
932
|
+
N = i === e,
|
|
933
|
+
f = i === M(-e),
|
|
934
|
+
d = i === M(-e * ze);
|
|
935
935
|
return (
|
|
936
|
-
N && (
|
|
937
|
-
(
|
|
938
|
-
(
|
|
939
|
-
!N && !
|
|
936
|
+
N && (a = s),
|
|
937
|
+
(f || d) && (a = _),
|
|
938
|
+
(M(a) & 1n) === 1n && (a = M(-a)),
|
|
939
|
+
!N && !f ? null : a
|
|
940
940
|
);
|
|
941
941
|
}
|
|
942
|
-
function
|
|
943
|
-
const n =
|
|
944
|
-
o =
|
|
945
|
-
r =
|
|
946
|
-
|
|
947
|
-
if (
|
|
948
|
-
const
|
|
949
|
-
return !(
|
|
942
|
+
function Zi(e, t) {
|
|
943
|
+
const n = M(e * e),
|
|
944
|
+
o = M(n - 1n),
|
|
945
|
+
r = M(ji * n + 1n),
|
|
946
|
+
a = qi(o, r);
|
|
947
|
+
if (a === null) return !1;
|
|
948
|
+
const i = (t & 128) !== 0;
|
|
949
|
+
return !(a === 0n && i);
|
|
950
950
|
}
|
|
951
|
-
function
|
|
951
|
+
function Qi(e) {
|
|
952
952
|
const t = e.toString(16);
|
|
953
953
|
return t.length === 1 ? `0${t}` : t;
|
|
954
954
|
}
|
|
955
|
-
function
|
|
956
|
-
const n = `0x${e.reduce((o, r,
|
|
955
|
+
function es(e) {
|
|
956
|
+
const n = `0x${e.reduce((o, r, a) => `${Qi(a === 31 ? r & -129 : r)}${o}`, '')}`;
|
|
957
957
|
return BigInt(n);
|
|
958
958
|
}
|
|
959
959
|
function wt(e) {
|
|
960
960
|
if (e.byteLength !== 32) return !1;
|
|
961
|
-
const t =
|
|
962
|
-
return
|
|
961
|
+
const t = es(e);
|
|
962
|
+
return Zi(t, e[31]);
|
|
963
963
|
}
|
|
964
|
-
function
|
|
964
|
+
function ts(e) {
|
|
965
965
|
const t = pe().encode(e);
|
|
966
966
|
return wt(t) === !1;
|
|
967
967
|
}
|
|
968
968
|
var He = 32,
|
|
969
969
|
We = 16,
|
|
970
|
-
|
|
970
|
+
ns = [
|
|
971
971
|
// The string 'ProgramDerivedAddress'
|
|
972
972
|
80, 114, 111, 103, 114, 97, 109, 68, 101, 114, 105, 118, 101, 100, 65, 100, 100, 114, 101, 115,
|
|
973
973
|
115,
|
|
974
974
|
];
|
|
975
|
-
async function
|
|
976
|
-
if ((
|
|
975
|
+
async function rs({ programAddress: e, seeds: t }) {
|
|
976
|
+
if (($i(), t.length > We))
|
|
977
977
|
throw new T(Ze, {
|
|
978
978
|
actual: t.length,
|
|
979
979
|
maxSeeds: We,
|
|
980
980
|
});
|
|
981
981
|
let n;
|
|
982
|
-
const o = t.reduce((_, N,
|
|
983
|
-
const
|
|
984
|
-
if (
|
|
982
|
+
const o = t.reduce((_, N, f) => {
|
|
983
|
+
const d = typeof N == 'string' ? (n || (n = new TextEncoder())).encode(N) : N;
|
|
984
|
+
if (d.byteLength > He)
|
|
985
985
|
throw new T(Qe, {
|
|
986
|
-
actual:
|
|
987
|
-
index:
|
|
986
|
+
actual: d.byteLength,
|
|
987
|
+
index: f,
|
|
988
988
|
maxSeedLength: He,
|
|
989
989
|
});
|
|
990
|
-
return (_.push(...
|
|
990
|
+
return (_.push(...d), _);
|
|
991
991
|
}, []),
|
|
992
992
|
r = pe(),
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
s = new Uint8Array(
|
|
996
|
-
if (wt(s)) throw new T(
|
|
993
|
+
a = r.encode(e),
|
|
994
|
+
i = await crypto.subtle.digest('SHA-256', new Uint8Array([...o, ...a, ...ns])),
|
|
995
|
+
s = new Uint8Array(i);
|
|
996
|
+
if (wt(s)) throw new T(Le);
|
|
997
997
|
return r.decode(s);
|
|
998
998
|
}
|
|
999
999
|
async function De({ programAddress: e, seeds: t }) {
|
|
@@ -1001,19 +1001,19 @@ async function De({ programAddress: e, seeds: t }) {
|
|
|
1001
1001
|
for (; n > 0; )
|
|
1002
1002
|
try {
|
|
1003
1003
|
return [
|
|
1004
|
-
await
|
|
1004
|
+
await rs({
|
|
1005
1005
|
programAddress: e,
|
|
1006
1006
|
seeds: [...t, new Uint8Array([n])],
|
|
1007
1007
|
}),
|
|
1008
1008
|
n,
|
|
1009
1009
|
];
|
|
1010
1010
|
} catch (o) {
|
|
1011
|
-
if (
|
|
1011
|
+
if (gt(o, Le)) n--;
|
|
1012
1012
|
else throw o;
|
|
1013
1013
|
}
|
|
1014
1014
|
throw new T(et);
|
|
1015
1015
|
}
|
|
1016
|
-
function
|
|
1016
|
+
function os(e, t, n, o) {
|
|
1017
1017
|
if (o < t || o > n)
|
|
1018
1018
|
throw new T(Tt, {
|
|
1019
1019
|
codecDescription: e,
|
|
@@ -1022,36 +1022,36 @@ function ss(e, t, n, o) {
|
|
|
1022
1022
|
value: o,
|
|
1023
1023
|
});
|
|
1024
1024
|
}
|
|
1025
|
-
function
|
|
1025
|
+
function xt(e) {
|
|
1026
1026
|
return (e == null ? void 0 : e.endian) !== 1;
|
|
1027
1027
|
}
|
|
1028
|
-
function
|
|
1028
|
+
function j(e) {
|
|
1029
1029
|
return w({
|
|
1030
1030
|
fixedSize: e.size,
|
|
1031
1031
|
write(t, n, o) {
|
|
1032
|
-
e.range &&
|
|
1032
|
+
e.range && os(e.name, e.range[0], e.range[1], t);
|
|
1033
1033
|
const r = new ArrayBuffer(e.size);
|
|
1034
|
-
return (e.set(new DataView(r), t,
|
|
1034
|
+
return (e.set(new DataView(r), t, xt(e.config)), n.set(new Uint8Array(r), o), o + e.size);
|
|
1035
1035
|
},
|
|
1036
1036
|
});
|
|
1037
1037
|
}
|
|
1038
|
-
function
|
|
1039
|
-
return
|
|
1038
|
+
function J(e) {
|
|
1039
|
+
return x({
|
|
1040
1040
|
fixedSize: e.size,
|
|
1041
1041
|
read(t, n = 0) {
|
|
1042
|
-
(
|
|
1043
|
-
const o = new DataView(
|
|
1044
|
-
return [e.get(o,
|
|
1042
|
+
(Mi(e.name, t, n), Ct(e.name, e.size, t, n));
|
|
1043
|
+
const o = new DataView(as(t, n, e.size));
|
|
1044
|
+
return [e.get(o, xt(e.config)), n + e.size];
|
|
1045
1045
|
},
|
|
1046
1046
|
});
|
|
1047
1047
|
}
|
|
1048
|
-
function
|
|
1048
|
+
function as(e, t, n) {
|
|
1049
1049
|
const o = e.byteOffset + (t ?? 0),
|
|
1050
1050
|
r = n ?? e.byteLength;
|
|
1051
1051
|
return e.buffer.slice(o, o + r);
|
|
1052
1052
|
}
|
|
1053
1053
|
var fe = (e = {}) =>
|
|
1054
|
-
|
|
1054
|
+
j({
|
|
1055
1055
|
config: e,
|
|
1056
1056
|
name: 'i32',
|
|
1057
1057
|
range: [-+'0x7fffffff' - 1, +'0x7fffffff'],
|
|
@@ -1059,55 +1059,55 @@ var fe = (e = {}) =>
|
|
|
1059
1059
|
size: 4,
|
|
1060
1060
|
}),
|
|
1061
1061
|
Ie = (e = {}) =>
|
|
1062
|
-
|
|
1062
|
+
J({
|
|
1063
1063
|
config: e,
|
|
1064
1064
|
get: (t, n) => t.getInt32(0, n),
|
|
1065
1065
|
name: 'i32',
|
|
1066
1066
|
size: 4,
|
|
1067
1067
|
}),
|
|
1068
|
-
|
|
1069
|
-
|
|
1068
|
+
is = (e = {}) =>
|
|
1069
|
+
j({
|
|
1070
1070
|
config: e,
|
|
1071
1071
|
name: 'i64',
|
|
1072
1072
|
range: [-BigInt('0x7fffffffffffffff') - 1n, BigInt('0x7fffffffffffffff')],
|
|
1073
1073
|
set: (t, n, o) => t.setBigInt64(0, BigInt(n), o),
|
|
1074
1074
|
size: 8,
|
|
1075
1075
|
}),
|
|
1076
|
-
|
|
1077
|
-
|
|
1076
|
+
ss = (e = {}) =>
|
|
1077
|
+
J({
|
|
1078
1078
|
config: e,
|
|
1079
1079
|
get: (t, n) => t.getBigInt64(0, n),
|
|
1080
1080
|
name: 'i64',
|
|
1081
1081
|
size: 8,
|
|
1082
1082
|
}),
|
|
1083
|
-
|
|
1084
|
-
|
|
1083
|
+
p = (e = {}) =>
|
|
1084
|
+
j({
|
|
1085
1085
|
config: e,
|
|
1086
1086
|
name: 'u128',
|
|
1087
1087
|
range: [0n, BigInt('0xffffffffffffffffffffffffffffffff')],
|
|
1088
1088
|
set: (t, n, o) => {
|
|
1089
1089
|
const r = o ? 8 : 0,
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
(t.setBigUint64(r, BigInt(n) >> 64n, o), t.setBigUint64(
|
|
1090
|
+
a = o ? 0 : 8,
|
|
1091
|
+
i = 0xffffffffffffffffn;
|
|
1092
|
+
(t.setBigUint64(r, BigInt(n) >> 64n, o), t.setBigUint64(a, BigInt(n) & i, o));
|
|
1093
1093
|
},
|
|
1094
1094
|
size: 16,
|
|
1095
1095
|
}),
|
|
1096
|
-
|
|
1097
|
-
|
|
1096
|
+
D = (e = {}) =>
|
|
1097
|
+
J({
|
|
1098
1098
|
config: e,
|
|
1099
1099
|
get: (t, n) => {
|
|
1100
1100
|
const o = n ? 8 : 0,
|
|
1101
1101
|
r = n ? 0 : 8,
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
return (
|
|
1102
|
+
a = t.getBigUint64(o, n),
|
|
1103
|
+
i = t.getBigUint64(r, n);
|
|
1104
|
+
return (a << 64n) + i;
|
|
1105
1105
|
},
|
|
1106
1106
|
name: 'u128',
|
|
1107
1107
|
size: 16,
|
|
1108
1108
|
}),
|
|
1109
1109
|
Ne = (e = {}) =>
|
|
1110
|
-
|
|
1110
|
+
j({
|
|
1111
1111
|
config: e,
|
|
1112
1112
|
name: 'u16',
|
|
1113
1113
|
range: [0, +'0xffff'],
|
|
@@ -1115,29 +1115,29 @@ var fe = (e = {}) =>
|
|
|
1115
1115
|
size: 2,
|
|
1116
1116
|
}),
|
|
1117
1117
|
Te = (e = {}) =>
|
|
1118
|
-
|
|
1118
|
+
J({
|
|
1119
1119
|
config: e,
|
|
1120
1120
|
get: (t, n) => t.getUint16(0, n),
|
|
1121
1121
|
name: 'u16',
|
|
1122
1122
|
size: 2,
|
|
1123
1123
|
}),
|
|
1124
|
-
|
|
1125
|
-
|
|
1124
|
+
V = (e = {}) =>
|
|
1125
|
+
j({
|
|
1126
1126
|
config: e,
|
|
1127
1127
|
name: 'u32',
|
|
1128
1128
|
range: [0, +'0xffffffff'],
|
|
1129
1129
|
set: (t, n, o) => t.setUint32(0, Number(n), o),
|
|
1130
1130
|
size: 4,
|
|
1131
1131
|
}),
|
|
1132
|
-
|
|
1133
|
-
|
|
1132
|
+
F = (e = {}) =>
|
|
1133
|
+
J({
|
|
1134
1134
|
config: e,
|
|
1135
1135
|
get: (t, n) => t.getUint32(0, n),
|
|
1136
1136
|
name: 'u32',
|
|
1137
1137
|
size: 4,
|
|
1138
1138
|
}),
|
|
1139
|
-
|
|
1140
|
-
|
|
1139
|
+
u = (e = {}) =>
|
|
1140
|
+
j({
|
|
1141
1141
|
config: e,
|
|
1142
1142
|
name: 'u64',
|
|
1143
1143
|
range: [0n, BigInt('0xffffffffffffffff')],
|
|
@@ -1145,102 +1145,102 @@ var fe = (e = {}) =>
|
|
|
1145
1145
|
size: 8,
|
|
1146
1146
|
}),
|
|
1147
1147
|
A = (e = {}) =>
|
|
1148
|
-
|
|
1148
|
+
J({
|
|
1149
1149
|
config: e,
|
|
1150
1150
|
get: (t, n) => t.getBigUint64(0, n),
|
|
1151
1151
|
name: 'u64',
|
|
1152
1152
|
size: 8,
|
|
1153
1153
|
}),
|
|
1154
|
-
|
|
1155
|
-
|
|
1154
|
+
O = () =>
|
|
1155
|
+
j({
|
|
1156
1156
|
name: 'u8',
|
|
1157
1157
|
range: [0, +'0xff'],
|
|
1158
1158
|
set: (e, t) => e.setUint8(0, Number(t)),
|
|
1159
1159
|
size: 1,
|
|
1160
1160
|
}),
|
|
1161
|
-
|
|
1162
|
-
|
|
1161
|
+
I = () =>
|
|
1162
|
+
J({
|
|
1163
1163
|
get: (e) => e.getUint8(0),
|
|
1164
1164
|
name: 'u8',
|
|
1165
1165
|
size: 1,
|
|
1166
1166
|
});
|
|
1167
|
-
function
|
|
1167
|
+
function Mt(e, t, n) {
|
|
1168
1168
|
if (t !== n)
|
|
1169
|
-
throw new T(
|
|
1169
|
+
throw new T(Ot, {
|
|
1170
1170
|
actual: n,
|
|
1171
1171
|
codecDescription: e,
|
|
1172
1172
|
expected: t,
|
|
1173
1173
|
});
|
|
1174
1174
|
}
|
|
1175
|
-
function
|
|
1175
|
+
function _s(e) {
|
|
1176
1176
|
return e.reduce((t, n) => (t === null || n === null ? null : Math.max(t, n)), 0);
|
|
1177
1177
|
}
|
|
1178
|
-
function
|
|
1178
|
+
function Y(e) {
|
|
1179
1179
|
return e.reduce((t, n) => (t === null || n === null ? null : t + n), 0);
|
|
1180
1180
|
}
|
|
1181
1181
|
function ne(e) {
|
|
1182
|
-
return
|
|
1182
|
+
return P(e) ? e.fixedSize : null;
|
|
1183
1183
|
}
|
|
1184
|
-
function
|
|
1185
|
-
return
|
|
1184
|
+
function q(e) {
|
|
1185
|
+
return P(e) ? e.fixedSize : (e.maxSize ?? null);
|
|
1186
1186
|
}
|
|
1187
1187
|
function Ae(e, t = {}) {
|
|
1188
|
-
const n = t.size ??
|
|
1189
|
-
o =
|
|
1190
|
-
r =
|
|
1188
|
+
const n = t.size ?? V(),
|
|
1189
|
+
o = ue(n, ne(e)),
|
|
1190
|
+
r = ue(n, q(e)) ?? void 0;
|
|
1191
1191
|
return w({
|
|
1192
1192
|
...(o !== null
|
|
1193
1193
|
? { fixedSize: o }
|
|
1194
1194
|
: {
|
|
1195
|
-
getSizeFromValue: (
|
|
1196
|
-
(typeof n == 'object' ? ee(
|
|
1195
|
+
getSizeFromValue: (a) =>
|
|
1196
|
+
(typeof n == 'object' ? ee(a.length, n) : 0) + [...a].reduce((s, _) => s + ee(_, e), 0),
|
|
1197
1197
|
maxSize: r,
|
|
1198
1198
|
}),
|
|
1199
|
-
write: (
|
|
1200
|
-
typeof n == 'number' &&
|
|
1201
|
-
typeof n == 'object' && (s = n.write(
|
|
1202
|
-
|
|
1203
|
-
s = e.write(_,
|
|
1199
|
+
write: (a, i, s) => (
|
|
1200
|
+
typeof n == 'number' && Mt('array', n, a.length),
|
|
1201
|
+
typeof n == 'object' && (s = n.write(a.length, i, s)),
|
|
1202
|
+
a.forEach((_) => {
|
|
1203
|
+
s = e.write(_, i, s);
|
|
1204
1204
|
}),
|
|
1205
1205
|
s
|
|
1206
1206
|
),
|
|
1207
1207
|
});
|
|
1208
1208
|
}
|
|
1209
1209
|
function de(e, t = {}) {
|
|
1210
|
-
const n = t.size ??
|
|
1210
|
+
const n = t.size ?? F(),
|
|
1211
1211
|
o = ne(e),
|
|
1212
|
-
r =
|
|
1213
|
-
|
|
1214
|
-
return
|
|
1215
|
-
...(r !== null ? { fixedSize: r } : { maxSize:
|
|
1216
|
-
read: (
|
|
1212
|
+
r = ue(n, o),
|
|
1213
|
+
a = ue(n, q(e)) ?? void 0;
|
|
1214
|
+
return x({
|
|
1215
|
+
...(r !== null ? { fixedSize: r } : { maxSize: a }),
|
|
1216
|
+
read: (i, s) => {
|
|
1217
1217
|
const _ = [];
|
|
1218
|
-
if (typeof n == 'object' &&
|
|
1218
|
+
if (typeof n == 'object' && i.slice(s).length === 0) return [_, s];
|
|
1219
1219
|
if (n === 'remainder') {
|
|
1220
|
-
for (; s <
|
|
1221
|
-
const [
|
|
1222
|
-
((s = y), _.push(
|
|
1220
|
+
for (; s < i.length; ) {
|
|
1221
|
+
const [d, y] = e.read(i, s);
|
|
1222
|
+
((s = y), _.push(d));
|
|
1223
1223
|
}
|
|
1224
1224
|
return [_, s];
|
|
1225
1225
|
}
|
|
1226
|
-
const [N,
|
|
1227
|
-
s =
|
|
1228
|
-
for (let
|
|
1229
|
-
const [y, W] = e.read(
|
|
1226
|
+
const [N, f] = typeof n == 'number' ? [n, s] : n.read(i, s);
|
|
1227
|
+
s = f;
|
|
1228
|
+
for (let d = 0; d < N; d += 1) {
|
|
1229
|
+
const [y, W] = e.read(i, s);
|
|
1230
1230
|
((s = W), _.push(y));
|
|
1231
1231
|
}
|
|
1232
1232
|
return [_, s];
|
|
1233
1233
|
},
|
|
1234
1234
|
});
|
|
1235
1235
|
}
|
|
1236
|
-
function
|
|
1236
|
+
function ue(e, t) {
|
|
1237
1237
|
return typeof e != 'number' ? null : e === 0 ? 0 : t === null ? null : t * e;
|
|
1238
1238
|
}
|
|
1239
1239
|
function yt(e = {}) {
|
|
1240
|
-
return b(e.size ??
|
|
1240
|
+
return b(e.size ?? O(), (t) => (t ? 1 : 0));
|
|
1241
1241
|
}
|
|
1242
1242
|
function kt(e = {}) {
|
|
1243
|
-
return Q(e.size ??
|
|
1243
|
+
return Q(e.size ?? I(), (t) => Number(t) === 1);
|
|
1244
1244
|
}
|
|
1245
1245
|
function h() {
|
|
1246
1246
|
return w({
|
|
@@ -1248,32 +1248,32 @@ function h() {
|
|
|
1248
1248
|
write: (e, t, n) => (t.set(e, n), n + e.length),
|
|
1249
1249
|
});
|
|
1250
1250
|
}
|
|
1251
|
-
function
|
|
1252
|
-
return
|
|
1251
|
+
function L() {
|
|
1252
|
+
return x({
|
|
1253
1253
|
read: (e, t) => {
|
|
1254
1254
|
const n = e.slice(t);
|
|
1255
1255
|
return [n, t + n.length];
|
|
1256
1256
|
},
|
|
1257
1257
|
});
|
|
1258
1258
|
}
|
|
1259
|
-
var
|
|
1260
|
-
|
|
1259
|
+
var cs = () =>
|
|
1260
|
+
x({
|
|
1261
1261
|
read(e, t) {
|
|
1262
1262
|
return [e.slice(t).reduce((o, r) => o + r.toString(16).padStart(2, '0'), ''), e.length];
|
|
1263
1263
|
},
|
|
1264
1264
|
});
|
|
1265
|
-
function
|
|
1265
|
+
function Rs(e) {
|
|
1266
1266
|
return w({
|
|
1267
1267
|
fixedSize: e.length,
|
|
1268
1268
|
write: (t, n, o) => (n.set(e, o), o + e.length),
|
|
1269
1269
|
});
|
|
1270
1270
|
}
|
|
1271
|
-
function
|
|
1272
|
-
return
|
|
1271
|
+
function us(e) {
|
|
1272
|
+
return x({
|
|
1273
1273
|
fixedSize: e.length,
|
|
1274
1274
|
read: (t, n) => {
|
|
1275
|
-
const o =
|
|
1276
|
-
if (!
|
|
1275
|
+
const o = cs();
|
|
1276
|
+
if (!H(t, e, n))
|
|
1277
1277
|
throw new T(ft, {
|
|
1278
1278
|
constant: e,
|
|
1279
1279
|
data: t,
|
|
@@ -1285,68 +1285,68 @@ function ls(e) {
|
|
|
1285
1285
|
},
|
|
1286
1286
|
});
|
|
1287
1287
|
}
|
|
1288
|
-
function
|
|
1289
|
-
const t =
|
|
1290
|
-
n =
|
|
1288
|
+
function ge(e) {
|
|
1289
|
+
const t = Y(e.map(ne)),
|
|
1290
|
+
n = Y(e.map(q)) ?? void 0;
|
|
1291
1291
|
return w({
|
|
1292
1292
|
...(t === null
|
|
1293
1293
|
? {
|
|
1294
|
-
getSizeFromValue: (o) => e.map((r,
|
|
1294
|
+
getSizeFromValue: (o) => e.map((r, a) => ee(o[a], r)).reduce((r, a) => r + a, 0),
|
|
1295
1295
|
maxSize: n,
|
|
1296
1296
|
}
|
|
1297
1297
|
: { fixedSize: t }),
|
|
1298
|
-
write: (o, r,
|
|
1299
|
-
|
|
1300
|
-
e.forEach((
|
|
1301
|
-
|
|
1298
|
+
write: (o, r, a) => (
|
|
1299
|
+
Mt('tuple', e.length, o.length),
|
|
1300
|
+
e.forEach((i, s) => {
|
|
1301
|
+
a = i.write(o[s], r, a);
|
|
1302
1302
|
}),
|
|
1303
|
-
|
|
1303
|
+
a
|
|
1304
1304
|
),
|
|
1305
1305
|
});
|
|
1306
1306
|
}
|
|
1307
|
-
function
|
|
1308
|
-
const t =
|
|
1309
|
-
n =
|
|
1310
|
-
return
|
|
1307
|
+
function me(e) {
|
|
1308
|
+
const t = Y(e.map(ne)),
|
|
1309
|
+
n = Y(e.map(q)) ?? void 0;
|
|
1310
|
+
return x({
|
|
1311
1311
|
...(t === null ? { maxSize: n } : { fixedSize: t }),
|
|
1312
1312
|
read: (o, r) => {
|
|
1313
|
-
const
|
|
1313
|
+
const a = [];
|
|
1314
1314
|
return (
|
|
1315
|
-
e.forEach((
|
|
1316
|
-
const [s, _] =
|
|
1317
|
-
(
|
|
1315
|
+
e.forEach((i) => {
|
|
1316
|
+
const [s, _] = i.read(o, r);
|
|
1317
|
+
(a.push(s), (r = _));
|
|
1318
1318
|
}),
|
|
1319
|
-
[
|
|
1319
|
+
[a, r]
|
|
1320
1320
|
);
|
|
1321
1321
|
},
|
|
1322
1322
|
});
|
|
1323
1323
|
}
|
|
1324
1324
|
function Bt(e, t) {
|
|
1325
1325
|
const n = Vt(e),
|
|
1326
|
-
o = (
|
|
1327
|
-
const _ = t(
|
|
1328
|
-
return (Ce(e, _), e[_].write(
|
|
1326
|
+
o = (a, i, s) => {
|
|
1327
|
+
const _ = t(a);
|
|
1328
|
+
return (Ce(e, _), e[_].write(a, i, s));
|
|
1329
1329
|
};
|
|
1330
1330
|
if (n !== null) return w({ fixedSize: n, write: o });
|
|
1331
1331
|
const r = Ft(e);
|
|
1332
1332
|
return w({
|
|
1333
1333
|
...(r !== null ? { maxSize: r } : {}),
|
|
1334
|
-
getSizeFromValue: (
|
|
1335
|
-
const
|
|
1336
|
-
return (Ce(e,
|
|
1334
|
+
getSizeFromValue: (a) => {
|
|
1335
|
+
const i = t(a);
|
|
1336
|
+
return (Ce(e, i), ee(a, e[i]));
|
|
1337
1337
|
},
|
|
1338
1338
|
write: o,
|
|
1339
1339
|
});
|
|
1340
1340
|
}
|
|
1341
1341
|
function Gt(e, t) {
|
|
1342
1342
|
const n = Vt(e),
|
|
1343
|
-
o = (
|
|
1344
|
-
const s = t(
|
|
1345
|
-
return (Ce(e, s), e[s].read(
|
|
1343
|
+
o = (a, i) => {
|
|
1344
|
+
const s = t(a, i);
|
|
1345
|
+
return (Ce(e, s), e[s].read(a, i));
|
|
1346
1346
|
};
|
|
1347
|
-
if (n !== null) return
|
|
1347
|
+
if (n !== null) return x({ fixedSize: n, read: o });
|
|
1348
1348
|
const r = Ft(e);
|
|
1349
|
-
return
|
|
1349
|
+
return x({ ...(r !== null ? { maxSize: r } : {}), read: o });
|
|
1350
1350
|
}
|
|
1351
1351
|
function Ce(e, t) {
|
|
1352
1352
|
if (typeof e[t] > 'u')
|
|
@@ -1358,35 +1358,35 @@ function Ce(e, t) {
|
|
|
1358
1358
|
}
|
|
1359
1359
|
function Vt(e) {
|
|
1360
1360
|
if (e.length === 0) return 0;
|
|
1361
|
-
if (!
|
|
1361
|
+
if (!P(e[0])) return null;
|
|
1362
1362
|
const t = e[0].fixedSize;
|
|
1363
|
-
return e.every((o) =>
|
|
1363
|
+
return e.every((o) => P(o) && o.fixedSize === t) ? t : null;
|
|
1364
1364
|
}
|
|
1365
1365
|
function Ft(e) {
|
|
1366
|
-
return
|
|
1366
|
+
return _s(e.map((t) => q(t)));
|
|
1367
1367
|
}
|
|
1368
1368
|
function re(e, t = {}) {
|
|
1369
1369
|
const n = t.discriminator ?? '__kind',
|
|
1370
|
-
o = t.size ??
|
|
1370
|
+
o = t.size ?? O();
|
|
1371
1371
|
return Bt(
|
|
1372
|
-
e.map(([, r],
|
|
1373
|
-
(r) =>
|
|
1372
|
+
e.map(([, r], a) => b(ge([o, r]), (i) => [a, i])),
|
|
1373
|
+
(r) => As(e, r[n])
|
|
1374
1374
|
);
|
|
1375
1375
|
}
|
|
1376
1376
|
function oe(e, t = {}) {
|
|
1377
1377
|
const n = t.discriminator ?? '__kind',
|
|
1378
|
-
o = t.size ??
|
|
1378
|
+
o = t.size ?? I();
|
|
1379
1379
|
return Gt(
|
|
1380
|
-
e.map(([r,
|
|
1381
|
-
Q(
|
|
1380
|
+
e.map(([r, a]) =>
|
|
1381
|
+
Q(me([o, a]), ([, i]) => ({
|
|
1382
1382
|
[n]: r,
|
|
1383
|
-
...
|
|
1383
|
+
...i,
|
|
1384
1384
|
}))
|
|
1385
1385
|
),
|
|
1386
|
-
(r,
|
|
1386
|
+
(r, a) => Number(o.read(r, a)[0])
|
|
1387
1387
|
);
|
|
1388
1388
|
}
|
|
1389
|
-
function
|
|
1389
|
+
function As(e, t) {
|
|
1390
1390
|
const n = e.findIndex(([o]) => t === o);
|
|
1391
1391
|
if (n < 0)
|
|
1392
1392
|
throw new T(Et, {
|
|
@@ -1396,18 +1396,18 @@ function Os(e, t) {
|
|
|
1396
1396
|
return n;
|
|
1397
1397
|
}
|
|
1398
1398
|
function zt(e) {
|
|
1399
|
-
const t = [...new Set(Object.values(e).filter((
|
|
1399
|
+
const t = [...new Set(Object.values(e).filter((i) => typeof i == 'number'))].sort(),
|
|
1400
1400
|
n = Object.fromEntries(Object.entries(e).slice(t.length)),
|
|
1401
1401
|
o = Object.keys(n),
|
|
1402
1402
|
r = Object.values(n),
|
|
1403
|
-
|
|
1404
|
-
return { enumKeys: o, enumRecord: n, enumValues: r, numericalValues: t, stringValues:
|
|
1403
|
+
a = [.../* @__PURE__ */ new Set([...o, ...r.filter((i) => typeof i == 'string')])];
|
|
1404
|
+
return { enumKeys: o, enumRecord: n, enumValues: r, numericalValues: t, stringValues: a };
|
|
1405
1405
|
}
|
|
1406
|
-
function
|
|
1406
|
+
function ds({ enumKeys: e, enumValues: t, variant: n }) {
|
|
1407
1407
|
const o = Ht(t, (r) => r === n);
|
|
1408
1408
|
return o >= 0 ? o : e.findIndex((r) => r === n);
|
|
1409
1409
|
}
|
|
1410
|
-
function
|
|
1410
|
+
function Os({ discriminator: e, enumKeys: t, enumValues: n, useValuesAsDiscriminators: o }) {
|
|
1411
1411
|
return o ? Ht(n, (r) => r === e) : e >= 0 && e < t.length ? e : -1;
|
|
1412
1412
|
}
|
|
1413
1413
|
function Ht(e, t) {
|
|
@@ -1428,50 +1428,50 @@ function Wt(e) {
|
|
|
1428
1428
|
return (n.push(t[0] === t[1] ? `${t[0]}` : `${t[0]}-${t[1]}`), n.join(', '));
|
|
1429
1429
|
}
|
|
1430
1430
|
function ae(e, t = {}) {
|
|
1431
|
-
const n = t.size ??
|
|
1431
|
+
const n = t.size ?? O(),
|
|
1432
1432
|
o = t.useValuesAsDiscriminators ?? !1,
|
|
1433
|
-
{ enumKeys: r, enumValues:
|
|
1434
|
-
if (o &&
|
|
1435
|
-
throw new T(
|
|
1436
|
-
stringValues:
|
|
1433
|
+
{ enumKeys: r, enumValues: a, numericalValues: i, stringValues: s } = zt(e);
|
|
1434
|
+
if (o && a.some((_) => typeof _ == 'string'))
|
|
1435
|
+
throw new T(ve, {
|
|
1436
|
+
stringValues: a.filter((_) => typeof _ == 'string'),
|
|
1437
1437
|
});
|
|
1438
1438
|
return b(n, (_) => {
|
|
1439
|
-
const N =
|
|
1439
|
+
const N = ds({ enumKeys: r, enumValues: a, variant: _ });
|
|
1440
1440
|
if (N < 0)
|
|
1441
1441
|
throw new T(Nt, {
|
|
1442
|
-
formattedNumericalValues: Wt(
|
|
1443
|
-
numericalValues:
|
|
1442
|
+
formattedNumericalValues: Wt(i),
|
|
1443
|
+
numericalValues: i,
|
|
1444
1444
|
stringValues: s,
|
|
1445
1445
|
variant: _,
|
|
1446
1446
|
});
|
|
1447
|
-
return o ?
|
|
1447
|
+
return o ? a[N] : N;
|
|
1448
1448
|
});
|
|
1449
1449
|
}
|
|
1450
1450
|
function ie(e, t = {}) {
|
|
1451
|
-
const n = t.size ??
|
|
1451
|
+
const n = t.size ?? I(),
|
|
1452
1452
|
o = t.useValuesAsDiscriminators ?? !1,
|
|
1453
|
-
{ enumKeys: r, enumValues:
|
|
1454
|
-
if (o &&
|
|
1455
|
-
throw new T(
|
|
1456
|
-
stringValues:
|
|
1453
|
+
{ enumKeys: r, enumValues: a, numericalValues: i } = zt(e);
|
|
1454
|
+
if (o && a.some((s) => typeof s == 'string'))
|
|
1455
|
+
throw new T(ve, {
|
|
1456
|
+
stringValues: a.filter((s) => typeof s == 'string'),
|
|
1457
1457
|
});
|
|
1458
1458
|
return Q(n, (s) => {
|
|
1459
1459
|
const _ = Number(s),
|
|
1460
|
-
N =
|
|
1460
|
+
N = Os({
|
|
1461
1461
|
discriminator: _,
|
|
1462
1462
|
enumKeys: r,
|
|
1463
|
-
enumValues:
|
|
1463
|
+
enumValues: a,
|
|
1464
1464
|
useValuesAsDiscriminators: o,
|
|
1465
1465
|
});
|
|
1466
1466
|
if (N < 0) {
|
|
1467
|
-
const
|
|
1468
|
-
throw new T(
|
|
1467
|
+
const f = o ? i : [...Array(r.length).keys()];
|
|
1468
|
+
throw new T(lt, {
|
|
1469
1469
|
discriminator: _,
|
|
1470
|
-
formattedValidDiscriminators: Wt(
|
|
1471
|
-
validDiscriminators:
|
|
1470
|
+
formattedValidDiscriminators: Wt(f),
|
|
1471
|
+
validDiscriminators: f,
|
|
1472
1472
|
});
|
|
1473
1473
|
}
|
|
1474
|
-
return
|
|
1474
|
+
return a[N];
|
|
1475
1475
|
});
|
|
1476
1476
|
}
|
|
1477
1477
|
function se() {
|
|
@@ -1481,44 +1481,44 @@ function se() {
|
|
|
1481
1481
|
});
|
|
1482
1482
|
}
|
|
1483
1483
|
function _e() {
|
|
1484
|
-
return
|
|
1484
|
+
return x({
|
|
1485
1485
|
fixedSize: 0,
|
|
1486
1486
|
read: (e, t) => [void 0, t],
|
|
1487
1487
|
});
|
|
1488
1488
|
}
|
|
1489
|
-
function
|
|
1489
|
+
function l(e) {
|
|
1490
1490
|
const t = e.map(([, r]) => r),
|
|
1491
|
-
n =
|
|
1492
|
-
o =
|
|
1491
|
+
n = Y(t.map(ne)),
|
|
1492
|
+
o = Y(t.map(q)) ?? void 0;
|
|
1493
1493
|
return w({
|
|
1494
1494
|
...(n === null
|
|
1495
1495
|
? {
|
|
1496
|
-
getSizeFromValue: (r) => e.map(([
|
|
1496
|
+
getSizeFromValue: (r) => e.map(([a, i]) => ee(r[a], i)).reduce((a, i) => a + i, 0),
|
|
1497
1497
|
maxSize: o,
|
|
1498
1498
|
}
|
|
1499
1499
|
: { fixedSize: n }),
|
|
1500
|
-
write: (r,
|
|
1500
|
+
write: (r, a, i) => (
|
|
1501
1501
|
e.forEach(([s, _]) => {
|
|
1502
|
-
|
|
1502
|
+
i = _.write(r[s], a, i);
|
|
1503
1503
|
}),
|
|
1504
|
-
|
|
1504
|
+
i
|
|
1505
1505
|
),
|
|
1506
1506
|
});
|
|
1507
1507
|
}
|
|
1508
1508
|
function E(e) {
|
|
1509
1509
|
const t = e.map(([, r]) => r),
|
|
1510
|
-
n =
|
|
1511
|
-
o =
|
|
1512
|
-
return
|
|
1510
|
+
n = Y(t.map(ne)),
|
|
1511
|
+
o = Y(t.map(q)) ?? void 0;
|
|
1512
|
+
return x({
|
|
1513
1513
|
...(n === null ? { maxSize: o } : { fixedSize: n }),
|
|
1514
|
-
read: (r,
|
|
1515
|
-
const
|
|
1514
|
+
read: (r, a) => {
|
|
1515
|
+
const i = {};
|
|
1516
1516
|
return (
|
|
1517
1517
|
e.forEach(([s, _]) => {
|
|
1518
|
-
const [N,
|
|
1519
|
-
((
|
|
1518
|
+
const [N, f] = _.read(r, a);
|
|
1519
|
+
((a = f), (i[s] = N));
|
|
1520
1520
|
}),
|
|
1521
|
-
[
|
|
1521
|
+
[i, a]
|
|
1522
1522
|
);
|
|
1523
1523
|
},
|
|
1524
1524
|
});
|
|
@@ -1533,41 +1533,41 @@ var $t = (e) => ({ __option: 'Some', value: e }),
|
|
|
1533
1533
|
((e.__option === 'Some' && 'value' in e) || e.__option === 'None')
|
|
1534
1534
|
),
|
|
1535
1535
|
Xe = (e) => e.__option === 'Some',
|
|
1536
|
-
|
|
1537
|
-
function
|
|
1538
|
-
const n = t.prefix === null ? b(se(), (r) => {}) : yt({ size: t.prefix ??
|
|
1536
|
+
ls = (e) => (e !== null ? $t(e) : Xt());
|
|
1537
|
+
function Es(e, t = {}) {
|
|
1538
|
+
const n = t.prefix === null ? b(se(), (r) => {}) : yt({ size: t.prefix ?? O() }),
|
|
1539
1539
|
o =
|
|
1540
1540
|
t.noneValue === 'zeroes'
|
|
1541
|
-
? (
|
|
1541
|
+
? (mt(e), m(se(), e.fixedSize))
|
|
1542
1542
|
: t.noneValue
|
|
1543
|
-
?
|
|
1543
|
+
? Rs(t.noneValue)
|
|
1544
1544
|
: se();
|
|
1545
1545
|
return Bt(
|
|
1546
|
-
[b(
|
|
1546
|
+
[b(ge([n, o]), (r) => [!1, void 0]), b(ge([n, e]), (r) => [!0, $e(r) && Xe(r) ? r.value : r])],
|
|
1547
1547
|
(r) => {
|
|
1548
|
-
const
|
|
1549
|
-
return Number(Xe(
|
|
1548
|
+
const a = $e(r) ? r : ls(r);
|
|
1549
|
+
return Number(Xe(a));
|
|
1550
1550
|
}
|
|
1551
1551
|
);
|
|
1552
1552
|
}
|
|
1553
|
-
function
|
|
1554
|
-
const n = t.prefix === null ? Q(_e(), () => !1) : kt({ size: t.prefix ??
|
|
1553
|
+
function Ns(e, t = {}) {
|
|
1554
|
+
const n = t.prefix === null ? Q(_e(), () => !1) : kt({ size: t.prefix ?? I() }),
|
|
1555
1555
|
o =
|
|
1556
1556
|
t.noneValue === 'zeroes'
|
|
1557
|
-
? (
|
|
1557
|
+
? (mt(e), C(_e(), e.fixedSize))
|
|
1558
1558
|
: t.noneValue
|
|
1559
|
-
?
|
|
1559
|
+
? us(t.noneValue)
|
|
1560
1560
|
: _e();
|
|
1561
|
-
return Gt([Q(
|
|
1562
|
-
if (t.prefix === null && !t.noneValue) return +(
|
|
1561
|
+
return Gt([Q(me([n, o]), () => Xt()), Q(me([n, e]), ([, r]) => $t(r))], (r, a) => {
|
|
1562
|
+
if (t.prefix === null && !t.noneValue) return +(a < r.length);
|
|
1563
1563
|
if (t.prefix === null && t.noneValue != null) {
|
|
1564
|
-
const
|
|
1565
|
-
return
|
|
1564
|
+
const i = t.noneValue === 'zeroes' ? new Uint8Array(o.fixedSize).fill(0) : t.noneValue;
|
|
1565
|
+
return H(r, i, a) ? 0 : 1;
|
|
1566
1566
|
}
|
|
1567
|
-
return Number(n.read(r,
|
|
1567
|
+
return Number(n.read(r, a)[0]);
|
|
1568
1568
|
});
|
|
1569
1569
|
}
|
|
1570
|
-
function
|
|
1570
|
+
function K(e) {
|
|
1571
1571
|
if (e.accounts === void 0)
|
|
1572
1572
|
throw new T(it, {
|
|
1573
1573
|
data: e.data,
|
|
@@ -1581,30 +1581,30 @@ var ce = /* @__PURE__ */ ((e) => (
|
|
|
1581
1581
|
(e[(e.READONLY = /* 0 */ 0)] = 'READONLY'),
|
|
1582
1582
|
e
|
|
1583
1583
|
))(ce || {}),
|
|
1584
|
-
|
|
1585
|
-
function
|
|
1586
|
-
return e |
|
|
1587
|
-
}
|
|
1588
|
-
function
|
|
1589
|
-
var
|
|
1590
|
-
if (!
|
|
1591
|
-
const r = (
|
|
1584
|
+
Ts = 2;
|
|
1585
|
+
function Ss(e) {
|
|
1586
|
+
return e | Ts;
|
|
1587
|
+
}
|
|
1588
|
+
function fs(e, t, n, o) {
|
|
1589
|
+
var a;
|
|
1590
|
+
if (!gt(e, st)) return !1;
|
|
1591
|
+
const r = (a = t.instructions[e.context.index]) == null ? void 0 : a.programAddress;
|
|
1592
1592
|
return !r || r !== n ? !1 : typeof o > 'u' || e.context.code === o;
|
|
1593
1593
|
}
|
|
1594
|
-
function
|
|
1594
|
+
function Is(e) {
|
|
1595
1595
|
return 'modifyAndSignTransactions' in e && typeof e.modifyAndSignTransactions == 'function';
|
|
1596
1596
|
}
|
|
1597
|
-
function
|
|
1597
|
+
function gs(e) {
|
|
1598
1598
|
return 'signTransactions' in e && typeof e.signTransactions == 'function';
|
|
1599
1599
|
}
|
|
1600
|
-
function
|
|
1600
|
+
function ms(e) {
|
|
1601
1601
|
return 'signAndSendTransactions' in e && typeof e.signAndSendTransactions == 'function';
|
|
1602
1602
|
}
|
|
1603
|
-
function
|
|
1604
|
-
return
|
|
1603
|
+
function Cs(e) {
|
|
1604
|
+
return gs(e) || Is(e) || ms(e);
|
|
1605
1605
|
}
|
|
1606
|
-
const
|
|
1607
|
-
|
|
1606
|
+
const hs = V,
|
|
1607
|
+
Ls = F;
|
|
1608
1608
|
var be = /* @__PURE__ */ ((e) => (
|
|
1609
1609
|
(e[(e.Uninitialized = 0)] = 'Uninitialized'),
|
|
1610
1610
|
(e[(e.Closed = 1)] = 'Closed'),
|
|
@@ -1612,19 +1612,18 @@ var be = /* @__PURE__ */ ((e) => (
|
|
|
1612
1612
|
(e[(e.Automation = 3)] = 'Automation'),
|
|
1613
1613
|
e
|
|
1614
1614
|
))(be || {});
|
|
1615
|
-
function
|
|
1615
|
+
function Ue() {
|
|
1616
1616
|
return ae(be);
|
|
1617
1617
|
}
|
|
1618
|
-
function
|
|
1618
|
+
function Pe() {
|
|
1619
1619
|
return ie(be);
|
|
1620
1620
|
}
|
|
1621
|
-
function
|
|
1622
|
-
return S(
|
|
1621
|
+
function j_() {
|
|
1622
|
+
return S(Ue(), Pe());
|
|
1623
1623
|
}
|
|
1624
1624
|
var we = /* @__PURE__ */ ((e) => (
|
|
1625
1625
|
(e[(e.Uninitialized = 0)] = 'Uninitialized'),
|
|
1626
|
-
(e[(e.
|
|
1627
|
-
(e[(e.HarvestSwapAndReinvest = 2)] = 'HarvestSwapAndReinvest'),
|
|
1626
|
+
(e[(e.HarvestSwapAndReinvest = 1)] = 'HarvestSwapAndReinvest'),
|
|
1628
1627
|
e
|
|
1629
1628
|
))(we || {});
|
|
1630
1629
|
function Yt() {
|
|
@@ -1633,7 +1632,7 @@ function Yt() {
|
|
|
1633
1632
|
function Kt() {
|
|
1634
1633
|
return ie(we);
|
|
1635
1634
|
}
|
|
1636
|
-
function
|
|
1635
|
+
function J_() {
|
|
1637
1636
|
return S(Yt(), Kt());
|
|
1638
1637
|
}
|
|
1639
1638
|
function jt() {
|
|
@@ -1641,13 +1640,13 @@ function jt() {
|
|
|
1641
1640
|
['None', se()],
|
|
1642
1641
|
[
|
|
1643
1642
|
'NextValidExecutionTimestamp',
|
|
1644
|
-
|
|
1645
|
-
['nextValidExecutionTimestamp',
|
|
1646
|
-
['minIntervalSeconds',
|
|
1643
|
+
l([
|
|
1644
|
+
['nextValidExecutionTimestamp', is()],
|
|
1645
|
+
['minIntervalSeconds', Es(hs())],
|
|
1647
1646
|
]),
|
|
1648
1647
|
],
|
|
1649
|
-
['MinFeesOwedA',
|
|
1650
|
-
['MinFeesOwedB',
|
|
1648
|
+
['MinFeesOwedA', l([['minFeesOwedA', u()]])],
|
|
1649
|
+
['MinFeesOwedB', l([['minFeesOwedB', u()]])],
|
|
1651
1650
|
]);
|
|
1652
1651
|
}
|
|
1653
1652
|
function Jt() {
|
|
@@ -1656,181 +1655,181 @@ function Jt() {
|
|
|
1656
1655
|
[
|
|
1657
1656
|
'NextValidExecutionTimestamp',
|
|
1658
1657
|
E([
|
|
1659
|
-
['nextValidExecutionTimestamp',
|
|
1660
|
-
['minIntervalSeconds',
|
|
1658
|
+
['nextValidExecutionTimestamp', ss()],
|
|
1659
|
+
['minIntervalSeconds', Ns(Ls())],
|
|
1661
1660
|
]),
|
|
1662
1661
|
],
|
|
1663
1662
|
['MinFeesOwedA', E([['minFeesOwedA', A()]])],
|
|
1664
1663
|
['MinFeesOwedB', E([['minFeesOwedB', A()]])],
|
|
1665
1664
|
]);
|
|
1666
1665
|
}
|
|
1667
|
-
function
|
|
1666
|
+
function q_() {
|
|
1668
1667
|
return S(jt(), Jt());
|
|
1669
1668
|
}
|
|
1670
|
-
function
|
|
1669
|
+
function Z_(e, t) {
|
|
1671
1670
|
return Array.isArray(t) ? { __kind: e, fields: t } : { __kind: e, ...(t ?? {}) };
|
|
1672
1671
|
}
|
|
1673
|
-
function
|
|
1672
|
+
function Q_(e, t) {
|
|
1674
1673
|
return t.__kind === e;
|
|
1675
1674
|
}
|
|
1676
|
-
function
|
|
1675
|
+
function vs() {
|
|
1677
1676
|
return re([
|
|
1678
1677
|
[
|
|
1679
1678
|
'CrankRewardDefaultUpdated',
|
|
1680
|
-
|
|
1681
|
-
['newCrankRewardDefault',
|
|
1682
|
-
['prevCrankRewardDefault',
|
|
1679
|
+
l([
|
|
1680
|
+
['newCrankRewardDefault', u()],
|
|
1681
|
+
['prevCrankRewardDefault', u()],
|
|
1683
1682
|
['updatedBy', c()],
|
|
1684
1683
|
]),
|
|
1685
1684
|
],
|
|
1686
1685
|
[
|
|
1687
1686
|
'GlobalConfigAuthorityUpdated',
|
|
1688
|
-
|
|
1687
|
+
l([
|
|
1689
1688
|
['newGlobalConfigAuthority', c()],
|
|
1690
1689
|
['prevGlobalConfigAuthority', c()],
|
|
1691
1690
|
]),
|
|
1692
1691
|
],
|
|
1693
1692
|
[
|
|
1694
1693
|
'AutomationCreated',
|
|
1695
|
-
|
|
1694
|
+
l([
|
|
1696
1695
|
['automation', c()],
|
|
1697
1696
|
['positionTokenAccount', c()],
|
|
1698
1697
|
['position', c()],
|
|
1699
|
-
['actionData',
|
|
1700
|
-
['automationIndex',
|
|
1701
|
-
['conditionsData',
|
|
1702
|
-
['crankReward',
|
|
1698
|
+
['actionData', m(h(), 64)],
|
|
1699
|
+
['automationIndex', O()],
|
|
1700
|
+
['conditionsData', m(h(), 192)],
|
|
1701
|
+
['crankReward', u()],
|
|
1703
1702
|
]),
|
|
1704
1703
|
],
|
|
1705
1704
|
[
|
|
1706
1705
|
'AutomationRemoved',
|
|
1707
|
-
|
|
1706
|
+
l([
|
|
1708
1707
|
['automation', c()],
|
|
1709
1708
|
['positionTokenAccount', c()],
|
|
1710
1709
|
['position', c()],
|
|
1711
|
-
['actionData',
|
|
1712
|
-
['automationIndex',
|
|
1713
|
-
['conditionsData',
|
|
1714
|
-
['crankReward',
|
|
1710
|
+
['actionData', m(h(), 64)],
|
|
1711
|
+
['automationIndex', O()],
|
|
1712
|
+
['conditionsData', m(h(), 192)],
|
|
1713
|
+
['crankReward', u()],
|
|
1715
1714
|
]),
|
|
1716
1715
|
],
|
|
1717
1716
|
[
|
|
1718
1717
|
'AutomationFunded',
|
|
1719
|
-
|
|
1718
|
+
l([
|
|
1720
1719
|
['automation', c()],
|
|
1721
1720
|
['payer', c()],
|
|
1722
|
-
['amountFunded',
|
|
1721
|
+
['amountFunded', u()],
|
|
1723
1722
|
['method', qt()],
|
|
1724
|
-
['value',
|
|
1723
|
+
['value', V()],
|
|
1725
1724
|
]),
|
|
1726
1725
|
],
|
|
1727
1726
|
[
|
|
1728
1727
|
'HarvestedAndReinvested',
|
|
1729
|
-
|
|
1728
|
+
l([
|
|
1730
1729
|
['automation', c()],
|
|
1731
1730
|
['positionTokenAccount', c()],
|
|
1732
1731
|
['position', c()],
|
|
1733
|
-
['automationIndex',
|
|
1734
|
-
['conditionsData',
|
|
1735
|
-
['feesCollectedA',
|
|
1736
|
-
['feesCollectedB',
|
|
1737
|
-
['liquidityIncreasedA',
|
|
1738
|
-
['liquidityIncreasedB',
|
|
1739
|
-
['tokenATransferFee',
|
|
1740
|
-
['tokenBTransferFee',
|
|
1741
|
-
['crankReward',
|
|
1732
|
+
['automationIndex', O()],
|
|
1733
|
+
['conditionsData', m(h(), 192)],
|
|
1734
|
+
['feesCollectedA', u()],
|
|
1735
|
+
['feesCollectedB', u()],
|
|
1736
|
+
['liquidityIncreasedA', u()],
|
|
1737
|
+
['liquidityIncreasedB', u()],
|
|
1738
|
+
['tokenATransferFee', u()],
|
|
1739
|
+
['tokenBTransferFee', u()],
|
|
1740
|
+
['crankReward', u()],
|
|
1742
1741
|
]),
|
|
1743
1742
|
],
|
|
1744
1743
|
[
|
|
1745
1744
|
'HarvestSwapAndReinvestPre',
|
|
1746
|
-
|
|
1745
|
+
l([
|
|
1747
1746
|
['automation', c()],
|
|
1748
1747
|
['positionTokenAccount', c()],
|
|
1749
1748
|
['position', c()],
|
|
1750
|
-
['automationIndex',
|
|
1751
|
-
['conditionsData',
|
|
1752
|
-
['feesCollectedA',
|
|
1753
|
-
['feesCollectedB',
|
|
1749
|
+
['automationIndex', O()],
|
|
1750
|
+
['conditionsData', m(h(), 192)],
|
|
1751
|
+
['feesCollectedA', u()],
|
|
1752
|
+
['feesCollectedB', u()],
|
|
1754
1753
|
]),
|
|
1755
1754
|
],
|
|
1756
1755
|
[
|
|
1757
1756
|
'HarvestSwapAndReinvestPost',
|
|
1758
|
-
|
|
1757
|
+
l([
|
|
1759
1758
|
['automation', c()],
|
|
1760
1759
|
['positionTokenAccount', c()],
|
|
1761
1760
|
['position', c()],
|
|
1762
|
-
['postSwapAmountA',
|
|
1763
|
-
['postSwapAmountB',
|
|
1764
|
-
['liquidityIncreasedA',
|
|
1765
|
-
['liquidityIncreasedB',
|
|
1766
|
-
['tokenATransferFee',
|
|
1767
|
-
['tokenBTransferFee',
|
|
1768
|
-
['crankReward',
|
|
1769
|
-
['amountToTransferToUserA',
|
|
1770
|
-
['amountToTransferToUserB',
|
|
1761
|
+
['postSwapAmountA', u()],
|
|
1762
|
+
['postSwapAmountB', u()],
|
|
1763
|
+
['liquidityIncreasedA', u()],
|
|
1764
|
+
['liquidityIncreasedB', u()],
|
|
1765
|
+
['tokenATransferFee', u()],
|
|
1766
|
+
['tokenBTransferFee', u()],
|
|
1767
|
+
['crankReward', u()],
|
|
1768
|
+
['amountToTransferToUserA', u()],
|
|
1769
|
+
['amountToTransferToUserB', u()],
|
|
1771
1770
|
]),
|
|
1772
1771
|
],
|
|
1773
1772
|
]);
|
|
1774
1773
|
}
|
|
1775
|
-
function
|
|
1774
|
+
function ps() {
|
|
1776
1775
|
return oe([
|
|
1777
1776
|
[
|
|
1778
1777
|
'CrankRewardDefaultUpdated',
|
|
1779
1778
|
E([
|
|
1780
1779
|
['newCrankRewardDefault', A()],
|
|
1781
1780
|
['prevCrankRewardDefault', A()],
|
|
1782
|
-
['updatedBy',
|
|
1781
|
+
['updatedBy', R()],
|
|
1783
1782
|
]),
|
|
1784
1783
|
],
|
|
1785
1784
|
[
|
|
1786
1785
|
'GlobalConfigAuthorityUpdated',
|
|
1787
1786
|
E([
|
|
1788
|
-
['newGlobalConfigAuthority',
|
|
1789
|
-
['prevGlobalConfigAuthority',
|
|
1787
|
+
['newGlobalConfigAuthority', R()],
|
|
1788
|
+
['prevGlobalConfigAuthority', R()],
|
|
1790
1789
|
]),
|
|
1791
1790
|
],
|
|
1792
1791
|
[
|
|
1793
1792
|
'AutomationCreated',
|
|
1794
1793
|
E([
|
|
1795
|
-
['automation',
|
|
1796
|
-
['positionTokenAccount',
|
|
1797
|
-
['position',
|
|
1798
|
-
['actionData', C(
|
|
1799
|
-
['automationIndex',
|
|
1800
|
-
['conditionsData', C(
|
|
1794
|
+
['automation', R()],
|
|
1795
|
+
['positionTokenAccount', R()],
|
|
1796
|
+
['position', R()],
|
|
1797
|
+
['actionData', C(L(), 64)],
|
|
1798
|
+
['automationIndex', I()],
|
|
1799
|
+
['conditionsData', C(L(), 192)],
|
|
1801
1800
|
['crankReward', A()],
|
|
1802
1801
|
]),
|
|
1803
1802
|
],
|
|
1804
1803
|
[
|
|
1805
1804
|
'AutomationRemoved',
|
|
1806
1805
|
E([
|
|
1807
|
-
['automation',
|
|
1808
|
-
['positionTokenAccount',
|
|
1809
|
-
['position',
|
|
1810
|
-
['actionData', C(
|
|
1811
|
-
['automationIndex',
|
|
1812
|
-
['conditionsData', C(
|
|
1806
|
+
['automation', R()],
|
|
1807
|
+
['positionTokenAccount', R()],
|
|
1808
|
+
['position', R()],
|
|
1809
|
+
['actionData', C(L(), 64)],
|
|
1810
|
+
['automationIndex', I()],
|
|
1811
|
+
['conditionsData', C(L(), 192)],
|
|
1813
1812
|
['crankReward', A()],
|
|
1814
1813
|
]),
|
|
1815
1814
|
],
|
|
1816
1815
|
[
|
|
1817
1816
|
'AutomationFunded',
|
|
1818
1817
|
E([
|
|
1819
|
-
['automation',
|
|
1820
|
-
['payer',
|
|
1818
|
+
['automation', R()],
|
|
1819
|
+
['payer', R()],
|
|
1821
1820
|
['amountFunded', A()],
|
|
1822
1821
|
['method', Zt()],
|
|
1823
|
-
['value',
|
|
1822
|
+
['value', F()],
|
|
1824
1823
|
]),
|
|
1825
1824
|
],
|
|
1826
1825
|
[
|
|
1827
1826
|
'HarvestedAndReinvested',
|
|
1828
1827
|
E([
|
|
1829
|
-
['automation',
|
|
1830
|
-
['positionTokenAccount',
|
|
1831
|
-
['position',
|
|
1832
|
-
['automationIndex',
|
|
1833
|
-
['conditionsData', C(
|
|
1828
|
+
['automation', R()],
|
|
1829
|
+
['positionTokenAccount', R()],
|
|
1830
|
+
['position', R()],
|
|
1831
|
+
['automationIndex', I()],
|
|
1832
|
+
['conditionsData', C(L(), 192)],
|
|
1834
1833
|
['feesCollectedA', A()],
|
|
1835
1834
|
['feesCollectedB', A()],
|
|
1836
1835
|
['liquidityIncreasedA', A()],
|
|
@@ -1843,11 +1842,11 @@ function Ps() {
|
|
|
1843
1842
|
[
|
|
1844
1843
|
'HarvestSwapAndReinvestPre',
|
|
1845
1844
|
E([
|
|
1846
|
-
['automation',
|
|
1847
|
-
['positionTokenAccount',
|
|
1848
|
-
['position',
|
|
1849
|
-
['automationIndex',
|
|
1850
|
-
['conditionsData', C(
|
|
1845
|
+
['automation', R()],
|
|
1846
|
+
['positionTokenAccount', R()],
|
|
1847
|
+
['position', R()],
|
|
1848
|
+
['automationIndex', I()],
|
|
1849
|
+
['conditionsData', C(L(), 192)],
|
|
1851
1850
|
['feesCollectedA', A()],
|
|
1852
1851
|
['feesCollectedB', A()],
|
|
1853
1852
|
]),
|
|
@@ -1855,9 +1854,9 @@ function Ps() {
|
|
|
1855
1854
|
[
|
|
1856
1855
|
'HarvestSwapAndReinvestPost',
|
|
1857
1856
|
E([
|
|
1858
|
-
['automation',
|
|
1859
|
-
['positionTokenAccount',
|
|
1860
|
-
['position',
|
|
1857
|
+
['automation', R()],
|
|
1858
|
+
['positionTokenAccount', R()],
|
|
1859
|
+
['position', R()],
|
|
1861
1860
|
['postSwapAmountA', A()],
|
|
1862
1861
|
['postSwapAmountB', A()],
|
|
1863
1862
|
['liquidityIncreasedA', A()],
|
|
@@ -1871,51 +1870,51 @@ function Ps() {
|
|
|
1871
1870
|
],
|
|
1872
1871
|
]);
|
|
1873
1872
|
}
|
|
1874
|
-
function
|
|
1875
|
-
return S(
|
|
1873
|
+
function ec() {
|
|
1874
|
+
return S(vs(), ps());
|
|
1876
1875
|
}
|
|
1877
|
-
function
|
|
1876
|
+
function tc(e, t) {
|
|
1878
1877
|
return Array.isArray(t) ? { __kind: e, fields: t } : { __kind: e, ...(t ?? {}) };
|
|
1879
1878
|
}
|
|
1880
|
-
function
|
|
1879
|
+
function nc(e, t) {
|
|
1881
1880
|
return t.__kind === e;
|
|
1882
1881
|
}
|
|
1883
|
-
var
|
|
1882
|
+
var xe = /* @__PURE__ */ ((e) => (
|
|
1884
1883
|
(e[(e.FundByCount = 0)] = 'FundByCount'),
|
|
1885
1884
|
(e[(e.FundByDuration = 1)] = 'FundByDuration'),
|
|
1886
1885
|
e
|
|
1887
|
-
))(
|
|
1886
|
+
))(xe || {});
|
|
1888
1887
|
function qt() {
|
|
1889
|
-
return ae(
|
|
1888
|
+
return ae(xe);
|
|
1890
1889
|
}
|
|
1891
1890
|
function Zt() {
|
|
1892
|
-
return ie(
|
|
1891
|
+
return ie(xe);
|
|
1893
1892
|
}
|
|
1894
|
-
function
|
|
1893
|
+
function rc() {
|
|
1895
1894
|
return S(qt(), Zt());
|
|
1896
1895
|
}
|
|
1897
1896
|
function Qt() {
|
|
1898
1897
|
return re([
|
|
1899
|
-
['FundByCount',
|
|
1900
|
-
['FundByDuration',
|
|
1898
|
+
['FundByCount', l([['count', V()]])],
|
|
1899
|
+
['FundByDuration', l([['durationSeconds', V()]])],
|
|
1901
1900
|
]);
|
|
1902
1901
|
}
|
|
1903
1902
|
function en() {
|
|
1904
1903
|
return oe([
|
|
1905
|
-
['FundByCount', E([['count',
|
|
1906
|
-
['FundByDuration', E([['durationSeconds',
|
|
1904
|
+
['FundByCount', E([['count', F()]])],
|
|
1905
|
+
['FundByDuration', E([['durationSeconds', F()]])],
|
|
1907
1906
|
]);
|
|
1908
1907
|
}
|
|
1909
|
-
function
|
|
1908
|
+
function oc() {
|
|
1910
1909
|
return S(Qt(), en());
|
|
1911
1910
|
}
|
|
1912
|
-
function
|
|
1911
|
+
function ac(e, t) {
|
|
1913
1912
|
return Array.isArray(t) ? { __kind: e, fields: t } : { __kind: e, ...(t ?? {}) };
|
|
1914
1913
|
}
|
|
1915
|
-
function
|
|
1914
|
+
function ic(e, t) {
|
|
1916
1915
|
return t.__kind === e;
|
|
1917
1916
|
}
|
|
1918
|
-
var
|
|
1917
|
+
var Me = /* @__PURE__ */ ((e) => (
|
|
1919
1918
|
(e[(e.TransferHookA = 0)] = 'TransferHookA'),
|
|
1920
1919
|
(e[(e.TransferHookB = 1)] = 'TransferHookB'),
|
|
1921
1920
|
(e[(e.TransferHookReward = 2)] = 'TransferHookReward'),
|
|
@@ -1926,155 +1925,155 @@ var xe = /* @__PURE__ */ ((e) => (
|
|
|
1926
1925
|
(e[(e.SupplementalTickArraysOne = 7)] = 'SupplementalTickArraysOne'),
|
|
1927
1926
|
(e[(e.SupplementalTickArraysTwo = 8)] = 'SupplementalTickArraysTwo'),
|
|
1928
1927
|
e
|
|
1929
|
-
))(
|
|
1928
|
+
))(Me || {});
|
|
1930
1929
|
function tn() {
|
|
1931
|
-
return ae(
|
|
1930
|
+
return ae(Me);
|
|
1932
1931
|
}
|
|
1933
1932
|
function nn() {
|
|
1934
|
-
return ie(
|
|
1933
|
+
return ie(Me);
|
|
1935
1934
|
}
|
|
1936
|
-
function
|
|
1935
|
+
function sc() {
|
|
1937
1936
|
return S(tn(), nn());
|
|
1938
1937
|
}
|
|
1939
|
-
function
|
|
1940
|
-
return
|
|
1938
|
+
function Ds() {
|
|
1939
|
+
return l([['slices', Ae(rn())]]);
|
|
1941
1940
|
}
|
|
1942
|
-
function
|
|
1941
|
+
function bs() {
|
|
1943
1942
|
return E([['slices', de(on())]]);
|
|
1944
1943
|
}
|
|
1945
|
-
function
|
|
1946
|
-
return S(
|
|
1944
|
+
function _c() {
|
|
1945
|
+
return S(Ds(), bs());
|
|
1947
1946
|
}
|
|
1948
1947
|
function rn() {
|
|
1949
|
-
return
|
|
1948
|
+
return l([
|
|
1950
1949
|
['accountsType', tn()],
|
|
1951
|
-
['length',
|
|
1950
|
+
['length', O()],
|
|
1952
1951
|
]);
|
|
1953
1952
|
}
|
|
1954
1953
|
function on() {
|
|
1955
1954
|
return E([
|
|
1956
1955
|
['accountsType', nn()],
|
|
1957
|
-
['length',
|
|
1956
|
+
['length', I()],
|
|
1958
1957
|
]);
|
|
1959
1958
|
}
|
|
1960
|
-
function
|
|
1959
|
+
function cc() {
|
|
1961
1960
|
return S(rn(), on());
|
|
1962
1961
|
}
|
|
1963
|
-
function
|
|
1962
|
+
function Us() {
|
|
1964
1963
|
return re([
|
|
1965
1964
|
[
|
|
1966
1965
|
'ByTokenAmounts',
|
|
1967
|
-
|
|
1968
|
-
['tokenMaxA',
|
|
1969
|
-
['tokenMaxB',
|
|
1970
|
-
['minSqrtPrice',
|
|
1971
|
-
['maxSqrtPrice',
|
|
1966
|
+
l([
|
|
1967
|
+
['tokenMaxA', u()],
|
|
1968
|
+
['tokenMaxB', u()],
|
|
1969
|
+
['minSqrtPrice', p()],
|
|
1970
|
+
['maxSqrtPrice', p()],
|
|
1972
1971
|
]),
|
|
1973
1972
|
],
|
|
1974
1973
|
]);
|
|
1975
1974
|
}
|
|
1976
|
-
function
|
|
1975
|
+
function Ps() {
|
|
1977
1976
|
return oe([
|
|
1978
1977
|
[
|
|
1979
1978
|
'ByTokenAmounts',
|
|
1980
1979
|
E([
|
|
1981
1980
|
['tokenMaxA', A()],
|
|
1982
1981
|
['tokenMaxB', A()],
|
|
1983
|
-
['minSqrtPrice',
|
|
1984
|
-
['maxSqrtPrice',
|
|
1982
|
+
['minSqrtPrice', D()],
|
|
1983
|
+
['maxSqrtPrice', D()],
|
|
1985
1984
|
]),
|
|
1986
1985
|
],
|
|
1987
1986
|
]);
|
|
1988
1987
|
}
|
|
1989
|
-
function
|
|
1990
|
-
return S(
|
|
1988
|
+
function Rc() {
|
|
1989
|
+
return S(Us(), Ps());
|
|
1991
1990
|
}
|
|
1992
|
-
function
|
|
1991
|
+
function uc(e, t) {
|
|
1993
1992
|
return Array.isArray(t) ? { __kind: e, fields: t } : { __kind: e, ...(t ?? {}) };
|
|
1994
1993
|
}
|
|
1995
|
-
function
|
|
1994
|
+
function Ac(e, t) {
|
|
1996
1995
|
return t.__kind === e;
|
|
1997
1996
|
}
|
|
1998
|
-
function
|
|
1999
|
-
return
|
|
2000
|
-
['discriminator',
|
|
1997
|
+
function ws() {
|
|
1998
|
+
return l([
|
|
1999
|
+
['discriminator', m(h(), 8)],
|
|
2001
2000
|
['whirlpool', c()],
|
|
2002
2001
|
['positionMint', c()],
|
|
2003
|
-
['liquidity',
|
|
2002
|
+
['liquidity', p()],
|
|
2004
2003
|
['tickLowerIndex', fe()],
|
|
2005
2004
|
['tickUpperIndex', fe()],
|
|
2006
|
-
['feeGrowthCheckpointA',
|
|
2007
|
-
['feeOwedA',
|
|
2008
|
-
['feeGrowthCheckpointB',
|
|
2009
|
-
['feeOwedB',
|
|
2005
|
+
['feeGrowthCheckpointA', p()],
|
|
2006
|
+
['feeOwedA', u()],
|
|
2007
|
+
['feeGrowthCheckpointB', p()],
|
|
2008
|
+
['feeOwedB', u()],
|
|
2010
2009
|
['rewardInfos', Ae(an(), { size: 3 })],
|
|
2011
2010
|
]);
|
|
2012
2011
|
}
|
|
2013
|
-
function
|
|
2012
|
+
function xs() {
|
|
2014
2013
|
return E([
|
|
2015
|
-
['discriminator', C(
|
|
2016
|
-
['whirlpool',
|
|
2017
|
-
['positionMint',
|
|
2018
|
-
['liquidity',
|
|
2014
|
+
['discriminator', C(L(), 8)],
|
|
2015
|
+
['whirlpool', R()],
|
|
2016
|
+
['positionMint', R()],
|
|
2017
|
+
['liquidity', D()],
|
|
2019
2018
|
['tickLowerIndex', Ie()],
|
|
2020
2019
|
['tickUpperIndex', Ie()],
|
|
2021
|
-
['feeGrowthCheckpointA',
|
|
2020
|
+
['feeGrowthCheckpointA', D()],
|
|
2022
2021
|
['feeOwedA', A()],
|
|
2023
|
-
['feeGrowthCheckpointB',
|
|
2022
|
+
['feeGrowthCheckpointB', D()],
|
|
2024
2023
|
['feeOwedB', A()],
|
|
2025
2024
|
['rewardInfos', de(sn(), { size: 3 })],
|
|
2026
2025
|
]);
|
|
2027
2026
|
}
|
|
2028
|
-
function
|
|
2029
|
-
return S(
|
|
2027
|
+
function dc() {
|
|
2028
|
+
return S(ws(), xs());
|
|
2030
2029
|
}
|
|
2031
2030
|
function an() {
|
|
2032
|
-
return
|
|
2033
|
-
['growthInsideCheckpoint',
|
|
2034
|
-
['amountOwed',
|
|
2031
|
+
return l([
|
|
2032
|
+
['growthInsideCheckpoint', p()],
|
|
2033
|
+
['amountOwed', u()],
|
|
2035
2034
|
]);
|
|
2036
2035
|
}
|
|
2037
2036
|
function sn() {
|
|
2038
2037
|
return E([
|
|
2039
|
-
['growthInsideCheckpoint',
|
|
2038
|
+
['growthInsideCheckpoint', D()],
|
|
2040
2039
|
['amountOwed', A()],
|
|
2041
2040
|
]);
|
|
2042
2041
|
}
|
|
2043
|
-
function
|
|
2042
|
+
function Oc() {
|
|
2044
2043
|
return S(an(), sn());
|
|
2045
2044
|
}
|
|
2046
|
-
function
|
|
2047
|
-
return
|
|
2045
|
+
function Ms() {
|
|
2046
|
+
return l([
|
|
2048
2047
|
['mint', c()],
|
|
2049
2048
|
['owner', c()],
|
|
2050
|
-
['amount',
|
|
2051
|
-
['delegateFlag',
|
|
2049
|
+
['amount', u()],
|
|
2050
|
+
['delegateFlag', V()],
|
|
2052
2051
|
['delegate', c()],
|
|
2053
2052
|
['state', _n()],
|
|
2054
|
-
['isNativeFlag',
|
|
2055
|
-
['nativeAmount',
|
|
2056
|
-
['delegateAmount',
|
|
2057
|
-
['closeAuthorityFlag',
|
|
2053
|
+
['isNativeFlag', V()],
|
|
2054
|
+
['nativeAmount', u()],
|
|
2055
|
+
['delegateAmount', u()],
|
|
2056
|
+
['closeAuthorityFlag', V()],
|
|
2058
2057
|
['closeAuthority', c()],
|
|
2059
2058
|
]);
|
|
2060
2059
|
}
|
|
2061
|
-
function
|
|
2060
|
+
function ys() {
|
|
2062
2061
|
return E([
|
|
2063
|
-
['mint',
|
|
2064
|
-
['owner',
|
|
2062
|
+
['mint', R()],
|
|
2063
|
+
['owner', R()],
|
|
2065
2064
|
['amount', A()],
|
|
2066
|
-
['delegateFlag',
|
|
2067
|
-
['delegate',
|
|
2065
|
+
['delegateFlag', F()],
|
|
2066
|
+
['delegate', R()],
|
|
2068
2067
|
['state', cn()],
|
|
2069
|
-
['isNativeFlag',
|
|
2068
|
+
['isNativeFlag', F()],
|
|
2070
2069
|
['nativeAmount', A()],
|
|
2071
2070
|
['delegateAmount', A()],
|
|
2072
|
-
['closeAuthorityFlag',
|
|
2073
|
-
['closeAuthority',
|
|
2071
|
+
['closeAuthorityFlag', F()],
|
|
2072
|
+
['closeAuthority', R()],
|
|
2074
2073
|
]);
|
|
2075
2074
|
}
|
|
2076
|
-
function
|
|
2077
|
-
return S(
|
|
2075
|
+
function lc() {
|
|
2076
|
+
return S(Ms(), ys());
|
|
2078
2077
|
}
|
|
2079
2078
|
var ye = /* @__PURE__ */ ((e) => (
|
|
2080
2079
|
(e[(e.Uninitialized = 0)] = 'Uninitialized'),
|
|
@@ -2088,234 +2087,234 @@ function _n() {
|
|
|
2088
2087
|
function cn() {
|
|
2089
2088
|
return ie(ye);
|
|
2090
2089
|
}
|
|
2091
|
-
function
|
|
2090
|
+
function Ec() {
|
|
2092
2091
|
return S(_n(), cn());
|
|
2093
2092
|
}
|
|
2094
|
-
function
|
|
2095
|
-
return
|
|
2096
|
-
['mintAuthorityFlag',
|
|
2093
|
+
function ks() {
|
|
2094
|
+
return l([
|
|
2095
|
+
['mintAuthorityFlag', V()],
|
|
2097
2096
|
['mintAuthority', c()],
|
|
2098
|
-
['supply',
|
|
2099
|
-
['decimals',
|
|
2097
|
+
['supply', u()],
|
|
2098
|
+
['decimals', O()],
|
|
2100
2099
|
['isInitialized', yt()],
|
|
2101
|
-
['freezeAuthorityFlag',
|
|
2100
|
+
['freezeAuthorityFlag', V()],
|
|
2102
2101
|
['freezeAuthority', c()],
|
|
2103
2102
|
]);
|
|
2104
2103
|
}
|
|
2105
|
-
function
|
|
2104
|
+
function Bs() {
|
|
2106
2105
|
return E([
|
|
2107
|
-
['mintAuthorityFlag',
|
|
2108
|
-
['mintAuthority',
|
|
2106
|
+
['mintAuthorityFlag', F()],
|
|
2107
|
+
['mintAuthority', R()],
|
|
2109
2108
|
['supply', A()],
|
|
2110
|
-
['decimals',
|
|
2109
|
+
['decimals', I()],
|
|
2111
2110
|
['isInitialized', kt()],
|
|
2112
|
-
['freezeAuthorityFlag',
|
|
2113
|
-
['freezeAuthority',
|
|
2111
|
+
['freezeAuthorityFlag', F()],
|
|
2112
|
+
['freezeAuthority', R()],
|
|
2114
2113
|
]);
|
|
2115
2114
|
}
|
|
2116
|
-
function
|
|
2117
|
-
return S(
|
|
2115
|
+
function Nc() {
|
|
2116
|
+
return S(ks(), Bs());
|
|
2118
2117
|
}
|
|
2119
|
-
function
|
|
2118
|
+
function Rn() {
|
|
2120
2119
|
return re([
|
|
2121
|
-
['UpdateCrankRewardDefault',
|
|
2122
|
-
['UpdateGlobalConfigAuthority',
|
|
2120
|
+
['UpdateCrankRewardDefault', l([['newCrankRewardDefault', u()]])],
|
|
2121
|
+
['UpdateGlobalConfigAuthority', l([['newAuthority', c()]])],
|
|
2123
2122
|
]);
|
|
2124
2123
|
}
|
|
2125
|
-
function
|
|
2124
|
+
function un() {
|
|
2126
2125
|
return oe([
|
|
2127
2126
|
['UpdateCrankRewardDefault', E([['newCrankRewardDefault', A()]])],
|
|
2128
|
-
['UpdateGlobalConfigAuthority', E([['newAuthority',
|
|
2127
|
+
['UpdateGlobalConfigAuthority', E([['newAuthority', R()]])],
|
|
2129
2128
|
]);
|
|
2130
2129
|
}
|
|
2131
|
-
function
|
|
2132
|
-
return S(
|
|
2130
|
+
function Tc() {
|
|
2131
|
+
return S(Rn(), un());
|
|
2133
2132
|
}
|
|
2134
|
-
function
|
|
2133
|
+
function Sc(e, t) {
|
|
2135
2134
|
return Array.isArray(t) ? { __kind: e, fields: t } : { __kind: e, ...(t ?? {}) };
|
|
2136
2135
|
}
|
|
2137
|
-
function
|
|
2136
|
+
function fc(e, t) {
|
|
2138
2137
|
return t.__kind === e;
|
|
2139
2138
|
}
|
|
2140
|
-
function
|
|
2141
|
-
return
|
|
2142
|
-
['discriminator',
|
|
2139
|
+
function Gs() {
|
|
2140
|
+
return l([
|
|
2141
|
+
['discriminator', m(h(), 8)],
|
|
2143
2142
|
['whirlpoolsConfig', c()],
|
|
2144
|
-
['whirlpoolBump',
|
|
2143
|
+
['whirlpoolBump', m(h(), 1)],
|
|
2145
2144
|
['tickSpacing', Ne()],
|
|
2146
|
-
['feeTierIndexSeed',
|
|
2145
|
+
['feeTierIndexSeed', m(h(), 2)],
|
|
2147
2146
|
['feeRate', Ne()],
|
|
2148
2147
|
['protocolFeeRate', Ne()],
|
|
2149
|
-
['liquidity',
|
|
2150
|
-
['sqrtPrice',
|
|
2148
|
+
['liquidity', p()],
|
|
2149
|
+
['sqrtPrice', p()],
|
|
2151
2150
|
['tickCurrentIndex', fe()],
|
|
2152
|
-
['protocolFeeOwedA',
|
|
2153
|
-
['protocolFeeOwedB',
|
|
2151
|
+
['protocolFeeOwedA', u()],
|
|
2152
|
+
['protocolFeeOwedB', u()],
|
|
2154
2153
|
['tokenMintA', c()],
|
|
2155
2154
|
['tokenVaultA', c()],
|
|
2156
|
-
['feeGrowthGlobalA',
|
|
2155
|
+
['feeGrowthGlobalA', p()],
|
|
2157
2156
|
['tokenMintB', c()],
|
|
2158
2157
|
['tokenVaultB', c()],
|
|
2159
|
-
['feeGrowthGlobalB',
|
|
2160
|
-
['rewardLastUpdatedTimestamp',
|
|
2158
|
+
['feeGrowthGlobalB', p()],
|
|
2159
|
+
['rewardLastUpdatedTimestamp', u()],
|
|
2161
2160
|
['rewardInfos', Ae(An(), { size: 3 })],
|
|
2162
2161
|
]);
|
|
2163
2162
|
}
|
|
2164
|
-
function
|
|
2163
|
+
function Vs() {
|
|
2165
2164
|
return E([
|
|
2166
|
-
['discriminator', C(
|
|
2167
|
-
['whirlpoolsConfig',
|
|
2168
|
-
['whirlpoolBump', C(
|
|
2165
|
+
['discriminator', C(L(), 8)],
|
|
2166
|
+
['whirlpoolsConfig', R()],
|
|
2167
|
+
['whirlpoolBump', C(L(), 1)],
|
|
2169
2168
|
['tickSpacing', Te()],
|
|
2170
|
-
['feeTierIndexSeed', C(
|
|
2169
|
+
['feeTierIndexSeed', C(L(), 2)],
|
|
2171
2170
|
['feeRate', Te()],
|
|
2172
2171
|
['protocolFeeRate', Te()],
|
|
2173
|
-
['liquidity',
|
|
2174
|
-
['sqrtPrice',
|
|
2172
|
+
['liquidity', D()],
|
|
2173
|
+
['sqrtPrice', D()],
|
|
2175
2174
|
['tickCurrentIndex', Ie()],
|
|
2176
2175
|
['protocolFeeOwedA', A()],
|
|
2177
2176
|
['protocolFeeOwedB', A()],
|
|
2178
|
-
['tokenMintA',
|
|
2179
|
-
['tokenVaultA',
|
|
2180
|
-
['feeGrowthGlobalA',
|
|
2181
|
-
['tokenMintB',
|
|
2182
|
-
['tokenVaultB',
|
|
2183
|
-
['feeGrowthGlobalB',
|
|
2177
|
+
['tokenMintA', R()],
|
|
2178
|
+
['tokenVaultA', R()],
|
|
2179
|
+
['feeGrowthGlobalA', D()],
|
|
2180
|
+
['tokenMintB', R()],
|
|
2181
|
+
['tokenVaultB', R()],
|
|
2182
|
+
['feeGrowthGlobalB', D()],
|
|
2184
2183
|
['rewardLastUpdatedTimestamp', A()],
|
|
2185
2184
|
['rewardInfos', de(dn(), { size: 3 })],
|
|
2186
2185
|
]);
|
|
2187
2186
|
}
|
|
2188
|
-
function
|
|
2189
|
-
return S(
|
|
2187
|
+
function Ic() {
|
|
2188
|
+
return S(Gs(), Vs());
|
|
2190
2189
|
}
|
|
2191
2190
|
function An() {
|
|
2192
|
-
return
|
|
2191
|
+
return l([
|
|
2193
2192
|
['mint', c()],
|
|
2194
2193
|
['vault', c()],
|
|
2195
|
-
['extension',
|
|
2196
|
-
['emissionsPerSecondX64',
|
|
2197
|
-
['growthGlobalX64',
|
|
2194
|
+
['extension', m(h(), 32)],
|
|
2195
|
+
['emissionsPerSecondX64', p()],
|
|
2196
|
+
['growthGlobalX64', p()],
|
|
2198
2197
|
]);
|
|
2199
2198
|
}
|
|
2200
2199
|
function dn() {
|
|
2201
2200
|
return E([
|
|
2202
|
-
['mint',
|
|
2203
|
-
['vault',
|
|
2204
|
-
['extension', C(
|
|
2205
|
-
['emissionsPerSecondX64',
|
|
2206
|
-
['growthGlobalX64',
|
|
2201
|
+
['mint', R()],
|
|
2202
|
+
['vault', R()],
|
|
2203
|
+
['extension', C(L(), 32)],
|
|
2204
|
+
['emissionsPerSecondX64', D()],
|
|
2205
|
+
['growthGlobalX64', D()],
|
|
2207
2206
|
]);
|
|
2208
2207
|
}
|
|
2209
|
-
function
|
|
2208
|
+
function gc() {
|
|
2210
2209
|
return S(An(), dn());
|
|
2211
2210
|
}
|
|
2212
|
-
function
|
|
2213
|
-
return
|
|
2214
|
-
['discriminator',
|
|
2211
|
+
function Fs() {
|
|
2212
|
+
return l([
|
|
2213
|
+
['discriminator', Ue()],
|
|
2215
2214
|
['positionTokenAccount', c()],
|
|
2216
|
-
['actionData',
|
|
2217
|
-
['automationIndex',
|
|
2218
|
-
['conditionsData',
|
|
2219
|
-
['bump',
|
|
2220
|
-
['authorityBump',
|
|
2221
|
-
['padding',
|
|
2222
|
-
['crankReward',
|
|
2215
|
+
['actionData', m(h(), 64)],
|
|
2216
|
+
['automationIndex', O()],
|
|
2217
|
+
['conditionsData', m(h(), 192)],
|
|
2218
|
+
['bump', O()],
|
|
2219
|
+
['authorityBump', O()],
|
|
2220
|
+
['padding', m(h(), 4)],
|
|
2221
|
+
['crankReward', u()],
|
|
2223
2222
|
['automationTokenAccountA', c()],
|
|
2224
2223
|
['automationTokenAccountB', c()],
|
|
2225
2224
|
['tokenMintA', c()],
|
|
2226
2225
|
['tokenMintB', c()],
|
|
2227
2226
|
['owner', c()],
|
|
2228
2227
|
['position', c()],
|
|
2229
|
-
['reserved',
|
|
2228
|
+
['reserved', m(h(), 272)],
|
|
2230
2229
|
]);
|
|
2231
2230
|
}
|
|
2232
|
-
function
|
|
2231
|
+
function On() {
|
|
2233
2232
|
return E([
|
|
2234
|
-
['discriminator',
|
|
2235
|
-
['positionTokenAccount',
|
|
2236
|
-
['actionData', C(
|
|
2237
|
-
['automationIndex',
|
|
2238
|
-
['conditionsData', C(
|
|
2239
|
-
['bump',
|
|
2240
|
-
['authorityBump',
|
|
2241
|
-
['padding', C(
|
|
2233
|
+
['discriminator', Pe()],
|
|
2234
|
+
['positionTokenAccount', R()],
|
|
2235
|
+
['actionData', C(L(), 64)],
|
|
2236
|
+
['automationIndex', I()],
|
|
2237
|
+
['conditionsData', C(L(), 192)],
|
|
2238
|
+
['bump', I()],
|
|
2239
|
+
['authorityBump', I()],
|
|
2240
|
+
['padding', C(L(), 4)],
|
|
2242
2241
|
['crankReward', A()],
|
|
2243
|
-
['automationTokenAccountA',
|
|
2244
|
-
['automationTokenAccountB',
|
|
2245
|
-
['tokenMintA',
|
|
2246
|
-
['tokenMintB',
|
|
2247
|
-
['owner',
|
|
2248
|
-
['position',
|
|
2249
|
-
['reserved', C(
|
|
2242
|
+
['automationTokenAccountA', R()],
|
|
2243
|
+
['automationTokenAccountB', R()],
|
|
2244
|
+
['tokenMintA', R()],
|
|
2245
|
+
['tokenMintB', R()],
|
|
2246
|
+
['owner', R()],
|
|
2247
|
+
['position', R()],
|
|
2248
|
+
['reserved', C(L(), 272)],
|
|
2250
2249
|
]);
|
|
2251
2250
|
}
|
|
2252
|
-
function
|
|
2253
|
-
return S(
|
|
2251
|
+
function mc() {
|
|
2252
|
+
return S(Fs(), On());
|
|
2254
2253
|
}
|
|
2255
|
-
function
|
|
2256
|
-
return
|
|
2254
|
+
function ln(e) {
|
|
2255
|
+
return Lt(e, On());
|
|
2257
2256
|
}
|
|
2258
|
-
async function
|
|
2259
|
-
const o = await
|
|
2257
|
+
async function Cc(e, t, n) {
|
|
2258
|
+
const o = await zs(e, t, n);
|
|
2260
2259
|
return (bt(o), o);
|
|
2261
2260
|
}
|
|
2262
|
-
async function
|
|
2261
|
+
async function zs(e, t, n) {
|
|
2263
2262
|
const o = await pt(e, t, n);
|
|
2264
|
-
return
|
|
2263
|
+
return ln(o);
|
|
2265
2264
|
}
|
|
2266
|
-
async function
|
|
2267
|
-
const o = await
|
|
2268
|
-
return (
|
|
2265
|
+
async function hc(e, t, n) {
|
|
2266
|
+
const o = await Hs(e, t, n);
|
|
2267
|
+
return (Ut(o), o);
|
|
2269
2268
|
}
|
|
2270
|
-
async function
|
|
2271
|
-
return (await Dt(e, t, n)).map((r) =>
|
|
2269
|
+
async function Hs(e, t, n) {
|
|
2270
|
+
return (await Dt(e, t, n)).map((r) => ln(r));
|
|
2272
2271
|
}
|
|
2273
|
-
function
|
|
2274
|
-
return
|
|
2275
|
-
['discriminator',
|
|
2276
|
-
['bump',
|
|
2277
|
-
['padding',
|
|
2272
|
+
function Ws() {
|
|
2273
|
+
return l([
|
|
2274
|
+
['discriminator', Ue()],
|
|
2275
|
+
['bump', O()],
|
|
2276
|
+
['padding', m(h(), 6)],
|
|
2278
2277
|
['globalConfigAuthority', c()],
|
|
2279
|
-
['crankRewardDefault',
|
|
2280
|
-
['reserved',
|
|
2278
|
+
['crankRewardDefault', u()],
|
|
2279
|
+
['reserved', m(h(), 976)],
|
|
2281
2280
|
]);
|
|
2282
2281
|
}
|
|
2283
2282
|
function En() {
|
|
2284
2283
|
return E([
|
|
2285
|
-
['discriminator',
|
|
2286
|
-
['bump',
|
|
2287
|
-
['padding', C(
|
|
2288
|
-
['globalConfigAuthority',
|
|
2284
|
+
['discriminator', Pe()],
|
|
2285
|
+
['bump', I()],
|
|
2286
|
+
['padding', C(L(), 6)],
|
|
2287
|
+
['globalConfigAuthority', R()],
|
|
2289
2288
|
['crankRewardDefault', A()],
|
|
2290
|
-
['reserved', C(
|
|
2289
|
+
['reserved', C(L(), 976)],
|
|
2291
2290
|
]);
|
|
2292
2291
|
}
|
|
2293
|
-
function
|
|
2294
|
-
return S(
|
|
2292
|
+
function Lc() {
|
|
2293
|
+
return S(Ws(), En());
|
|
2295
2294
|
}
|
|
2296
2295
|
function Nn(e) {
|
|
2297
|
-
return
|
|
2296
|
+
return Lt(e, En());
|
|
2298
2297
|
}
|
|
2299
|
-
async function
|
|
2300
|
-
const o = await
|
|
2298
|
+
async function vc(e, t, n) {
|
|
2299
|
+
const o = await $s(e, t, n);
|
|
2301
2300
|
return (bt(o), o);
|
|
2302
2301
|
}
|
|
2303
|
-
async function
|
|
2302
|
+
async function $s(e, t, n) {
|
|
2304
2303
|
const o = await pt(e, t, n);
|
|
2305
2304
|
return Nn(o);
|
|
2306
2305
|
}
|
|
2307
|
-
async function
|
|
2308
|
-
const o = await
|
|
2309
|
-
return (
|
|
2306
|
+
async function pc(e, t, n) {
|
|
2307
|
+
const o = await Xs(e, t, n);
|
|
2308
|
+
return (Ut(o), o);
|
|
2310
2309
|
}
|
|
2311
|
-
async function
|
|
2310
|
+
async function Xs(e, t, n) {
|
|
2312
2311
|
return (await Dt(e, t, n)).map((r) => Nn(r));
|
|
2313
2312
|
}
|
|
2314
|
-
function
|
|
2313
|
+
function Ys(e) {
|
|
2315
2314
|
if (!e) throw new Error('Expected a Address.');
|
|
2316
2315
|
return typeof e == 'object' && 'address' in e ? e.address : Array.isArray(e) ? e[0] : e;
|
|
2317
2316
|
}
|
|
2318
|
-
function
|
|
2317
|
+
function Z(e, t) {
|
|
2319
2318
|
return (n) => {
|
|
2320
2319
|
if (!n.value)
|
|
2321
2320
|
return Object.freeze({
|
|
@@ -2324,25 +2323,25 @@ function j(e, t) {
|
|
|
2324
2323
|
});
|
|
2325
2324
|
const o = n.isWritable ? ce.WRITABLE : ce.READONLY;
|
|
2326
2325
|
return Object.freeze({
|
|
2327
|
-
address:
|
|
2328
|
-
role: Ye(n.value) ?
|
|
2326
|
+
address: Ys(n.value),
|
|
2327
|
+
role: Ye(n.value) ? Ss(o) : o,
|
|
2329
2328
|
...(Ye(n.value) ? { signer: n.value } : {}),
|
|
2330
2329
|
});
|
|
2331
2330
|
};
|
|
2332
2331
|
}
|
|
2333
2332
|
function Ye(e) {
|
|
2334
|
-
return !!e && typeof e == 'object' && 'address' in e &&
|
|
2333
|
+
return !!e && typeof e == 'object' && 'address' in e && Cs(e);
|
|
2335
2334
|
}
|
|
2336
2335
|
const Tn = 2;
|
|
2337
|
-
function
|
|
2338
|
-
return
|
|
2336
|
+
function Dc() {
|
|
2337
|
+
return O().encode(Tn);
|
|
2339
2338
|
}
|
|
2340
2339
|
function Sn() {
|
|
2341
2340
|
return b(
|
|
2342
|
-
|
|
2343
|
-
['discriminator',
|
|
2341
|
+
l([
|
|
2342
|
+
['discriminator', O()],
|
|
2344
2343
|
['action', Yt()],
|
|
2345
|
-
['automationIndex',
|
|
2344
|
+
['automationIndex', O()],
|
|
2346
2345
|
['conditions', Ae(jt(), { size: 3 })],
|
|
2347
2346
|
]),
|
|
2348
2347
|
(e) => ({ ...e, discriminator: Tn })
|
|
@@ -2350,17 +2349,17 @@ function Sn() {
|
|
|
2350
2349
|
}
|
|
2351
2350
|
function fn() {
|
|
2352
2351
|
return E([
|
|
2353
|
-
['discriminator',
|
|
2352
|
+
['discriminator', I()],
|
|
2354
2353
|
['action', Kt()],
|
|
2355
|
-
['automationIndex',
|
|
2354
|
+
['automationIndex', I()],
|
|
2356
2355
|
['conditions', de(Jt(), { size: 3 })],
|
|
2357
2356
|
]);
|
|
2358
2357
|
}
|
|
2359
|
-
function
|
|
2358
|
+
function bc() {
|
|
2360
2359
|
return S(Sn(), fn());
|
|
2361
2360
|
}
|
|
2362
|
-
function
|
|
2363
|
-
const n = (t == null ? void 0 : t.programAddress) ??
|
|
2361
|
+
function Uc(e, t) {
|
|
2362
|
+
const n = (t == null ? void 0 : t.programAddress) ?? U,
|
|
2364
2363
|
r = {
|
|
2365
2364
|
positionOwner: { value: e.positionOwner ?? null, isWritable: !0 },
|
|
2366
2365
|
automation: { value: e.automation ?? null, isWritable: !0 },
|
|
@@ -2386,32 +2385,32 @@ function yc(e, t) {
|
|
|
2386
2385
|
systemProgram: { value: e.systemProgram ?? null, isWritable: !1 },
|
|
2387
2386
|
ataProgram: { value: e.ataProgram ?? null, isWritable: !1 },
|
|
2388
2387
|
},
|
|
2389
|
-
|
|
2388
|
+
a = { ...e };
|
|
2390
2389
|
(r.systemProgram.value || (r.systemProgram.value = '11111111111111111111111111111111'),
|
|
2391
2390
|
r.ataProgram.value || (r.ataProgram.value = 'ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL'));
|
|
2392
|
-
const
|
|
2391
|
+
const i = Z(n);
|
|
2393
2392
|
return Object.freeze({
|
|
2394
2393
|
accounts: [
|
|
2395
|
-
|
|
2396
|
-
|
|
2397
|
-
|
|
2398
|
-
|
|
2399
|
-
|
|
2400
|
-
|
|
2401
|
-
|
|
2402
|
-
|
|
2403
|
-
|
|
2404
|
-
|
|
2405
|
-
|
|
2406
|
-
|
|
2407
|
-
|
|
2408
|
-
|
|
2394
|
+
i(r.positionOwner),
|
|
2395
|
+
i(r.automation),
|
|
2396
|
+
i(r.automationTokenAccountA),
|
|
2397
|
+
i(r.automationTokenAccountB),
|
|
2398
|
+
i(r.position),
|
|
2399
|
+
i(r.positionTokenAccount),
|
|
2400
|
+
i(r.whirlpool),
|
|
2401
|
+
i(r.globalConfig),
|
|
2402
|
+
i(r.tokenMintA),
|
|
2403
|
+
i(r.tokenMintB),
|
|
2404
|
+
i(r.tokenProgramA),
|
|
2405
|
+
i(r.tokenProgramB),
|
|
2406
|
+
i(r.systemProgram),
|
|
2407
|
+
i(r.ataProgram),
|
|
2409
2408
|
],
|
|
2410
|
-
data: Sn().encode(
|
|
2409
|
+
data: Sn().encode(a),
|
|
2411
2410
|
programAddress: n,
|
|
2412
2411
|
});
|
|
2413
2412
|
}
|
|
2414
|
-
function
|
|
2413
|
+
function Ks(e) {
|
|
2415
2414
|
if (e.accounts.length < 14) throw new Error('Not enough accounts');
|
|
2416
2415
|
let t = 0;
|
|
2417
2416
|
const n = () => {
|
|
@@ -2440,44 +2439,44 @@ function qs(e) {
|
|
|
2440
2439
|
};
|
|
2441
2440
|
}
|
|
2442
2441
|
const In = 4;
|
|
2443
|
-
function
|
|
2444
|
-
return
|
|
2442
|
+
function Pc() {
|
|
2443
|
+
return O().encode(In);
|
|
2445
2444
|
}
|
|
2446
|
-
function
|
|
2445
|
+
function gn() {
|
|
2447
2446
|
return b(
|
|
2448
|
-
|
|
2449
|
-
['discriminator',
|
|
2447
|
+
l([
|
|
2448
|
+
['discriminator', O()],
|
|
2450
2449
|
['instructionData', Qt()],
|
|
2451
2450
|
]),
|
|
2452
2451
|
(e) => ({ ...e, discriminator: In })
|
|
2453
2452
|
);
|
|
2454
2453
|
}
|
|
2455
|
-
function
|
|
2454
|
+
function mn() {
|
|
2456
2455
|
return E([
|
|
2457
|
-
['discriminator',
|
|
2456
|
+
['discriminator', I()],
|
|
2458
2457
|
['instructionData', en()],
|
|
2459
2458
|
]);
|
|
2460
2459
|
}
|
|
2461
|
-
function
|
|
2462
|
-
return S(
|
|
2460
|
+
function wc() {
|
|
2461
|
+
return S(gn(), mn());
|
|
2463
2462
|
}
|
|
2464
|
-
function
|
|
2465
|
-
const n = (t == null ? void 0 : t.programAddress) ??
|
|
2463
|
+
function xc(e, t) {
|
|
2464
|
+
const n = (t == null ? void 0 : t.programAddress) ?? U,
|
|
2466
2465
|
r = {
|
|
2467
2466
|
payer: { value: e.payer ?? null, isWritable: !0 },
|
|
2468
2467
|
automation: { value: e.automation ?? null, isWritable: !0 },
|
|
2469
2468
|
systemProgram: { value: e.systemProgram ?? null, isWritable: !1 },
|
|
2470
2469
|
},
|
|
2471
|
-
|
|
2470
|
+
a = { ...e };
|
|
2472
2471
|
r.systemProgram.value || (r.systemProgram.value = '11111111111111111111111111111111');
|
|
2473
|
-
const
|
|
2472
|
+
const i = Z(n);
|
|
2474
2473
|
return Object.freeze({
|
|
2475
|
-
accounts: [
|
|
2476
|
-
data:
|
|
2474
|
+
accounts: [i(r.payer), i(r.automation), i(r.systemProgram)],
|
|
2475
|
+
data: gn().encode(a),
|
|
2477
2476
|
programAddress: n,
|
|
2478
2477
|
});
|
|
2479
2478
|
}
|
|
2480
|
-
function
|
|
2479
|
+
function js(e) {
|
|
2481
2480
|
if (e.accounts.length < 3) throw new Error('Not enough accounts');
|
|
2482
2481
|
let t = 0;
|
|
2483
2482
|
const n = () => {
|
|
@@ -2491,19 +2490,19 @@ function Zs(e) {
|
|
|
2491
2490
|
automation: n(),
|
|
2492
2491
|
systemProgram: n(),
|
|
2493
2492
|
},
|
|
2494
|
-
data:
|
|
2493
|
+
data: mn().decode(e.data),
|
|
2495
2494
|
};
|
|
2496
2495
|
}
|
|
2497
|
-
const Cn =
|
|
2498
|
-
function
|
|
2499
|
-
return
|
|
2496
|
+
const Cn = 6;
|
|
2497
|
+
function Mc() {
|
|
2498
|
+
return O().encode(Cn);
|
|
2500
2499
|
}
|
|
2501
2500
|
function hn() {
|
|
2502
2501
|
return b(
|
|
2503
|
-
|
|
2504
|
-
['discriminator',
|
|
2505
|
-
['minSqrtPrice',
|
|
2506
|
-
['maxSqrtPrice',
|
|
2502
|
+
l([
|
|
2503
|
+
['discriminator', O()],
|
|
2504
|
+
['minSqrtPrice', p()],
|
|
2505
|
+
['maxSqrtPrice', p()],
|
|
2507
2506
|
]),
|
|
2508
2507
|
(e) => ({
|
|
2509
2508
|
...e,
|
|
@@ -2511,164 +2510,18 @@ function hn() {
|
|
|
2511
2510
|
})
|
|
2512
2511
|
);
|
|
2513
2512
|
}
|
|
2514
|
-
function
|
|
2515
|
-
return E([
|
|
2516
|
-
['discriminator', f()],
|
|
2517
|
-
['minSqrtPrice', p()],
|
|
2518
|
-
['maxSqrtPrice', p()],
|
|
2519
|
-
]);
|
|
2520
|
-
}
|
|
2521
|
-
function Fc() {
|
|
2522
|
-
return S(hn(), vn());
|
|
2523
|
-
}
|
|
2524
|
-
function zc(e, t) {
|
|
2525
|
-
const n = (t == null ? void 0 : t.programAddress) ?? P,
|
|
2526
|
-
r = {
|
|
2527
|
-
crankOperator: { value: e.crankOperator ?? null, isWritable: !0 },
|
|
2528
|
-
automation: { value: e.automation ?? null, isWritable: !0 },
|
|
2529
|
-
automationTokenAccountA: {
|
|
2530
|
-
value: e.automationTokenAccountA ?? null,
|
|
2531
|
-
isWritable: !0,
|
|
2532
|
-
},
|
|
2533
|
-
automationTokenAccountB: {
|
|
2534
|
-
value: e.automationTokenAccountB ?? null,
|
|
2535
|
-
isWritable: !0,
|
|
2536
|
-
},
|
|
2537
|
-
automationAuthority: {
|
|
2538
|
-
value: e.automationAuthority ?? null,
|
|
2539
|
-
isWritable: !1,
|
|
2540
|
-
},
|
|
2541
|
-
automationAuthorityTokenAccountA: {
|
|
2542
|
-
value: e.automationAuthorityTokenAccountA ?? null,
|
|
2543
|
-
isWritable: !0,
|
|
2544
|
-
},
|
|
2545
|
-
automationAuthorityTokenAccountB: {
|
|
2546
|
-
value: e.automationAuthorityTokenAccountB ?? null,
|
|
2547
|
-
isWritable: !0,
|
|
2548
|
-
},
|
|
2549
|
-
positionTokenAccount: {
|
|
2550
|
-
value: e.positionTokenAccount ?? null,
|
|
2551
|
-
isWritable: !1,
|
|
2552
|
-
},
|
|
2553
|
-
position: { value: e.position ?? null, isWritable: !0 },
|
|
2554
|
-
positionOwner: { value: e.positionOwner ?? null, isWritable: !1 },
|
|
2555
|
-
whirlpool: { value: e.whirlpool ?? null, isWritable: !0 },
|
|
2556
|
-
systemProgram: { value: e.systemProgram ?? null, isWritable: !1 },
|
|
2557
|
-
tokenMintA: { value: e.tokenMintA ?? null, isWritable: !0 },
|
|
2558
|
-
tokenMintB: { value: e.tokenMintB ?? null, isWritable: !0 },
|
|
2559
|
-
tokenVaultA: { value: e.tokenVaultA ?? null, isWritable: !0 },
|
|
2560
|
-
tokenVaultB: { value: e.tokenVaultB ?? null, isWritable: !0 },
|
|
2561
|
-
tokenProgramA: { value: e.tokenProgramA ?? null, isWritable: !1 },
|
|
2562
|
-
tokenProgramB: { value: e.tokenProgramB ?? null, isWritable: !1 },
|
|
2563
|
-
memoProgram: { value: e.memoProgram ?? null, isWritable: !1 },
|
|
2564
|
-
tickArrayLower: { value: e.tickArrayLower ?? null, isWritable: !0 },
|
|
2565
|
-
tickArrayUpper: { value: e.tickArrayUpper ?? null, isWritable: !0 },
|
|
2566
|
-
whirlpoolProgram: {
|
|
2567
|
-
value: e.whirlpoolProgram ?? null,
|
|
2568
|
-
isWritable: !1,
|
|
2569
|
-
},
|
|
2570
|
-
ataProgram: { value: e.ataProgram ?? null, isWritable: !1 },
|
|
2571
|
-
},
|
|
2572
|
-
i = { ...e };
|
|
2573
|
-
(r.systemProgram.value || (r.systemProgram.value = '11111111111111111111111111111111'),
|
|
2574
|
-
r.ataProgram.value || (r.ataProgram.value = 'ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL'));
|
|
2575
|
-
const a = j(n);
|
|
2576
|
-
return Object.freeze({
|
|
2577
|
-
accounts: [
|
|
2578
|
-
a(r.crankOperator),
|
|
2579
|
-
a(r.automation),
|
|
2580
|
-
a(r.automationTokenAccountA),
|
|
2581
|
-
a(r.automationTokenAccountB),
|
|
2582
|
-
a(r.automationAuthority),
|
|
2583
|
-
a(r.automationAuthorityTokenAccountA),
|
|
2584
|
-
a(r.automationAuthorityTokenAccountB),
|
|
2585
|
-
a(r.positionTokenAccount),
|
|
2586
|
-
a(r.position),
|
|
2587
|
-
a(r.positionOwner),
|
|
2588
|
-
a(r.whirlpool),
|
|
2589
|
-
a(r.systemProgram),
|
|
2590
|
-
a(r.tokenMintA),
|
|
2591
|
-
a(r.tokenMintB),
|
|
2592
|
-
a(r.tokenVaultA),
|
|
2593
|
-
a(r.tokenVaultB),
|
|
2594
|
-
a(r.tokenProgramA),
|
|
2595
|
-
a(r.tokenProgramB),
|
|
2596
|
-
a(r.memoProgram),
|
|
2597
|
-
a(r.tickArrayLower),
|
|
2598
|
-
a(r.tickArrayUpper),
|
|
2599
|
-
a(r.whirlpoolProgram),
|
|
2600
|
-
a(r.ataProgram),
|
|
2601
|
-
],
|
|
2602
|
-
data: hn().encode(i),
|
|
2603
|
-
programAddress: n,
|
|
2604
|
-
});
|
|
2605
|
-
}
|
|
2606
|
-
function Qs(e) {
|
|
2607
|
-
if (e.accounts.length < 23) throw new Error('Not enough accounts');
|
|
2608
|
-
let t = 0;
|
|
2609
|
-
const n = () => {
|
|
2610
|
-
const o = e.accounts[t];
|
|
2611
|
-
return ((t += 1), o);
|
|
2612
|
-
};
|
|
2613
|
-
return {
|
|
2614
|
-
programAddress: e.programAddress,
|
|
2615
|
-
accounts: {
|
|
2616
|
-
crankOperator: n(),
|
|
2617
|
-
automation: n(),
|
|
2618
|
-
automationTokenAccountA: n(),
|
|
2619
|
-
automationTokenAccountB: n(),
|
|
2620
|
-
automationAuthority: n(),
|
|
2621
|
-
automationAuthorityTokenAccountA: n(),
|
|
2622
|
-
automationAuthorityTokenAccountB: n(),
|
|
2623
|
-
positionTokenAccount: n(),
|
|
2624
|
-
position: n(),
|
|
2625
|
-
positionOwner: n(),
|
|
2626
|
-
whirlpool: n(),
|
|
2627
|
-
systemProgram: n(),
|
|
2628
|
-
tokenMintA: n(),
|
|
2629
|
-
tokenMintB: n(),
|
|
2630
|
-
tokenVaultA: n(),
|
|
2631
|
-
tokenVaultB: n(),
|
|
2632
|
-
tokenProgramA: n(),
|
|
2633
|
-
tokenProgramB: n(),
|
|
2634
|
-
memoProgram: n(),
|
|
2635
|
-
tickArrayLower: n(),
|
|
2636
|
-
tickArrayUpper: n(),
|
|
2637
|
-
whirlpoolProgram: n(),
|
|
2638
|
-
ataProgram: n(),
|
|
2639
|
-
},
|
|
2640
|
-
data: vn().decode(e.data),
|
|
2641
|
-
};
|
|
2642
|
-
}
|
|
2643
|
-
const Ln = 7;
|
|
2644
|
-
function Hc() {
|
|
2645
|
-
return d().encode(Ln);
|
|
2646
|
-
}
|
|
2647
|
-
function pn() {
|
|
2648
|
-
return b(
|
|
2649
|
-
O([
|
|
2650
|
-
['discriminator', d()],
|
|
2651
|
-
['minSqrtPrice', L()],
|
|
2652
|
-
['maxSqrtPrice', L()],
|
|
2653
|
-
]),
|
|
2654
|
-
(e) => ({
|
|
2655
|
-
...e,
|
|
2656
|
-
discriminator: Ln,
|
|
2657
|
-
})
|
|
2658
|
-
);
|
|
2659
|
-
}
|
|
2660
|
-
function Dn() {
|
|
2513
|
+
function Ln() {
|
|
2661
2514
|
return E([
|
|
2662
|
-
['discriminator',
|
|
2663
|
-
['minSqrtPrice',
|
|
2664
|
-
['maxSqrtPrice',
|
|
2515
|
+
['discriminator', I()],
|
|
2516
|
+
['minSqrtPrice', D()],
|
|
2517
|
+
['maxSqrtPrice', D()],
|
|
2665
2518
|
]);
|
|
2666
2519
|
}
|
|
2667
|
-
function
|
|
2668
|
-
return S(
|
|
2520
|
+
function yc() {
|
|
2521
|
+
return S(hn(), Ln());
|
|
2669
2522
|
}
|
|
2670
|
-
function
|
|
2671
|
-
const n = (t == null ? void 0 : t.programAddress) ??
|
|
2523
|
+
function kc(e, t) {
|
|
2524
|
+
const n = (t == null ? void 0 : t.programAddress) ?? U,
|
|
2672
2525
|
r = {
|
|
2673
2526
|
crankOperator: { value: e.crankOperator ?? null, isWritable: !0 },
|
|
2674
2527
|
crankOperatorTokenAccountA: {
|
|
@@ -2717,40 +2570,40 @@ function $c(e, t) {
|
|
|
2717
2570
|
isWritable: !1,
|
|
2718
2571
|
},
|
|
2719
2572
|
},
|
|
2720
|
-
|
|
2573
|
+
a = { ...e };
|
|
2721
2574
|
r.instructionsSysvar.value ||
|
|
2722
2575
|
(r.instructionsSysvar.value = 'Sysvar1nstructions1111111111111111111111111');
|
|
2723
|
-
const
|
|
2576
|
+
const i = Z(n);
|
|
2724
2577
|
return Object.freeze({
|
|
2725
2578
|
accounts: [
|
|
2726
|
-
|
|
2727
|
-
|
|
2728
|
-
|
|
2729
|
-
|
|
2730
|
-
|
|
2731
|
-
|
|
2732
|
-
|
|
2733
|
-
|
|
2734
|
-
|
|
2735
|
-
|
|
2736
|
-
|
|
2737
|
-
|
|
2738
|
-
|
|
2739
|
-
|
|
2740
|
-
|
|
2741
|
-
|
|
2742
|
-
|
|
2743
|
-
|
|
2744
|
-
|
|
2745
|
-
|
|
2746
|
-
|
|
2747
|
-
|
|
2579
|
+
i(r.crankOperator),
|
|
2580
|
+
i(r.crankOperatorTokenAccountA),
|
|
2581
|
+
i(r.crankOperatorTokenAccountB),
|
|
2582
|
+
i(r.automation),
|
|
2583
|
+
i(r.automationTokenAccountA),
|
|
2584
|
+
i(r.automationTokenAccountB),
|
|
2585
|
+
i(r.automationAuthority),
|
|
2586
|
+
i(r.positionTokenAccount),
|
|
2587
|
+
i(r.position),
|
|
2588
|
+
i(r.positionOwner),
|
|
2589
|
+
i(r.whirlpool),
|
|
2590
|
+
i(r.tokenMintA),
|
|
2591
|
+
i(r.tokenMintB),
|
|
2592
|
+
i(r.tokenVaultA),
|
|
2593
|
+
i(r.tokenVaultB),
|
|
2594
|
+
i(r.tokenProgramA),
|
|
2595
|
+
i(r.tokenProgramB),
|
|
2596
|
+
i(r.memoProgram),
|
|
2597
|
+
i(r.tickArrayLower),
|
|
2598
|
+
i(r.tickArrayUpper),
|
|
2599
|
+
i(r.whirlpoolProgram),
|
|
2600
|
+
i(r.instructionsSysvar),
|
|
2748
2601
|
],
|
|
2749
|
-
data:
|
|
2602
|
+
data: hn().encode(a),
|
|
2750
2603
|
programAddress: n,
|
|
2751
2604
|
});
|
|
2752
2605
|
}
|
|
2753
|
-
function
|
|
2606
|
+
function Js(e) {
|
|
2754
2607
|
if (e.accounts.length < 22) throw new Error('Not enough accounts');
|
|
2755
2608
|
let t = 0;
|
|
2756
2609
|
const n = () => {
|
|
@@ -2783,27 +2636,27 @@ function e_(e) {
|
|
|
2783
2636
|
whirlpoolProgram: n(),
|
|
2784
2637
|
instructionsSysvar: n(),
|
|
2785
2638
|
},
|
|
2786
|
-
data:
|
|
2639
|
+
data: Ln().decode(e.data),
|
|
2787
2640
|
};
|
|
2788
2641
|
}
|
|
2789
|
-
const
|
|
2790
|
-
function
|
|
2791
|
-
return
|
|
2642
|
+
const vn = 5;
|
|
2643
|
+
function Bc() {
|
|
2644
|
+
return O().encode(vn);
|
|
2792
2645
|
}
|
|
2793
|
-
function
|
|
2794
|
-
return b(
|
|
2646
|
+
function pn() {
|
|
2647
|
+
return b(l([['discriminator', O()]]), (e) => ({
|
|
2795
2648
|
...e,
|
|
2796
|
-
discriminator:
|
|
2649
|
+
discriminator: vn,
|
|
2797
2650
|
}));
|
|
2798
2651
|
}
|
|
2799
|
-
function
|
|
2800
|
-
return E([['discriminator',
|
|
2652
|
+
function Dn() {
|
|
2653
|
+
return E([['discriminator', I()]]);
|
|
2801
2654
|
}
|
|
2802
|
-
function
|
|
2803
|
-
return S(
|
|
2655
|
+
function Gc() {
|
|
2656
|
+
return S(pn(), Dn());
|
|
2804
2657
|
}
|
|
2805
|
-
function
|
|
2806
|
-
const n = (t == null ? void 0 : t.programAddress) ??
|
|
2658
|
+
function Vc(e, t) {
|
|
2659
|
+
const n = (t == null ? void 0 : t.programAddress) ?? U,
|
|
2807
2660
|
r = {
|
|
2808
2661
|
crankOperator: { value: e.crankOperator ?? null, isWritable: !0 },
|
|
2809
2662
|
crankOperatorTokenAccountA: {
|
|
@@ -2849,36 +2702,36 @@ function Kc(e, t) {
|
|
|
2849
2702
|
(r.instructionsSysvar.value = 'Sysvar1nstructions1111111111111111111111111'),
|
|
2850
2703
|
r.systemProgram.value || (r.systemProgram.value = '11111111111111111111111111111111'),
|
|
2851
2704
|
r.ataProgram.value || (r.ataProgram.value = 'ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL'));
|
|
2852
|
-
const
|
|
2705
|
+
const a = Z(n);
|
|
2853
2706
|
return Object.freeze({
|
|
2854
2707
|
accounts: [
|
|
2855
|
-
|
|
2856
|
-
|
|
2857
|
-
|
|
2858
|
-
|
|
2859
|
-
|
|
2860
|
-
|
|
2861
|
-
|
|
2862
|
-
|
|
2863
|
-
|
|
2864
|
-
|
|
2865
|
-
|
|
2866
|
-
|
|
2867
|
-
|
|
2868
|
-
|
|
2869
|
-
|
|
2870
|
-
|
|
2871
|
-
|
|
2872
|
-
|
|
2873
|
-
|
|
2874
|
-
|
|
2875
|
-
|
|
2708
|
+
a(r.crankOperator),
|
|
2709
|
+
a(r.crankOperatorTokenAccountA),
|
|
2710
|
+
a(r.crankOperatorTokenAccountB),
|
|
2711
|
+
a(r.automation),
|
|
2712
|
+
a(r.automationAuthority),
|
|
2713
|
+
a(r.positionTokenAccount),
|
|
2714
|
+
a(r.position),
|
|
2715
|
+
a(r.whirlpool),
|
|
2716
|
+
a(r.tokenMintA),
|
|
2717
|
+
a(r.tokenMintB),
|
|
2718
|
+
a(r.tokenVaultA),
|
|
2719
|
+
a(r.tokenVaultB),
|
|
2720
|
+
a(r.tokenProgramA),
|
|
2721
|
+
a(r.tokenProgramB),
|
|
2722
|
+
a(r.memoProgram),
|
|
2723
|
+
a(r.tickArrayLower),
|
|
2724
|
+
a(r.tickArrayUpper),
|
|
2725
|
+
a(r.whirlpoolProgram),
|
|
2726
|
+
a(r.instructionsSysvar),
|
|
2727
|
+
a(r.systemProgram),
|
|
2728
|
+
a(r.ataProgram),
|
|
2876
2729
|
],
|
|
2877
|
-
data:
|
|
2730
|
+
data: pn().encode({}),
|
|
2878
2731
|
programAddress: n,
|
|
2879
2732
|
});
|
|
2880
2733
|
}
|
|
2881
|
-
function
|
|
2734
|
+
function qs(e) {
|
|
2882
2735
|
if (e.accounts.length < 21) throw new Error('Not enough accounts');
|
|
2883
2736
|
let t = 0;
|
|
2884
2737
|
const n = () => {
|
|
@@ -2910,53 +2763,53 @@ function t_(e) {
|
|
|
2910
2763
|
systemProgram: n(),
|
|
2911
2764
|
ataProgram: n(),
|
|
2912
2765
|
},
|
|
2913
|
-
data:
|
|
2766
|
+
data: Dn().decode(e.data),
|
|
2914
2767
|
};
|
|
2915
2768
|
}
|
|
2916
|
-
const
|
|
2917
|
-
function
|
|
2918
|
-
return
|
|
2769
|
+
const bn = 0;
|
|
2770
|
+
function Fc() {
|
|
2771
|
+
return O().encode(bn);
|
|
2919
2772
|
}
|
|
2920
|
-
function
|
|
2773
|
+
function Un() {
|
|
2921
2774
|
return b(
|
|
2922
|
-
|
|
2923
|
-
['discriminator',
|
|
2775
|
+
l([
|
|
2776
|
+
['discriminator', O()],
|
|
2924
2777
|
['globalConfigAuthority', c()],
|
|
2925
|
-
['crankRewardDefault',
|
|
2778
|
+
['crankRewardDefault', u()],
|
|
2926
2779
|
]),
|
|
2927
2780
|
(e) => ({
|
|
2928
2781
|
...e,
|
|
2929
|
-
discriminator:
|
|
2782
|
+
discriminator: bn,
|
|
2930
2783
|
})
|
|
2931
2784
|
);
|
|
2932
2785
|
}
|
|
2933
|
-
function
|
|
2786
|
+
function Pn() {
|
|
2934
2787
|
return E([
|
|
2935
|
-
['discriminator',
|
|
2936
|
-
['globalConfigAuthority',
|
|
2788
|
+
['discriminator', I()],
|
|
2789
|
+
['globalConfigAuthority', R()],
|
|
2937
2790
|
['crankRewardDefault', A()],
|
|
2938
2791
|
]);
|
|
2939
2792
|
}
|
|
2940
|
-
function
|
|
2941
|
-
return S(
|
|
2793
|
+
function zc() {
|
|
2794
|
+
return S(Un(), Pn());
|
|
2942
2795
|
}
|
|
2943
|
-
function
|
|
2944
|
-
const n = (t == null ? void 0 : t.programAddress) ??
|
|
2796
|
+
function Hc(e, t) {
|
|
2797
|
+
const n = (t == null ? void 0 : t.programAddress) ?? U,
|
|
2945
2798
|
r = {
|
|
2946
2799
|
deployer: { value: e.deployer ?? null, isWritable: !0 },
|
|
2947
2800
|
globalConfig: { value: e.globalConfig ?? null, isWritable: !0 },
|
|
2948
2801
|
systemProgram: { value: e.systemProgram ?? null, isWritable: !1 },
|
|
2949
2802
|
},
|
|
2950
|
-
|
|
2803
|
+
a = { ...e };
|
|
2951
2804
|
r.systemProgram.value || (r.systemProgram.value = '11111111111111111111111111111111');
|
|
2952
|
-
const
|
|
2805
|
+
const i = Z(n);
|
|
2953
2806
|
return Object.freeze({
|
|
2954
|
-
accounts: [
|
|
2955
|
-
data:
|
|
2807
|
+
accounts: [i(r.deployer), i(r.globalConfig), i(r.systemProgram)],
|
|
2808
|
+
data: Un().encode(a),
|
|
2956
2809
|
programAddress: n,
|
|
2957
2810
|
});
|
|
2958
2811
|
}
|
|
2959
|
-
function
|
|
2812
|
+
function Zs(e) {
|
|
2960
2813
|
if (e.accounts.length < 3) throw new Error('Not enough accounts');
|
|
2961
2814
|
let t = 0;
|
|
2962
2815
|
const n = () => {
|
|
@@ -2970,24 +2823,24 @@ function n_(e) {
|
|
|
2970
2823
|
globalConfig: n(),
|
|
2971
2824
|
systemProgram: n(),
|
|
2972
2825
|
},
|
|
2973
|
-
data:
|
|
2826
|
+
data: Pn().decode(e.data),
|
|
2974
2827
|
};
|
|
2975
2828
|
}
|
|
2976
|
-
const
|
|
2977
|
-
function
|
|
2978
|
-
return
|
|
2829
|
+
const wn = 3;
|
|
2830
|
+
function Wc() {
|
|
2831
|
+
return O().encode(wn);
|
|
2979
2832
|
}
|
|
2980
|
-
function
|
|
2981
|
-
return b(
|
|
2833
|
+
function xn() {
|
|
2834
|
+
return b(l([['discriminator', O()]]), (e) => ({ ...e, discriminator: wn }));
|
|
2982
2835
|
}
|
|
2983
|
-
function
|
|
2984
|
-
return E([['discriminator',
|
|
2836
|
+
function Mn() {
|
|
2837
|
+
return E([['discriminator', I()]]);
|
|
2985
2838
|
}
|
|
2986
|
-
function
|
|
2987
|
-
return S(
|
|
2839
|
+
function $c() {
|
|
2840
|
+
return S(xn(), Mn());
|
|
2988
2841
|
}
|
|
2989
|
-
function
|
|
2990
|
-
const n = (t == null ? void 0 : t.programAddress) ??
|
|
2842
|
+
function Xc(e, t) {
|
|
2843
|
+
const n = (t == null ? void 0 : t.programAddress) ?? U,
|
|
2991
2844
|
r = {
|
|
2992
2845
|
positionOwner: { value: e.positionOwner ?? null, isWritable: !0 },
|
|
2993
2846
|
positionOwnerTokenAccountA: {
|
|
@@ -3011,25 +2864,25 @@ function eu(e, t) {
|
|
|
3011
2864
|
};
|
|
3012
2865
|
(r.systemProgram.value || (r.systemProgram.value = '11111111111111111111111111111111'),
|
|
3013
2866
|
r.ataProgram.value || (r.ataProgram.value = 'ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL'));
|
|
3014
|
-
const
|
|
2867
|
+
const a = Z(n);
|
|
3015
2868
|
return Object.freeze({
|
|
3016
2869
|
accounts: [
|
|
3017
|
-
|
|
3018
|
-
|
|
3019
|
-
|
|
3020
|
-
|
|
3021
|
-
|
|
3022
|
-
|
|
3023
|
-
|
|
3024
|
-
|
|
3025
|
-
|
|
3026
|
-
|
|
2870
|
+
a(r.positionOwner),
|
|
2871
|
+
a(r.positionOwnerTokenAccountA),
|
|
2872
|
+
a(r.positionOwnerTokenAccountB),
|
|
2873
|
+
a(r.positionTokenAccount),
|
|
2874
|
+
a(r.tokenMintA),
|
|
2875
|
+
a(r.tokenMintB),
|
|
2876
|
+
a(r.tokenProgramA),
|
|
2877
|
+
a(r.tokenProgramB),
|
|
2878
|
+
a(r.systemProgram),
|
|
2879
|
+
a(r.ataProgram),
|
|
3027
2880
|
],
|
|
3028
|
-
data:
|
|
2881
|
+
data: xn().encode({}),
|
|
3029
2882
|
programAddress: n,
|
|
3030
2883
|
});
|
|
3031
2884
|
}
|
|
3032
|
-
function
|
|
2885
|
+
function Qs(e) {
|
|
3033
2886
|
if (e.accounts.length < 10) throw new Error('Not enough accounts');
|
|
3034
2887
|
let t = 0;
|
|
3035
2888
|
const n = () => {
|
|
@@ -3050,36 +2903,36 @@ function r_(e) {
|
|
|
3050
2903
|
systemProgram: n(),
|
|
3051
2904
|
ataProgram: n(),
|
|
3052
2905
|
},
|
|
3053
|
-
data:
|
|
2906
|
+
data: Mn().decode(e.data),
|
|
3054
2907
|
};
|
|
3055
2908
|
}
|
|
3056
|
-
const
|
|
3057
|
-
function
|
|
3058
|
-
return
|
|
2909
|
+
const yn = 1;
|
|
2910
|
+
function Yc() {
|
|
2911
|
+
return O().encode(yn);
|
|
3059
2912
|
}
|
|
3060
|
-
function
|
|
2913
|
+
function kn() {
|
|
3061
2914
|
return b(
|
|
3062
|
-
|
|
3063
|
-
['discriminator',
|
|
3064
|
-
['instructionData',
|
|
2915
|
+
l([
|
|
2916
|
+
['discriminator', O()],
|
|
2917
|
+
['instructionData', Rn()],
|
|
3065
2918
|
]),
|
|
3066
2919
|
(e) => ({
|
|
3067
2920
|
...e,
|
|
3068
|
-
discriminator:
|
|
2921
|
+
discriminator: yn,
|
|
3069
2922
|
})
|
|
3070
2923
|
);
|
|
3071
2924
|
}
|
|
3072
|
-
function
|
|
2925
|
+
function Bn() {
|
|
3073
2926
|
return E([
|
|
3074
|
-
['discriminator',
|
|
3075
|
-
['instructionData',
|
|
2927
|
+
['discriminator', I()],
|
|
2928
|
+
['instructionData', un()],
|
|
3076
2929
|
]);
|
|
3077
2930
|
}
|
|
3078
|
-
function
|
|
3079
|
-
return S(
|
|
2931
|
+
function Kc() {
|
|
2932
|
+
return S(kn(), Bn());
|
|
3080
2933
|
}
|
|
3081
|
-
function
|
|
3082
|
-
const n = (t == null ? void 0 : t.programAddress) ??
|
|
2934
|
+
function jc(e, t) {
|
|
2935
|
+
const n = (t == null ? void 0 : t.programAddress) ?? U,
|
|
3083
2936
|
r = {
|
|
3084
2937
|
globalConfigAuthority: {
|
|
3085
2938
|
value: e.globalConfigAuthority ?? null,
|
|
@@ -3087,15 +2940,15 @@ function ru(e, t) {
|
|
|
3087
2940
|
},
|
|
3088
2941
|
globalConfig: { value: e.globalConfig ?? null, isWritable: !0 },
|
|
3089
2942
|
},
|
|
3090
|
-
|
|
3091
|
-
|
|
2943
|
+
a = { ...e },
|
|
2944
|
+
i = Z(n);
|
|
3092
2945
|
return Object.freeze({
|
|
3093
|
-
accounts: [
|
|
3094
|
-
data:
|
|
2946
|
+
accounts: [i(r.globalConfigAuthority), i(r.globalConfig)],
|
|
2947
|
+
data: kn().encode(a),
|
|
3095
2948
|
programAddress: n,
|
|
3096
2949
|
});
|
|
3097
2950
|
}
|
|
3098
|
-
function
|
|
2951
|
+
function e_(e) {
|
|
3099
2952
|
if (e.accounts.length < 2) throw new Error('Not enough accounts');
|
|
3100
2953
|
let t = 0;
|
|
3101
2954
|
const n = () => {
|
|
@@ -3108,202 +2961,190 @@ function o_(e) {
|
|
|
3108
2961
|
globalConfigAuthority: n(),
|
|
3109
2962
|
globalConfig: n(),
|
|
3110
2963
|
},
|
|
3111
|
-
data:
|
|
2964
|
+
data: Bn().decode(e.data),
|
|
3112
2965
|
};
|
|
3113
2966
|
}
|
|
3114
|
-
const
|
|
3115
|
-
var
|
|
2967
|
+
const U = 'wpAutoU2kNC95CB9SzvSRmhC52ncPabVY225e3pfQA8';
|
|
2968
|
+
var t_ = /* @__PURE__ */ ((e) => (
|
|
3116
2969
|
(e[(e.Automation = 0)] = 'Automation'),
|
|
3117
2970
|
(e[(e.GlobalConfig = 1)] = 'GlobalConfig'),
|
|
3118
2971
|
e
|
|
3119
|
-
))(
|
|
3120
|
-
|
|
2972
|
+
))(t_ || {}),
|
|
2973
|
+
n_ = /* @__PURE__ */ ((e) => (
|
|
3121
2974
|
(e[(e.InitializeGlobalConfig = 0)] = 'InitializeGlobalConfig'),
|
|
3122
2975
|
(e[(e.UpdateGlobalConfig = 1)] = 'UpdateGlobalConfig'),
|
|
3123
2976
|
(e[(e.CreateAutomation = 2)] = 'CreateAutomation'),
|
|
3124
2977
|
(e[(e.RemoveAutomations = 3)] = 'RemoveAutomations'),
|
|
3125
2978
|
(e[(e.FundAutomation = 4)] = 'FundAutomation'),
|
|
3126
|
-
(e[(e.
|
|
3127
|
-
(e[(e.
|
|
3128
|
-
(e[(e.HarvestSwapAndReinvestPost = 7)] = 'HarvestSwapAndReinvestPost'),
|
|
2979
|
+
(e[(e.HarvestSwapAndReinvestPre = 5)] = 'HarvestSwapAndReinvestPre'),
|
|
2980
|
+
(e[(e.HarvestSwapAndReinvestPost = 6)] = 'HarvestSwapAndReinvestPost'),
|
|
3129
2981
|
e
|
|
3130
|
-
))(
|
|
3131
|
-
function
|
|
2982
|
+
))(n_ || {});
|
|
2983
|
+
function r_(e) {
|
|
3132
2984
|
const t = 'data' in e ? e.data : e;
|
|
3133
|
-
if (
|
|
3134
|
-
if (
|
|
3135
|
-
if (
|
|
3136
|
-
if (
|
|
3137
|
-
if (
|
|
3138
|
-
if (
|
|
3139
|
-
if (
|
|
3140
|
-
if (V(t, d().encode(7), 0)) return 7;
|
|
2985
|
+
if (H(t, O().encode(0), 0)) return 0;
|
|
2986
|
+
if (H(t, O().encode(1), 0)) return 1;
|
|
2987
|
+
if (H(t, O().encode(2), 0)) return 2;
|
|
2988
|
+
if (H(t, O().encode(3), 0)) return 3;
|
|
2989
|
+
if (H(t, O().encode(4), 0)) return 4;
|
|
2990
|
+
if (H(t, O().encode(5), 0)) return 5;
|
|
2991
|
+
if (H(t, O().encode(6), 0)) return 6;
|
|
3141
2992
|
throw new Error(
|
|
3142
2993
|
'The provided instruction could not be identified as a whirlpoolsAutomationProgram instruction.'
|
|
3143
2994
|
);
|
|
3144
2995
|
}
|
|
3145
|
-
function
|
|
3146
|
-
const t =
|
|
2996
|
+
function Jc(e) {
|
|
2997
|
+
const t = r_(e);
|
|
3147
2998
|
switch (t) {
|
|
3148
2999
|
case 0:
|
|
3149
3000
|
return (
|
|
3150
|
-
|
|
3001
|
+
K(e),
|
|
3151
3002
|
{
|
|
3152
3003
|
instructionType: 0,
|
|
3153
|
-
...
|
|
3004
|
+
...Zs(e),
|
|
3154
3005
|
}
|
|
3155
3006
|
);
|
|
3156
3007
|
case 1:
|
|
3157
3008
|
return (
|
|
3158
|
-
|
|
3009
|
+
K(e),
|
|
3159
3010
|
{
|
|
3160
3011
|
instructionType: 1,
|
|
3161
|
-
...
|
|
3012
|
+
...e_(e),
|
|
3162
3013
|
}
|
|
3163
3014
|
);
|
|
3164
3015
|
case 2:
|
|
3165
3016
|
return (
|
|
3166
|
-
|
|
3017
|
+
K(e),
|
|
3167
3018
|
{
|
|
3168
3019
|
instructionType: 2,
|
|
3169
|
-
...
|
|
3020
|
+
...Ks(e),
|
|
3170
3021
|
}
|
|
3171
3022
|
);
|
|
3172
3023
|
case 3:
|
|
3173
3024
|
return (
|
|
3174
|
-
|
|
3025
|
+
K(e),
|
|
3175
3026
|
{
|
|
3176
3027
|
instructionType: 3,
|
|
3177
|
-
...
|
|
3028
|
+
...Qs(e),
|
|
3178
3029
|
}
|
|
3179
3030
|
);
|
|
3180
3031
|
case 4:
|
|
3181
3032
|
return (
|
|
3182
|
-
|
|
3033
|
+
K(e),
|
|
3183
3034
|
{
|
|
3184
3035
|
instructionType: 4,
|
|
3185
|
-
...
|
|
3036
|
+
...js(e),
|
|
3186
3037
|
}
|
|
3187
3038
|
);
|
|
3188
3039
|
case 5:
|
|
3189
3040
|
return (
|
|
3190
|
-
|
|
3041
|
+
K(e),
|
|
3191
3042
|
{
|
|
3192
3043
|
instructionType: 5,
|
|
3193
|
-
...
|
|
3044
|
+
...qs(e),
|
|
3194
3045
|
}
|
|
3195
3046
|
);
|
|
3196
3047
|
case 6:
|
|
3197
3048
|
return (
|
|
3198
|
-
|
|
3049
|
+
K(e),
|
|
3199
3050
|
{
|
|
3200
3051
|
instructionType: 6,
|
|
3201
|
-
...
|
|
3202
|
-
}
|
|
3203
|
-
);
|
|
3204
|
-
case 7:
|
|
3205
|
-
return (
|
|
3206
|
-
$(e),
|
|
3207
|
-
{
|
|
3208
|
-
instructionType: 7,
|
|
3209
|
-
...e_(e),
|
|
3052
|
+
...Js(e),
|
|
3210
3053
|
}
|
|
3211
3054
|
);
|
|
3212
3055
|
default:
|
|
3213
3056
|
throw new Error(`Unrecognized instruction type: ${t}`);
|
|
3214
3057
|
}
|
|
3215
3058
|
}
|
|
3216
|
-
const
|
|
3217
|
-
|
|
3218
|
-
|
|
3219
|
-
|
|
3220
|
-
|
|
3221
|
-
|
|
3222
|
-
|
|
3223
|
-
|
|
3224
|
-
|
|
3225
|
-
|
|
3226
|
-
|
|
3227
|
-
|
|
3228
|
-
|
|
3229
|
-
|
|
3230
|
-
|
|
3231
|
-
|
|
3232
|
-
|
|
3233
|
-
|
|
3234
|
-
|
|
3235
|
-
|
|
3236
|
-
|
|
3237
|
-
|
|
3238
|
-
|
|
3239
|
-
|
|
3240
|
-
|
|
3241
|
-
|
|
3242
|
-
|
|
3243
|
-
|
|
3244
|
-
|
|
3245
|
-
|
|
3246
|
-
|
|
3247
|
-
|
|
3248
|
-
|
|
3249
|
-
let zn;
|
|
3059
|
+
const o_ = 6e3,
|
|
3060
|
+
a_ = 6001,
|
|
3061
|
+
i_ = 6002,
|
|
3062
|
+
s_ = 6003,
|
|
3063
|
+
__ = 6004,
|
|
3064
|
+
c_ = 6005,
|
|
3065
|
+
R_ = 6006,
|
|
3066
|
+
u_ = 6007,
|
|
3067
|
+
A_ = 6008,
|
|
3068
|
+
d_ = 6009,
|
|
3069
|
+
O_ = 6010,
|
|
3070
|
+
l_ = 6011,
|
|
3071
|
+
E_ = 6012,
|
|
3072
|
+
N_ = 6013,
|
|
3073
|
+
T_ = 6014,
|
|
3074
|
+
S_ = 6015,
|
|
3075
|
+
f_ = 6016,
|
|
3076
|
+
I_ = 6017,
|
|
3077
|
+
g_ = 6018,
|
|
3078
|
+
m_ = 6019,
|
|
3079
|
+
C_ = 6020,
|
|
3080
|
+
h_ = 6021,
|
|
3081
|
+
L_ = 6022,
|
|
3082
|
+
v_ = 6023,
|
|
3083
|
+
p_ = 6024,
|
|
3084
|
+
D_ = 6025,
|
|
3085
|
+
b_ = 6026,
|
|
3086
|
+
U_ = 6027,
|
|
3087
|
+
P_ = 6028,
|
|
3088
|
+
w_ = 6029,
|
|
3089
|
+
x_ = 6030,
|
|
3090
|
+
M_ = 6031;
|
|
3091
|
+
let Gn;
|
|
3250
3092
|
process.env.NODE_ENV !== 'production' &&
|
|
3251
|
-
(
|
|
3252
|
-
[
|
|
3253
|
-
[
|
|
3254
|
-
[
|
|
3255
|
-
[
|
|
3256
|
-
[
|
|
3257
|
-
[
|
|
3258
|
-
[
|
|
3259
|
-
[
|
|
3260
|
-
[
|
|
3261
|
-
[
|
|
3262
|
-
[
|
|
3263
|
-
[
|
|
3264
|
-
[
|
|
3265
|
-
[
|
|
3266
|
-
[
|
|
3267
|
-
[
|
|
3268
|
-
[
|
|
3269
|
-
[
|
|
3270
|
-
[
|
|
3271
|
-
[
|
|
3272
|
-
[
|
|
3273
|
-
[
|
|
3274
|
-
[
|
|
3275
|
-
[
|
|
3276
|
-
[
|
|
3277
|
-
[
|
|
3278
|
-
[
|
|
3279
|
-
[
|
|
3280
|
-
[
|
|
3281
|
-
[
|
|
3282
|
-
[
|
|
3283
|
-
[
|
|
3284
|
-
[V_]: 'Unsupported token extension',
|
|
3093
|
+
(Gn = {
|
|
3094
|
+
[d_]: 'Account already initialized',
|
|
3095
|
+
[O_]: 'Account not initialized',
|
|
3096
|
+
[g_]: 'Arithmetic error',
|
|
3097
|
+
[h_]: 'Condition violation',
|
|
3098
|
+
[A_]: 'Emit event error',
|
|
3099
|
+
[R_]: 'Invalid account address',
|
|
3100
|
+
[__]: 'Incorrect owner',
|
|
3101
|
+
[a_]: 'Incorrect program id',
|
|
3102
|
+
[b_]: 'Insufficient funds to pay crank reward',
|
|
3103
|
+
[P_]: 'Insufficient instruction count after this instruction',
|
|
3104
|
+
[U_]: 'Insufficient instruction count before this instruction',
|
|
3105
|
+
[w_]: 'Invalid accompanying instruction',
|
|
3106
|
+
[u_]: 'Invalid account data',
|
|
3107
|
+
[s_]: 'Invalid account role',
|
|
3108
|
+
[E_]: 'Invalid action',
|
|
3109
|
+
[S_]: 'Invalid action data length',
|
|
3110
|
+
[C_]: 'Invalid amount to fund automation',
|
|
3111
|
+
[I_]: 'Invalid automation action',
|
|
3112
|
+
[T_]: 'Invalid automation_index',
|
|
3113
|
+
[N_]: 'Invalid condition',
|
|
3114
|
+
[f_]: 'Invalid condition data length',
|
|
3115
|
+
[L_]: 'Invalid accounts for CPI',
|
|
3116
|
+
[v_]: 'Invalid instruction data for CPI',
|
|
3117
|
+
[p_]: 'Invalid crank reward',
|
|
3118
|
+
[m_]: 'Invalid next valid exection timestamp condition',
|
|
3119
|
+
[l_]: 'Position token amount must be 1',
|
|
3120
|
+
[x_]: 'Invalid remaining accounts length',
|
|
3121
|
+
[c_]: 'Invalid seeds',
|
|
3122
|
+
[i_]: 'Not enough account keys',
|
|
3123
|
+
[D_]: 'Redundant global config update',
|
|
3124
|
+
[o_]: 'Unknown instruction discriminator',
|
|
3125
|
+
[M_]: 'Unsupported token extension',
|
|
3285
3126
|
});
|
|
3286
|
-
function
|
|
3127
|
+
function qc(e) {
|
|
3287
3128
|
return process.env.NODE_ENV !== 'production'
|
|
3288
|
-
?
|
|
3129
|
+
? Gn[e]
|
|
3289
3130
|
: 'Error message not available in production bundles.';
|
|
3290
3131
|
}
|
|
3291
|
-
function
|
|
3292
|
-
return
|
|
3132
|
+
function Zc(e, t, n) {
|
|
3133
|
+
return fs(e, t, U, n);
|
|
3293
3134
|
}
|
|
3294
|
-
const
|
|
3135
|
+
const Qc = 64;
|
|
3295
3136
|
/*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) */
|
|
3296
|
-
function
|
|
3137
|
+
function y_(e) {
|
|
3297
3138
|
return e instanceof Uint8Array || (ArrayBuffer.isView(e) && e.constructor.name === 'Uint8Array');
|
|
3298
3139
|
}
|
|
3299
|
-
function
|
|
3300
|
-
const o =
|
|
3140
|
+
function Vn(e, t, n = '') {
|
|
3141
|
+
const o = y_(e),
|
|
3301
3142
|
r = e == null ? void 0 : e.length;
|
|
3302
3143
|
if (!o || t !== void 0) {
|
|
3303
|
-
const
|
|
3144
|
+
const i = n && `"${n}" `,
|
|
3304
3145
|
s = '',
|
|
3305
3146
|
_ = o ? `length=${r}` : `type=${typeof e}`;
|
|
3306
|
-
throw new Error(
|
|
3147
|
+
throw new Error(i + 'expected Uint8Array' + s + ', got ' + _);
|
|
3307
3148
|
}
|
|
3308
3149
|
return e;
|
|
3309
3150
|
}
|
|
@@ -3311,8 +3152,8 @@ function Ke(e, t = !0) {
|
|
|
3311
3152
|
if (e.destroyed) throw new Error('Hash instance has been destroyed');
|
|
3312
3153
|
if (t && e.finished) throw new Error('Hash#digest() has already been called');
|
|
3313
3154
|
}
|
|
3314
|
-
function
|
|
3315
|
-
|
|
3155
|
+
function k_(e, t) {
|
|
3156
|
+
Vn(e, void 0, 'digestInto() output');
|
|
3316
3157
|
const n = t.outputLen;
|
|
3317
3158
|
if (e.length < n) throw new Error('"digestInto() output" expected to be of length >=' + n);
|
|
3318
3159
|
}
|
|
@@ -3325,8 +3166,8 @@ function Se(e) {
|
|
|
3325
3166
|
function G(e, t) {
|
|
3326
3167
|
return (e << (32 - t)) | (e >>> t);
|
|
3327
3168
|
}
|
|
3328
|
-
function
|
|
3329
|
-
const n = (r,
|
|
3169
|
+
function B_(e, t = {}) {
|
|
3170
|
+
const n = (r, a) => e(a).update(r).digest(),
|
|
3330
3171
|
o = e(void 0);
|
|
3331
3172
|
return (
|
|
3332
3173
|
(n.outputLen = o.outputLen),
|
|
@@ -3336,28 +3177,28 @@ function H_(e, t = {}) {
|
|
|
3336
3177
|
Object.freeze(n)
|
|
3337
3178
|
);
|
|
3338
3179
|
}
|
|
3339
|
-
const
|
|
3180
|
+
const G_ = (e) => ({
|
|
3340
3181
|
oid: Uint8Array.from([6, 9, 96, 134, 72, 1, 101, 3, 4, 2, e]),
|
|
3341
3182
|
});
|
|
3342
|
-
function
|
|
3183
|
+
function V_(e, t, n) {
|
|
3343
3184
|
return (e & t) ^ (~e & n);
|
|
3344
3185
|
}
|
|
3345
|
-
function
|
|
3186
|
+
function F_(e, t, n) {
|
|
3346
3187
|
return (e & t) ^ (e & n) ^ (t & n);
|
|
3347
3188
|
}
|
|
3348
|
-
class
|
|
3189
|
+
class z_ {
|
|
3349
3190
|
constructor(t, n, o, r) {
|
|
3350
|
-
|
|
3351
|
-
|
|
3352
|
-
|
|
3353
|
-
|
|
3191
|
+
g(this, 'blockLen');
|
|
3192
|
+
g(this, 'outputLen');
|
|
3193
|
+
g(this, 'padOffset');
|
|
3194
|
+
g(this, 'isLE');
|
|
3354
3195
|
// For partial updates less than block size
|
|
3355
|
-
|
|
3356
|
-
|
|
3357
|
-
|
|
3358
|
-
|
|
3359
|
-
|
|
3360
|
-
|
|
3196
|
+
g(this, 'buffer');
|
|
3197
|
+
g(this, 'view');
|
|
3198
|
+
g(this, 'finished', !1);
|
|
3199
|
+
g(this, 'length', 0);
|
|
3200
|
+
g(this, 'pos', 0);
|
|
3201
|
+
g(this, 'destroyed', !1);
|
|
3361
3202
|
((this.blockLen = t),
|
|
3362
3203
|
(this.outputLen = n),
|
|
3363
3204
|
(this.padOffset = o),
|
|
@@ -3366,39 +3207,39 @@ class Y_ {
|
|
|
3366
3207
|
(this.view = Se(this.buffer)));
|
|
3367
3208
|
}
|
|
3368
3209
|
update(t) {
|
|
3369
|
-
(Ke(this),
|
|
3210
|
+
(Ke(this), Vn(t));
|
|
3370
3211
|
const { view: n, buffer: o, blockLen: r } = this,
|
|
3371
|
-
|
|
3372
|
-
for (let
|
|
3373
|
-
const s = Math.min(r - this.pos,
|
|
3212
|
+
a = t.length;
|
|
3213
|
+
for (let i = 0; i < a; ) {
|
|
3214
|
+
const s = Math.min(r - this.pos, a - i);
|
|
3374
3215
|
if (s === r) {
|
|
3375
3216
|
const _ = Se(t);
|
|
3376
|
-
for (; r <=
|
|
3217
|
+
for (; r <= a - i; i += r) this.process(_, i);
|
|
3377
3218
|
continue;
|
|
3378
3219
|
}
|
|
3379
|
-
(o.set(t.subarray(
|
|
3220
|
+
(o.set(t.subarray(i, i + s), this.pos),
|
|
3380
3221
|
(this.pos += s),
|
|
3381
|
-
(
|
|
3222
|
+
(i += s),
|
|
3382
3223
|
this.pos === r && (this.process(n, 0), (this.pos = 0)));
|
|
3383
3224
|
}
|
|
3384
3225
|
return ((this.length += t.length), this.roundClean(), this);
|
|
3385
3226
|
}
|
|
3386
3227
|
digestInto(t) {
|
|
3387
|
-
(Ke(this),
|
|
3388
|
-
const { buffer: n, view: o, blockLen: r, isLE:
|
|
3389
|
-
let { pos:
|
|
3390
|
-
((n[
|
|
3391
|
-
he(this.buffer.subarray(
|
|
3392
|
-
this.padOffset > r -
|
|
3393
|
-
for (let
|
|
3394
|
-
(o.setBigUint64(r - 8, BigInt(this.length * 8),
|
|
3228
|
+
(Ke(this), k_(t, this), (this.finished = !0));
|
|
3229
|
+
const { buffer: n, view: o, blockLen: r, isLE: a } = this;
|
|
3230
|
+
let { pos: i } = this;
|
|
3231
|
+
((n[i++] = 128),
|
|
3232
|
+
he(this.buffer.subarray(i)),
|
|
3233
|
+
this.padOffset > r - i && (this.process(o, 0), (i = 0)));
|
|
3234
|
+
for (let d = i; d < r; d++) n[d] = 0;
|
|
3235
|
+
(o.setBigUint64(r - 8, BigInt(this.length * 8), a), this.process(o, 0));
|
|
3395
3236
|
const s = Se(t),
|
|
3396
3237
|
_ = this.outputLen;
|
|
3397
3238
|
if (_ % 4) throw new Error('_sha2: outputLen must be aligned to 32bit');
|
|
3398
3239
|
const N = _ / 4,
|
|
3399
|
-
|
|
3400
|
-
if (N >
|
|
3401
|
-
for (let
|
|
3240
|
+
f = this.get();
|
|
3241
|
+
if (N > f.length) throw new Error('_sha2: outputLen bigger than state');
|
|
3242
|
+
for (let d = 0; d < N; d++) s.setUint32(4 * d, f[d], a);
|
|
3402
3243
|
}
|
|
3403
3244
|
digest() {
|
|
3404
3245
|
const { buffer: t, outputLen: n } = this;
|
|
@@ -3408,10 +3249,10 @@ class Y_ {
|
|
|
3408
3249
|
}
|
|
3409
3250
|
_cloneInto(t) {
|
|
3410
3251
|
(t || (t = new this.constructor()), t.set(...this.get()));
|
|
3411
|
-
const { blockLen: n, buffer: o, length: r, finished:
|
|
3252
|
+
const { blockLen: n, buffer: o, length: r, finished: a, destroyed: i, pos: s } = this;
|
|
3412
3253
|
return (
|
|
3413
|
-
(t.destroyed =
|
|
3414
|
-
(t.finished =
|
|
3254
|
+
(t.destroyed = i),
|
|
3255
|
+
(t.finished = a),
|
|
3415
3256
|
(t.length = r),
|
|
3416
3257
|
(t.pos = s),
|
|
3417
3258
|
r % n && t.buffer.set(o),
|
|
@@ -3422,10 +3263,10 @@ class Y_ {
|
|
|
3422
3263
|
return this._cloneInto();
|
|
3423
3264
|
}
|
|
3424
3265
|
}
|
|
3425
|
-
const
|
|
3266
|
+
const $ = /* @__PURE__ */ Uint32Array.from([
|
|
3426
3267
|
1779033703, 3144134277, 1013904242, 2773480762, 1359893119, 2600822924, 528734635, 1541459225,
|
|
3427
3268
|
]),
|
|
3428
|
-
|
|
3269
|
+
H_ = /* @__PURE__ */ Uint32Array.from([
|
|
3429
3270
|
1116352408, 1899447441, 3049323471, 3921009573, 961987163, 1508970993, 2453635748, 2870763221,
|
|
3430
3271
|
3624381080, 310598401, 607225278, 1426881987, 1925078388, 2162078206, 2614888103, 3248222580,
|
|
3431
3272
|
3835390401, 4022224774, 264347078, 604807628, 770255983, 1249150122, 1555081692, 1996064986,
|
|
@@ -3435,92 +3276,92 @@ const X = /* @__PURE__ */ Uint32Array.from([
|
|
|
3435
3276
|
430227734, 506948616, 659060556, 883997877, 958139571, 1322822218, 1537002063, 1747873779,
|
|
3436
3277
|
1955562222, 2024104815, 2227730452, 2361852424, 2428436474, 2756734187, 3204031479, 3329325298,
|
|
3437
3278
|
]),
|
|
3438
|
-
|
|
3439
|
-
class
|
|
3279
|
+
X = /* @__PURE__ */ new Uint32Array(64);
|
|
3280
|
+
class W_ extends z_ {
|
|
3440
3281
|
constructor(t) {
|
|
3441
3282
|
super(64, t, 8, !1);
|
|
3442
3283
|
}
|
|
3443
3284
|
get() {
|
|
3444
|
-
const { A: t, B: n, C: o, D: r, E:
|
|
3445
|
-
return [t, n, o, r,
|
|
3285
|
+
const { A: t, B: n, C: o, D: r, E: a, F: i, G: s, H: _ } = this;
|
|
3286
|
+
return [t, n, o, r, a, i, s, _];
|
|
3446
3287
|
}
|
|
3447
3288
|
// prettier-ignore
|
|
3448
|
-
set(t, n, o, r,
|
|
3449
|
-
this.A = t | 0, this.B = n | 0, this.C = o | 0, this.D = r | 0, this.E =
|
|
3289
|
+
set(t, n, o, r, a, i, s, _) {
|
|
3290
|
+
this.A = t | 0, this.B = n | 0, this.C = o | 0, this.D = r | 0, this.E = a | 0, this.F = i | 0, this.G = s | 0, this.H = _ | 0;
|
|
3450
3291
|
}
|
|
3451
3292
|
process(t, n) {
|
|
3452
|
-
for (let
|
|
3453
|
-
for (let
|
|
3454
|
-
const y =
|
|
3455
|
-
W =
|
|
3293
|
+
for (let d = 0; d < 16; d++, n += 4) X[d] = t.getUint32(n, !1);
|
|
3294
|
+
for (let d = 16; d < 64; d++) {
|
|
3295
|
+
const y = X[d - 15],
|
|
3296
|
+
W = X[d - 2],
|
|
3456
3297
|
Be = G(y, 7) ^ G(y, 18) ^ (y >>> 3),
|
|
3457
|
-
|
|
3458
|
-
|
|
3298
|
+
Oe = G(W, 17) ^ G(W, 19) ^ (W >>> 10);
|
|
3299
|
+
X[d] = (Oe + X[d - 7] + Be + X[d - 16]) | 0;
|
|
3459
3300
|
}
|
|
3460
|
-
let { A: o, B: r, C:
|
|
3461
|
-
for (let
|
|
3301
|
+
let { A: o, B: r, C: a, D: i, E: s, F: _, G: N, H: f } = this;
|
|
3302
|
+
for (let d = 0; d < 64; d++) {
|
|
3462
3303
|
const y = G(s, 6) ^ G(s, 11) ^ G(s, 25),
|
|
3463
|
-
W = (
|
|
3464
|
-
|
|
3465
|
-
((
|
|
3304
|
+
W = (f + y + V_(s, _, N) + H_[d] + X[d]) | 0,
|
|
3305
|
+
Oe = ((G(o, 2) ^ G(o, 13) ^ G(o, 22)) + F_(o, r, a)) | 0;
|
|
3306
|
+
((f = N), (N = _), (_ = s), (s = (i + W) | 0), (i = a), (a = r), (r = o), (o = (W + Oe) | 0));
|
|
3466
3307
|
}
|
|
3467
3308
|
((o = (o + this.A) | 0),
|
|
3468
3309
|
(r = (r + this.B) | 0),
|
|
3469
|
-
(
|
|
3470
|
-
(
|
|
3310
|
+
(a = (a + this.C) | 0),
|
|
3311
|
+
(i = (i + this.D) | 0),
|
|
3471
3312
|
(s = (s + this.E) | 0),
|
|
3472
3313
|
(_ = (_ + this.F) | 0),
|
|
3473
3314
|
(N = (N + this.G) | 0),
|
|
3474
|
-
(
|
|
3475
|
-
this.set(o, r,
|
|
3315
|
+
(f = (f + this.H) | 0),
|
|
3316
|
+
this.set(o, r, a, i, s, _, N, f));
|
|
3476
3317
|
}
|
|
3477
3318
|
roundClean() {
|
|
3478
|
-
he(
|
|
3319
|
+
he(X);
|
|
3479
3320
|
}
|
|
3480
3321
|
destroy() {
|
|
3481
3322
|
(this.set(0, 0, 0, 0, 0, 0, 0, 0), he(this.buffer));
|
|
3482
3323
|
}
|
|
3483
3324
|
}
|
|
3484
|
-
class
|
|
3325
|
+
class $_ extends W_ {
|
|
3485
3326
|
constructor() {
|
|
3486
3327
|
super(32);
|
|
3487
3328
|
// We cannot use array here since array allows indexing by variable
|
|
3488
3329
|
// which means optimizer/compiler cannot use registers.
|
|
3489
|
-
|
|
3490
|
-
|
|
3491
|
-
|
|
3492
|
-
|
|
3493
|
-
|
|
3494
|
-
|
|
3495
|
-
|
|
3496
|
-
|
|
3330
|
+
g(this, 'A', $[0] | 0);
|
|
3331
|
+
g(this, 'B', $[1] | 0);
|
|
3332
|
+
g(this, 'C', $[2] | 0);
|
|
3333
|
+
g(this, 'D', $[3] | 0);
|
|
3334
|
+
g(this, 'E', $[4] | 0);
|
|
3335
|
+
g(this, 'F', $[5] | 0);
|
|
3336
|
+
g(this, 'G', $[6] | 0);
|
|
3337
|
+
g(this, 'H', $[7] | 0);
|
|
3497
3338
|
}
|
|
3498
3339
|
}
|
|
3499
|
-
const
|
|
3340
|
+
const X_ = /* @__PURE__ */ B_(() => new $_(), /* @__PURE__ */ G_(1)),
|
|
3500
3341
|
te = c(),
|
|
3501
3342
|
je = pe(),
|
|
3502
|
-
|
|
3343
|
+
Y_ = new TextEncoder().encode('ProgramDerivedAddress');
|
|
3503
3344
|
function ke(e, t) {
|
|
3504
3345
|
const n = je.encode(e);
|
|
3505
3346
|
for (let o = 255; o > 0; o--) {
|
|
3506
3347
|
const r = [];
|
|
3507
3348
|
for (const s of t) r.push(...s);
|
|
3508
|
-
(r.push(o), r.push(...n), r.push(...
|
|
3509
|
-
const
|
|
3510
|
-
|
|
3511
|
-
if (
|
|
3349
|
+
(r.push(o), r.push(...n), r.push(...Y_));
|
|
3350
|
+
const a = X_(new Uint8Array(r)),
|
|
3351
|
+
i = je.decode(a);
|
|
3352
|
+
if (ts(i)) return [i, o];
|
|
3512
3353
|
}
|
|
3513
3354
|
throw new Error('Failed to find viable PDA bump seed');
|
|
3514
3355
|
}
|
|
3515
|
-
async function
|
|
3356
|
+
async function eR() {
|
|
3516
3357
|
return De({
|
|
3517
|
-
programAddress:
|
|
3358
|
+
programAddress: U,
|
|
3518
3359
|
seeds: [new TextEncoder().encode('global_config')],
|
|
3519
3360
|
});
|
|
3520
3361
|
}
|
|
3521
|
-
async function
|
|
3362
|
+
async function tR(e, t, n) {
|
|
3522
3363
|
return De({
|
|
3523
|
-
programAddress:
|
|
3364
|
+
programAddress: U,
|
|
3524
3365
|
seeds: [
|
|
3525
3366
|
new TextEncoder().encode('automation'),
|
|
3526
3367
|
te.encode(e),
|
|
@@ -3529,220 +3370,212 @@ async function cu(e, t, n) {
|
|
|
3529
3370
|
],
|
|
3530
3371
|
});
|
|
3531
3372
|
}
|
|
3532
|
-
async function
|
|
3373
|
+
async function nR(e) {
|
|
3533
3374
|
return De({
|
|
3534
|
-
programAddress:
|
|
3375
|
+
programAddress: U,
|
|
3535
3376
|
seeds: [new TextEncoder().encode('automation-authority'), te.encode(e)],
|
|
3536
3377
|
});
|
|
3537
3378
|
}
|
|
3538
|
-
function
|
|
3539
|
-
return ke(
|
|
3379
|
+
function rR() {
|
|
3380
|
+
return ke(U, [new TextEncoder().encode('global_config')]);
|
|
3540
3381
|
}
|
|
3541
|
-
function
|
|
3542
|
-
return ke(
|
|
3382
|
+
function oR(e, t, n) {
|
|
3383
|
+
return ke(U, [
|
|
3543
3384
|
new TextEncoder().encode('automation'),
|
|
3544
3385
|
te.encode(e),
|
|
3545
3386
|
te.encode(t),
|
|
3546
3387
|
new Uint8Array([n]),
|
|
3547
3388
|
]);
|
|
3548
3389
|
}
|
|
3549
|
-
function
|
|
3550
|
-
return ke(
|
|
3390
|
+
function aR(e) {
|
|
3391
|
+
return ke(U, [new TextEncoder().encode('automation-authority'), te.encode(e)]);
|
|
3551
3392
|
}
|
|
3552
|
-
const
|
|
3393
|
+
const iR = 'J5YZi2SoRbaAFcMJWcvkQRUgpB3YdMHJ4AEKhEV6ED7x';
|
|
3553
3394
|
export {
|
|
3554
3395
|
be as AccountDiscriminator,
|
|
3555
3396
|
we as Action,
|
|
3556
3397
|
Tn as CREATE_AUTOMATION_DISCRIMINATOR,
|
|
3557
3398
|
In as FUND_AUTOMATION_DISCRIMINATOR,
|
|
3558
|
-
|
|
3559
|
-
Cn as
|
|
3560
|
-
|
|
3561
|
-
bn as
|
|
3562
|
-
|
|
3563
|
-
|
|
3564
|
-
|
|
3565
|
-
yn as REMOVE_AUTOMATIONS_DISCRIMINATOR,
|
|
3399
|
+
xe as FundAutomationMethod,
|
|
3400
|
+
Cn as HARVEST_SWAP_AND_REINVEST_POST_DISCRIMINATOR,
|
|
3401
|
+
vn as HARVEST_SWAP_AND_REINVEST_PRE_DISCRIMINATOR,
|
|
3402
|
+
bn as INITIALIZE_GLOBAL_CONFIG_DISCRIMINATOR,
|
|
3403
|
+
Me as IncreaseLiquidityByTokenAmountsAccountsType,
|
|
3404
|
+
Qc as MAX_AUTOMATION_INDEX,
|
|
3405
|
+
wn as REMOVE_AUTOMATIONS_DISCRIMINATOR,
|
|
3566
3406
|
ye as TokenAccountState,
|
|
3567
|
-
|
|
3568
|
-
|
|
3569
|
-
|
|
3570
|
-
|
|
3571
|
-
|
|
3572
|
-
|
|
3573
|
-
|
|
3574
|
-
|
|
3575
|
-
|
|
3576
|
-
|
|
3577
|
-
|
|
3578
|
-
|
|
3579
|
-
|
|
3580
|
-
|
|
3581
|
-
|
|
3582
|
-
|
|
3583
|
-
|
|
3584
|
-
|
|
3585
|
-
|
|
3586
|
-
|
|
3587
|
-
|
|
3588
|
-
|
|
3589
|
-
|
|
3590
|
-
|
|
3591
|
-
|
|
3592
|
-
|
|
3593
|
-
|
|
3594
|
-
|
|
3595
|
-
|
|
3596
|
-
|
|
3597
|
-
|
|
3598
|
-
|
|
3599
|
-
|
|
3600
|
-
|
|
3601
|
-
|
|
3602
|
-
|
|
3603
|
-
|
|
3604
|
-
|
|
3605
|
-
|
|
3606
|
-
|
|
3607
|
-
On as decodeAutomation,
|
|
3407
|
+
yn as UPDATE_GLOBAL_CONFIG_DISCRIMINATOR,
|
|
3408
|
+
d_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__ACCOUNT_ALREADY_INITIALIZED,
|
|
3409
|
+
O_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__ACCOUNT_NOT_INITIALIZED,
|
|
3410
|
+
g_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__ARITHMETIC_ERROR,
|
|
3411
|
+
h_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__CONDITION_VIOLATION,
|
|
3412
|
+
A_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__EMIT_EVENT_ERROR,
|
|
3413
|
+
R_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INCORRECT_ACCOUNT_ADDRESS,
|
|
3414
|
+
__ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INCORRECT_OWNER,
|
|
3415
|
+
a_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INCORRECT_PROGRAM_ID,
|
|
3416
|
+
b_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INSUFFICIENT_FUNDS_TO_PAY_CRANK_REWARD,
|
|
3417
|
+
P_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INSUFFICIENT_INSTRUCTION_COUNT_AFTER,
|
|
3418
|
+
U_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INSUFFICIENT_INSTRUCTION_COUNT_BEFORE,
|
|
3419
|
+
w_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INVALID_ACCOMPANYING_INSTRUCTION,
|
|
3420
|
+
u_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INVALID_ACCOUNT_DATA,
|
|
3421
|
+
s_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INVALID_ACCOUNT_ROLE,
|
|
3422
|
+
E_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INVALID_ACTION,
|
|
3423
|
+
S_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INVALID_ACTION_DATA_LENGTH,
|
|
3424
|
+
C_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INVALID_AMOUNT_TO_FUND_AUTOMATION,
|
|
3425
|
+
I_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INVALID_AUTOMATION_ACTION,
|
|
3426
|
+
T_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INVALID_AUTOMATION_INDEX,
|
|
3427
|
+
N_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INVALID_CONDITION,
|
|
3428
|
+
f_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INVALID_CONDITION_DATA_LENGTH,
|
|
3429
|
+
p_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INVALID_CRANK_REWARD,
|
|
3430
|
+
L_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INVALID_C_P_I_ACCOUNTS,
|
|
3431
|
+
v_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INVALID_C_P_I_INSTRUCTION_DATA,
|
|
3432
|
+
m_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INVALID_NEXT_VALID_EXECUTION_TIMESTAMP_CONDITION,
|
|
3433
|
+
l_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INVALID_POSITION_TOKEN_AMOUNT,
|
|
3434
|
+
x_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INVALID_REMAINING_ACCOUNTS_LENGTH,
|
|
3435
|
+
c_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__INVALID_SEEDS,
|
|
3436
|
+
i_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__NOT_ENOUGH_ACCOUNT_KEYS,
|
|
3437
|
+
D_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__REDUNDANT_GLOBAL_CONFIG_UPDATE,
|
|
3438
|
+
o_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__UNKNOWN_INSTRUCTION_DISCRIMINATOR,
|
|
3439
|
+
M_ as WHIRLPOOLS_AUTOMATION_PROGRAM_ERROR__UNSUPPORTED_TOKEN_EXTENSION,
|
|
3440
|
+
U as WHIRLPOOLS_AUTOMATION_PROGRAM_PROGRAM_ADDRESS,
|
|
3441
|
+
iR as WHIRLPOOLS_AUTOMATION_PROGRAM_STAGING_ADDRESS,
|
|
3442
|
+
t_ as WhirlpoolsAutomationProgramAccount,
|
|
3443
|
+
n_ as WhirlpoolsAutomationProgramInstruction,
|
|
3444
|
+
Ki as address,
|
|
3445
|
+
Z_ as condition,
|
|
3446
|
+
ln as decodeAutomation,
|
|
3608
3447
|
Nn as decodeGlobalConfig,
|
|
3609
|
-
|
|
3610
|
-
|
|
3611
|
-
|
|
3612
|
-
|
|
3613
|
-
|
|
3614
|
-
|
|
3615
|
-
|
|
3616
|
-
|
|
3617
|
-
|
|
3618
|
-
|
|
3619
|
-
|
|
3620
|
-
|
|
3621
|
-
|
|
3622
|
-
|
|
3623
|
-
|
|
3624
|
-
|
|
3625
|
-
|
|
3626
|
-
|
|
3627
|
-
|
|
3628
|
-
|
|
3448
|
+
tc as event,
|
|
3449
|
+
hc as fetchAllAutomation,
|
|
3450
|
+
pc as fetchAllGlobalConfig,
|
|
3451
|
+
Hs as fetchAllMaybeAutomation,
|
|
3452
|
+
Xs as fetchAllMaybeGlobalConfig,
|
|
3453
|
+
Cc as fetchAutomation,
|
|
3454
|
+
vc as fetchGlobalConfig,
|
|
3455
|
+
zs as fetchMaybeAutomation,
|
|
3456
|
+
$s as fetchMaybeGlobalConfig,
|
|
3457
|
+
tR as findAutomationAddress,
|
|
3458
|
+
oR as findAutomationAddressSync,
|
|
3459
|
+
nR as findAutomationAuthorityAddress,
|
|
3460
|
+
aR as findAutomationAuthorityAddressSync,
|
|
3461
|
+
eR as findGlobalConfigAddress,
|
|
3462
|
+
rR as findGlobalConfigAddressSync,
|
|
3463
|
+
ac as fundAutomationVariant,
|
|
3464
|
+
j_ as getAccountDiscriminatorCodec,
|
|
3465
|
+
Pe as getAccountDiscriminatorDecoder,
|
|
3466
|
+
Ue as getAccountDiscriminatorEncoder,
|
|
3467
|
+
J_ as getActionCodec,
|
|
3629
3468
|
Kt as getActionDecoder,
|
|
3630
3469
|
Yt as getActionEncoder,
|
|
3631
|
-
|
|
3470
|
+
R as getAddressDecoder,
|
|
3632
3471
|
c as getAddressEncoder,
|
|
3633
|
-
|
|
3634
|
-
|
|
3635
|
-
|
|
3636
|
-
|
|
3472
|
+
mc as getAutomationCodec,
|
|
3473
|
+
On as getAutomationDecoder,
|
|
3474
|
+
Fs as getAutomationEncoder,
|
|
3475
|
+
q_ as getConditionCodec,
|
|
3637
3476
|
Jt as getConditionDecoder,
|
|
3638
3477
|
jt as getConditionEncoder,
|
|
3639
|
-
|
|
3640
|
-
|
|
3641
|
-
|
|
3478
|
+
Dc as getCreateAutomationDiscriminatorBytes,
|
|
3479
|
+
Uc as getCreateAutomationInstruction,
|
|
3480
|
+
bc as getCreateAutomationInstructionDataCodec,
|
|
3642
3481
|
fn as getCreateAutomationInstructionDataDecoder,
|
|
3643
3482
|
Sn as getCreateAutomationInstructionDataEncoder,
|
|
3644
|
-
|
|
3645
|
-
|
|
3646
|
-
|
|
3647
|
-
|
|
3648
|
-
|
|
3649
|
-
|
|
3650
|
-
|
|
3651
|
-
|
|
3652
|
-
|
|
3483
|
+
ec as getEventCodec,
|
|
3484
|
+
ps as getEventDecoder,
|
|
3485
|
+
vs as getEventEncoder,
|
|
3486
|
+
Pc as getFundAutomationDiscriminatorBytes,
|
|
3487
|
+
xc as getFundAutomationInstruction,
|
|
3488
|
+
wc as getFundAutomationInstructionDataCodec,
|
|
3489
|
+
mn as getFundAutomationInstructionDataDecoder,
|
|
3490
|
+
gn as getFundAutomationInstructionDataEncoder,
|
|
3491
|
+
rc as getFundAutomationMethodCodec,
|
|
3653
3492
|
Zt as getFundAutomationMethodDecoder,
|
|
3654
3493
|
qt as getFundAutomationMethodEncoder,
|
|
3655
|
-
|
|
3494
|
+
oc as getFundAutomationVariantCodec,
|
|
3656
3495
|
en as getFundAutomationVariantDecoder,
|
|
3657
3496
|
Qt as getFundAutomationVariantEncoder,
|
|
3658
|
-
|
|
3497
|
+
Lc as getGlobalConfigCodec,
|
|
3659
3498
|
En as getGlobalConfigDecoder,
|
|
3660
|
-
|
|
3661
|
-
|
|
3662
|
-
|
|
3663
|
-
|
|
3664
|
-
|
|
3665
|
-
hn as
|
|
3666
|
-
|
|
3667
|
-
|
|
3668
|
-
|
|
3669
|
-
Dn as
|
|
3670
|
-
pn as
|
|
3671
|
-
|
|
3672
|
-
Kc as getHarvestSwapAndReinvestPreInstruction,
|
|
3673
|
-
Yc as getHarvestSwapAndReinvestPreInstructionDataCodec,
|
|
3674
|
-
Un as getHarvestSwapAndReinvestPreInstructionDataDecoder,
|
|
3675
|
-
Pn as getHarvestSwapAndReinvestPreInstructionDataEncoder,
|
|
3676
|
-
Ac as getIncreaseLiquidityByTokenAmountsAccountsTypeCodec,
|
|
3499
|
+
Ws as getGlobalConfigEncoder,
|
|
3500
|
+
Mc as getHarvestSwapAndReinvestPostDiscriminatorBytes,
|
|
3501
|
+
kc as getHarvestSwapAndReinvestPostInstruction,
|
|
3502
|
+
yc as getHarvestSwapAndReinvestPostInstructionDataCodec,
|
|
3503
|
+
Ln as getHarvestSwapAndReinvestPostInstructionDataDecoder,
|
|
3504
|
+
hn as getHarvestSwapAndReinvestPostInstructionDataEncoder,
|
|
3505
|
+
Bc as getHarvestSwapAndReinvestPreDiscriminatorBytes,
|
|
3506
|
+
Vc as getHarvestSwapAndReinvestPreInstruction,
|
|
3507
|
+
Gc as getHarvestSwapAndReinvestPreInstructionDataCodec,
|
|
3508
|
+
Dn as getHarvestSwapAndReinvestPreInstructionDataDecoder,
|
|
3509
|
+
pn as getHarvestSwapAndReinvestPreInstructionDataEncoder,
|
|
3510
|
+
sc as getIncreaseLiquidityByTokenAmountsAccountsTypeCodec,
|
|
3677
3511
|
nn as getIncreaseLiquidityByTokenAmountsAccountsTypeDecoder,
|
|
3678
3512
|
tn as getIncreaseLiquidityByTokenAmountsAccountsTypeEncoder,
|
|
3679
|
-
|
|
3680
|
-
|
|
3681
|
-
|
|
3682
|
-
|
|
3513
|
+
_c as getIncreaseLiquidityByTokenAmountsRemainingAccountsInfoCodec,
|
|
3514
|
+
bs as getIncreaseLiquidityByTokenAmountsRemainingAccountsInfoDecoder,
|
|
3515
|
+
Ds as getIncreaseLiquidityByTokenAmountsRemainingAccountsInfoEncoder,
|
|
3516
|
+
cc as getIncreaseLiquidityByTokenAmountsRemainingAccountsSliceCodec,
|
|
3683
3517
|
on as getIncreaseLiquidityByTokenAmountsRemainingAccountsSliceDecoder,
|
|
3684
3518
|
rn as getIncreaseLiquidityByTokenAmountsRemainingAccountsSliceEncoder,
|
|
3685
|
-
|
|
3686
|
-
|
|
3687
|
-
|
|
3688
|
-
|
|
3689
|
-
|
|
3690
|
-
|
|
3691
|
-
|
|
3692
|
-
|
|
3693
|
-
|
|
3694
|
-
|
|
3695
|
-
|
|
3696
|
-
|
|
3697
|
-
|
|
3698
|
-
|
|
3519
|
+
Rc as getIncreaseLiquidityMethodCodec,
|
|
3520
|
+
Ps as getIncreaseLiquidityMethodDecoder,
|
|
3521
|
+
Us as getIncreaseLiquidityMethodEncoder,
|
|
3522
|
+
Fc as getInitializeGlobalConfigDiscriminatorBytes,
|
|
3523
|
+
Hc as getInitializeGlobalConfigInstruction,
|
|
3524
|
+
zc as getInitializeGlobalConfigInstructionDataCodec,
|
|
3525
|
+
Pn as getInitializeGlobalConfigInstructionDataDecoder,
|
|
3526
|
+
Un as getInitializeGlobalConfigInstructionDataEncoder,
|
|
3527
|
+
Ls as getNonZeroU32Decoder,
|
|
3528
|
+
hs as getNonZeroU32Encoder,
|
|
3529
|
+
dc as getPositionCodec,
|
|
3530
|
+
xs as getPositionDecoder,
|
|
3531
|
+
ws as getPositionEncoder,
|
|
3532
|
+
Oc as getPositionRewardInfoCodec,
|
|
3699
3533
|
sn as getPositionRewardInfoDecoder,
|
|
3700
3534
|
an as getPositionRewardInfoEncoder,
|
|
3701
|
-
|
|
3702
|
-
|
|
3703
|
-
|
|
3704
|
-
|
|
3705
|
-
|
|
3706
|
-
|
|
3707
|
-
|
|
3708
|
-
|
|
3709
|
-
|
|
3535
|
+
Wc as getRemoveAutomationsDiscriminatorBytes,
|
|
3536
|
+
Xc as getRemoveAutomationsInstruction,
|
|
3537
|
+
$c as getRemoveAutomationsInstructionDataCodec,
|
|
3538
|
+
Mn as getRemoveAutomationsInstructionDataDecoder,
|
|
3539
|
+
xn as getRemoveAutomationsInstructionDataEncoder,
|
|
3540
|
+
lc as getTokenAccountCodec,
|
|
3541
|
+
ys as getTokenAccountDecoder,
|
|
3542
|
+
Ms as getTokenAccountEncoder,
|
|
3543
|
+
Ec as getTokenAccountStateCodec,
|
|
3710
3544
|
cn as getTokenAccountStateDecoder,
|
|
3711
3545
|
_n as getTokenAccountStateEncoder,
|
|
3712
|
-
|
|
3713
|
-
|
|
3714
|
-
|
|
3715
|
-
|
|
3716
|
-
|
|
3717
|
-
|
|
3718
|
-
|
|
3719
|
-
|
|
3720
|
-
|
|
3721
|
-
|
|
3722
|
-
|
|
3723
|
-
|
|
3724
|
-
|
|
3725
|
-
|
|
3726
|
-
|
|
3546
|
+
Nc as getTokenMintCodec,
|
|
3547
|
+
Bs as getTokenMintDecoder,
|
|
3548
|
+
ks as getTokenMintEncoder,
|
|
3549
|
+
Yc as getUpdateGlobalConfigDiscriminatorBytes,
|
|
3550
|
+
jc as getUpdateGlobalConfigInstruction,
|
|
3551
|
+
Kc as getUpdateGlobalConfigInstructionDataCodec,
|
|
3552
|
+
Bn as getUpdateGlobalConfigInstructionDataDecoder,
|
|
3553
|
+
kn as getUpdateGlobalConfigInstructionDataEncoder,
|
|
3554
|
+
Tc as getUpdateGlobalConfigVariantCodec,
|
|
3555
|
+
un as getUpdateGlobalConfigVariantDecoder,
|
|
3556
|
+
Rn as getUpdateGlobalConfigVariantEncoder,
|
|
3557
|
+
Ic as getWhirlpoolCodec,
|
|
3558
|
+
Vs as getWhirlpoolDecoder,
|
|
3559
|
+
Gs as getWhirlpoolEncoder,
|
|
3560
|
+
gc as getWhirlpoolRewardInfoCodec,
|
|
3727
3561
|
dn as getWhirlpoolRewardInfoDecoder,
|
|
3728
3562
|
An as getWhirlpoolRewardInfoEncoder,
|
|
3729
|
-
|
|
3730
|
-
|
|
3731
|
-
|
|
3732
|
-
|
|
3733
|
-
|
|
3734
|
-
|
|
3735
|
-
|
|
3736
|
-
|
|
3737
|
-
|
|
3738
|
-
|
|
3739
|
-
|
|
3740
|
-
|
|
3741
|
-
|
|
3742
|
-
|
|
3743
|
-
|
|
3744
|
-
|
|
3745
|
-
|
|
3746
|
-
|
|
3747
|
-
Cc as updateGlobalConfigVariant,
|
|
3563
|
+
qc as getWhirlpoolsAutomationProgramErrorMessage,
|
|
3564
|
+
r_ as identifyWhirlpoolsAutomationProgramInstruction,
|
|
3565
|
+
uc as increaseLiquidityMethod,
|
|
3566
|
+
Q_ as isCondition,
|
|
3567
|
+
nc as isEvent,
|
|
3568
|
+
ic as isFundAutomationVariant,
|
|
3569
|
+
Ac as isIncreaseLiquidityMethod,
|
|
3570
|
+
fc as isUpdateGlobalConfigVariant,
|
|
3571
|
+
Zc as isWhirlpoolsAutomationProgramError,
|
|
3572
|
+
Ks as parseCreateAutomationInstruction,
|
|
3573
|
+
js as parseFundAutomationInstruction,
|
|
3574
|
+
Js as parseHarvestSwapAndReinvestPostInstruction,
|
|
3575
|
+
qs as parseHarvestSwapAndReinvestPreInstruction,
|
|
3576
|
+
Zs as parseInitializeGlobalConfigInstruction,
|
|
3577
|
+
Qs as parseRemoveAutomationsInstruction,
|
|
3578
|
+
e_ as parseUpdateGlobalConfigInstruction,
|
|
3579
|
+
Jc as parseWhirlpoolsAutomationProgramInstruction,
|
|
3580
|
+
Sc as updateGlobalConfigVariant,
|
|
3748
3581
|
};
|