probing 5.0.4 → 7.0.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/CHANGELOG.md +8 -0
- package/README.md +0 -9
- package/liquidity/find_max_payable.js +0 -1
- package/liquidity/subscribe_to_find_max_payable.js +0 -1
- package/liquidity/subscribe_to_find_path.js +0 -3
- package/liquidity/subscribe_to_multi_path_probe.js +0 -3
- package/package.json +3 -3
- package/payments/get_route_for_payment.js +0 -1
- package/payments/subscribe_to_multi_path_pay.js +0 -6
- package/routing/is_route_payable.js +0 -1
- package/test/liquidity/test_subscribe_to_find_path.js +0 -4
- package/test/liquidity/test_subscribe_to_multi_path_probe.js +0 -3
- package/test/payments/test_get_route_for_payment.js +4 -1
- package/test/routing/test_is_route_payable.js +0 -1
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -120,7 +120,6 @@ Subscribe to a payment over multiple paths
|
|
|
120
120
|
fee_mtokens: <Fee Paid Millitokens String>
|
|
121
121
|
hops: [{
|
|
122
122
|
channel: <Standard Format Channel Id String>
|
|
123
|
-
channel_capacity: <Hop Channel Capacity Tokens Number>
|
|
124
123
|
fee_mtokens: <Hop Forward Fee Millitokens String>
|
|
125
124
|
forward_mtokens: <Hop Forwarded Millitokens String>
|
|
126
125
|
timeout: <Hop CLTV Expiry Block Height Number>
|
|
@@ -134,7 +133,6 @@ Subscribe to a payment over multiple paths
|
|
|
134
133
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
135
134
|
hops: [{
|
|
136
135
|
channel: <Standard Format Channel Id String>
|
|
137
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
138
136
|
fee: <Fee Number>
|
|
139
137
|
fee_mtokens: <Fee Millitokens String>
|
|
140
138
|
forward: <Forward Tokens Number>
|
|
@@ -159,7 +157,6 @@ Subscribe to a payment over multiple paths
|
|
|
159
157
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
160
158
|
hops: [{
|
|
161
159
|
channel: <Standard Format Channel Id String>
|
|
162
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
163
160
|
fee: <Fee Number>
|
|
164
161
|
fee_mtokens: <Fee Millitokens String>
|
|
165
162
|
forward: <Forward Tokens Number>
|
|
@@ -194,7 +191,6 @@ Subscribe to a payment over multiple paths
|
|
|
194
191
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
195
192
|
hops: [{
|
|
196
193
|
channel: <Standard Format Channel Id String>
|
|
197
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
198
194
|
fee: <Fee Number>
|
|
199
195
|
fee_mtokens: <Fee Millitokens String>
|
|
200
196
|
forward: <Forward Tokens Number>
|
|
@@ -225,7 +221,6 @@ Subscribe to a payment over multiple paths
|
|
|
225
221
|
fee_mtokens: <Fee Paid Millitokens String>
|
|
226
222
|
hops: [{
|
|
227
223
|
channel: <Standard Format Channel Id String>
|
|
228
|
-
channel_capacity: <Hop Channel Capacity Tokens Number>
|
|
229
224
|
fee_mtokens: <Hop Forward Fee Millitokens String>
|
|
230
225
|
forward_mtokens: <Hop Forwarded Millitokens String>
|
|
231
226
|
timeout: <Hop CLTV Expiry Block Height Number>
|
|
@@ -239,7 +234,6 @@ Subscribe to a payment over multiple paths
|
|
|
239
234
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
240
235
|
hops: [{
|
|
241
236
|
channel: <Standard Format Channel Id String>
|
|
242
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
243
237
|
fee: <Fee Number>
|
|
244
238
|
fee_mtokens: <Fee Millitokens String>
|
|
245
239
|
forward: <Forward Tokens Number>
|
|
@@ -320,7 +314,6 @@ This method is not supported on versions below LND 0.10.0
|
|
|
320
314
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
321
315
|
hops: [{
|
|
322
316
|
channel: <Standard Format Channel Id String>
|
|
323
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
324
317
|
fee: <Fee Number>
|
|
325
318
|
fee_mtokens: <Fee Millitokens String>
|
|
326
319
|
forward: <Forward Tokens Number>
|
|
@@ -365,7 +358,6 @@ This method is not supported on versions below LND 0.10.0
|
|
|
365
358
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
366
359
|
hops: [{
|
|
367
360
|
channel: <Standard Format Channel Id String>
|
|
368
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
369
361
|
fee: <Fee Number>
|
|
370
362
|
fee_mtokens: <Fee Millitokens String>
|
|
371
363
|
forward: <Forward Tokens Number>
|
|
@@ -402,7 +394,6 @@ This method is not supported on versions below LND 0.10.0
|
|
|
402
394
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
403
395
|
hops: [{
|
|
404
396
|
channel: <Standard Format Channel Id String>
|
|
405
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
406
397
|
fee: <Fee Number>
|
|
407
398
|
fee_mtokens: <Fee Millitokens String>
|
|
408
399
|
forward: <Forward Tokens Number>
|
|
@@ -49,7 +49,6 @@ const to = tokens => Math.max(2, tokens - Math.round(Math.random() * 20000));
|
|
|
49
49
|
fee_mtokens: <Route Fee Millitokens String>
|
|
50
50
|
hops: [{
|
|
51
51
|
channel: <Standard Format Channel Id String>
|
|
52
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
53
52
|
fee: <Fee Number>
|
|
54
53
|
fee_mtokens: <Fee Millitokens String>
|
|
55
54
|
forward: <Forward Tokens Number>
|
|
@@ -47,7 +47,6 @@ const {nextTick} = process;
|
|
|
47
47
|
fee_mtokens: <Route Fee Millitokens String>
|
|
48
48
|
hops: [{
|
|
49
49
|
channel: <Standard Format Channel Id String>
|
|
50
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
51
50
|
fee: <Fee Number>
|
|
52
51
|
fee_mtokens: <Fee Millitokens String>
|
|
53
52
|
forward: <Forward Tokens Number>
|
|
@@ -80,7 +80,6 @@ const {nextTick} = process;
|
|
|
80
80
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
81
81
|
hops: [{
|
|
82
82
|
channel: <Standard Format Channel Id String>
|
|
83
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
84
83
|
fee: <Fee Number>
|
|
85
84
|
fee_mtokens: <Fee Millitokens String>
|
|
86
85
|
forward: <Forward Tokens Number>
|
|
@@ -122,7 +121,6 @@ const {nextTick} = process;
|
|
|
122
121
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
123
122
|
hops: [{
|
|
124
123
|
channel: <Standard Format Channel Id String>
|
|
125
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
126
124
|
fee: <Fee Number>
|
|
127
125
|
fee_mtokens: <Fee Millitokens String>
|
|
128
126
|
forward: <Forward Tokens Number>
|
|
@@ -159,7 +157,6 @@ const {nextTick} = process;
|
|
|
159
157
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
160
158
|
hops: [{
|
|
161
159
|
channel: <Standard Format Channel Id String>
|
|
162
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
163
160
|
fee: <Fee Number>
|
|
164
161
|
fee_mtokens: <Fee Millitokens String>
|
|
165
162
|
forward: <Forward Tokens Number>
|
|
@@ -78,7 +78,6 @@ const {nextTick} = process;
|
|
|
78
78
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
79
79
|
hops: [{
|
|
80
80
|
channel: <Standard Format Channel Id String>
|
|
81
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
82
81
|
fee: <Fee Number>
|
|
83
82
|
fee_mtokens: <Fee Millitokens String>
|
|
84
83
|
forward: <Forward Tokens Number>
|
|
@@ -120,7 +119,6 @@ const {nextTick} = process;
|
|
|
120
119
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
121
120
|
hops: [{
|
|
122
121
|
channel: <Standard Format Channel Id String>
|
|
123
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
124
122
|
fee: <Fee Number>
|
|
125
123
|
fee_mtokens: <Fee Millitokens String>
|
|
126
124
|
forward: <Forward Tokens Number>
|
|
@@ -157,7 +155,6 @@ const {nextTick} = process;
|
|
|
157
155
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
158
156
|
hops: [{
|
|
159
157
|
channel: <Standard Format Channel Id String>
|
|
160
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
161
158
|
fee: <Fee Number>
|
|
162
159
|
fee_mtokens: <Fee Millitokens String>
|
|
163
160
|
forward: <Forward Tokens Number>
|
package/package.json
CHANGED
|
@@ -9,11 +9,11 @@
|
|
|
9
9
|
"dependencies": {
|
|
10
10
|
"async": "3.2.6",
|
|
11
11
|
"asyncjs-util": "1.2.12",
|
|
12
|
-
"ln-service": "
|
|
12
|
+
"ln-service": "59.1.1"
|
|
13
13
|
},
|
|
14
14
|
"description": "Lightning Network probing utilities",
|
|
15
15
|
"engines": {
|
|
16
|
-
"node": ">=
|
|
16
|
+
"node": ">=22"
|
|
17
17
|
},
|
|
18
18
|
"keywords": [
|
|
19
19
|
"lightning",
|
|
@@ -30,5 +30,5 @@
|
|
|
30
30
|
"scripts": {
|
|
31
31
|
"test": "npx nyc@17.1 node --experimental-test-coverage --test"
|
|
32
32
|
},
|
|
33
|
-
"version": "
|
|
33
|
+
"version": "7.0.0"
|
|
34
34
|
}
|
|
@@ -43,7 +43,6 @@ const {isArray} = Array;
|
|
|
43
43
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
44
44
|
hops: [{
|
|
45
45
|
channel: <Standard Format Channel Id String>
|
|
46
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
47
46
|
fee: <Fee Number>
|
|
48
47
|
fee_mtokens: <Fee Millitokens String>
|
|
49
48
|
forward: <Forward Tokens Number>
|
|
@@ -71,7 +71,6 @@ const tokensAsMillitokens = tokens => BigInt(tokens) * BigInt(1e3);
|
|
|
71
71
|
fee_mtokens: <Fee Paid Millitokens String>
|
|
72
72
|
hops: [{
|
|
73
73
|
channel: <Standard Format Channel Id String>
|
|
74
|
-
channel_capacity: <Hop Channel Capacity Tokens Number>
|
|
75
74
|
fee_mtokens: <Hop Forward Fee Millitokens String>
|
|
76
75
|
forward_mtokens: <Hop Forwarded Millitokens String>
|
|
77
76
|
timeout: <Hop CLTV Expiry Block Height Number>
|
|
@@ -85,7 +84,6 @@ const tokensAsMillitokens = tokens => BigInt(tokens) * BigInt(1e3);
|
|
|
85
84
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
86
85
|
hops: [{
|
|
87
86
|
channel: <Standard Format Channel Id String>
|
|
88
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
89
87
|
fee: <Fee Number>
|
|
90
88
|
fee_mtokens: <Fee Millitokens String>
|
|
91
89
|
forward: <Forward Tokens Number>
|
|
@@ -110,7 +108,6 @@ const tokensAsMillitokens = tokens => BigInt(tokens) * BigInt(1e3);
|
|
|
110
108
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
111
109
|
hops: [{
|
|
112
110
|
channel: <Standard Format Channel Id String>
|
|
113
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
114
111
|
fee: <Fee Number>
|
|
115
112
|
fee_mtokens: <Fee Millitokens String>
|
|
116
113
|
forward: <Forward Tokens Number>
|
|
@@ -145,7 +142,6 @@ const tokensAsMillitokens = tokens => BigInt(tokens) * BigInt(1e3);
|
|
|
145
142
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
146
143
|
hops: [{
|
|
147
144
|
channel: <Standard Format Channel Id String>
|
|
148
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
149
145
|
fee: <Fee Number>
|
|
150
146
|
fee_mtokens: <Fee Millitokens String>
|
|
151
147
|
forward: <Forward Tokens Number>
|
|
@@ -176,7 +172,6 @@ const tokensAsMillitokens = tokens => BigInt(tokens) * BigInt(1e3);
|
|
|
176
172
|
fee_mtokens: <Fee Paid Millitokens String>
|
|
177
173
|
hops: [{
|
|
178
174
|
channel: <Standard Format Channel Id String>
|
|
179
|
-
channel_capacity: <Hop Channel Capacity Tokens Number>
|
|
180
175
|
fee_mtokens: <Hop Forward Fee Millitokens String>
|
|
181
176
|
forward_mtokens: <Hop Forwarded Millitokens String>
|
|
182
177
|
timeout: <Hop CLTV Expiry Block Height Number>
|
|
@@ -190,7 +185,6 @@ const tokensAsMillitokens = tokens => BigInt(tokens) * BigInt(1e3);
|
|
|
190
185
|
fee_mtokens: <Total Fee Millitokens To Pay String>
|
|
191
186
|
hops: [{
|
|
192
187
|
channel: <Standard Format Channel Id String>
|
|
193
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
194
188
|
fee: <Fee Number>
|
|
195
189
|
fee_mtokens: <Fee Millitokens String>
|
|
196
190
|
forward: <Forward Tokens Number>
|
|
@@ -44,7 +44,6 @@ const payWithTimeout = timeout => asyncTimeout(payViaRoutes, timeout);
|
|
|
44
44
|
fee_mtokens: <Route Fee Millitokens String>
|
|
45
45
|
hops: [{
|
|
46
46
|
channel: <Standard Format Channel Id String>
|
|
47
|
-
channel_capacity: <Channel Capacity Tokens Number>
|
|
48
47
|
fee: <Fee Number>
|
|
49
48
|
fee_mtokens: <Fee Millitokens String>
|
|
50
49
|
forward: <Forward Tokens Number>
|
|
@@ -249,7 +249,6 @@ const tests = [
|
|
|
249
249
|
routes: [{
|
|
250
250
|
hops: [{
|
|
251
251
|
amt_to_forward_msat: '1',
|
|
252
|
-
chan_capacity: '1',
|
|
253
252
|
chan_id: '1',
|
|
254
253
|
custom_records: {},
|
|
255
254
|
expiry: 1,
|
|
@@ -364,7 +363,6 @@ const tests = [
|
|
|
364
363
|
routes: [{
|
|
365
364
|
hops: [{
|
|
366
365
|
amt_to_forward_msat: '1',
|
|
367
|
-
chan_capacity: '1',
|
|
368
366
|
chan_id: '1',
|
|
369
367
|
custom_records: {},
|
|
370
368
|
expiry: 1,
|
|
@@ -394,7 +392,6 @@ const tests = [
|
|
|
394
392
|
fee_mtokens: '1',
|
|
395
393
|
hops: [{
|
|
396
394
|
channel: '0x0x1',
|
|
397
|
-
channel_capacity: 1,
|
|
398
395
|
fee: 0,
|
|
399
396
|
fee_mtokens: '1',
|
|
400
397
|
forward: 0,
|
|
@@ -422,7 +419,6 @@ const tests = [
|
|
|
422
419
|
fee_mtokens: '1',
|
|
423
420
|
hops: [{
|
|
424
421
|
channel: '0x0x1',
|
|
425
|
-
channel_capacity: 1,
|
|
426
422
|
fee: 0,
|
|
427
423
|
fee_mtokens: '1',
|
|
428
424
|
forward: 0,
|
|
@@ -213,7 +213,6 @@ const tests = [
|
|
|
213
213
|
routes: [{
|
|
214
214
|
hops: [{
|
|
215
215
|
amt_to_forward_msat: '1',
|
|
216
|
-
chan_capacity: '1',
|
|
217
216
|
chan_id: '1',
|
|
218
217
|
custom_records: {},
|
|
219
218
|
expiry: 1,
|
|
@@ -256,7 +255,6 @@ const tests = [
|
|
|
256
255
|
fee_mtokens: '1',
|
|
257
256
|
hops: [{
|
|
258
257
|
channel: '0x0x1',
|
|
259
|
-
channel_capacity: 1,
|
|
260
258
|
fee: 0,
|
|
261
259
|
fee_mtokens: '1',
|
|
262
260
|
forward: 0,
|
|
@@ -284,7 +282,6 @@ const tests = [
|
|
|
284
282
|
fee_mtokens: '1',
|
|
285
283
|
hops: [{
|
|
286
284
|
channel: '0x0x1',
|
|
287
|
-
channel_capacity: 1,
|
|
288
285
|
fee: 0,
|
|
289
286
|
fee_mtokens: '1',
|
|
290
287
|
forward: 0,
|
|
@@ -47,7 +47,6 @@ const makeExpected = overrides => {
|
|
|
47
47
|
fee_mtokens: '0',
|
|
48
48
|
hops: [{
|
|
49
49
|
channel: '0x0x1',
|
|
50
|
-
channel_capacity: 1,
|
|
51
50
|
fee: 0,
|
|
52
51
|
fee_mtokens: '0',
|
|
53
52
|
forward: 0,
|
|
@@ -166,6 +165,10 @@ tests.forEach(({args, description, error, expected}) => {
|
|
|
166
165
|
} else {
|
|
167
166
|
const route = await getRouteForPayment(args);
|
|
168
167
|
|
|
168
|
+
route.route.hops.forEach(hop => {
|
|
169
|
+
delete hop.channel_capacity;
|
|
170
|
+
});
|
|
171
|
+
|
|
169
172
|
strictSame(route, expected, 'Got expected route');
|
|
170
173
|
}
|
|
171
174
|
|