question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

UNKNOWN_PAYMENT_HASH

See original GitHub issue

Using Python 2.7.15+ on Ubuntu 18.04, latest code from master, lnd version 0.7.0-beta commit=v0.7.0-beta-rc3 installed with routerrpc, latest requirements.txt installed with pip. I’m trying to rebalance a channel with the following command and getting an error. I’ve tried this with different “to” channels and different amounts and I get the same error.

$ python rebalance.py -f 627916797039411200 -t 630216975379267584 -a 500000 --max-fee-factor 3
Sending 500,000 satoshis to rebalance to channel with ID 630216975379267584
Forced first channel has ID 627916797039411200

Trying route #1
627916797039411200 -> 623648492953534464 -> 631089987556999169 -> 630216975379267584
failure {
  code: UNKNOWN_PAYMENT_HASH
  failure_source_pubkey: "\003\201\030\340I\017\215=\360{k\334^p4\336\351\rv\220\022vM1\277\353\026ri\206h$\360"
}

Unknown error code 1
Could not find any suitable route

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:8 (4 by maintainers)

github_iconTop GitHub Comments

2reactions
C-Ottocommented, Jul 15, 2019

I have plenty of information, thanks for reporting. I’ll work on this when I find the time.

2reactions
Fr4nZ82commented, Jul 8, 2019

Same for me, debian 9.9 Python 2.7.13 lnd 0.7.0-beta commit=v0.7.0-beta-6-gb16259592944ec12c7e47bc10b3b69e25d61950f

lnd logs:

2019-07-08 21:11:53.248 [ERR] CRTR: Attempt to send payment 8c859859c3eaa582720441cf286663ce43331b213a81110a2f29715642b7cd73 failed: UnknownNextPeer
2019-07-08 21:11:53.248 [WRN] CRTR: Failed to find route for payment 8c859859c3eaa582720441cf286663ce43331b213a81110a2f29715642b7cd73: pre-built route already tried
2019-07-08 21:11:54.664 [ERR] CRTR: Attempt to send payment 8c859859c3eaa582720441cf286663ce43331b213a81110a2f29715642b7cd73 failed: TemporaryChannelFailure(update=(*lnwire.ChannelUpdate)(0xc001a5c0b0)({
 Signature: (lnwire.Sig) (len=64 cap=64) {
  00000000  08 94 b7 44 46 34 03 aa  e8 dc c9 57 37 17 85 0c  |...DF4.....W7...|
  00000010  17 3b a7 ac 28 80 8f 44  e8 83 a2 0b 30 fd 0d 78  |.;..(..D....0..x|
  00000020  4a fa f4 27 9e 4f 52 4e  94 b9 60 2c 67 17 6b 3c  |J..'.ORN..`,g.k<|
  00000030  89 50 f2 8c 2b 73 81 ab  aa 28 35 f7 e7 e8 62 7e  |.P..+s...(5...b~|
 },
 ChainHash: (chainhash.Hash) (len=32 cap=32) 000000000019d6689c085ae165831e934ff763ae46a2a6c172b3f1b60a8ce26f,
 ShortChannelID: (lnwire.ShortChannelID) 532202:2187:0,
 Timestamp: (uint32) 1562598599,
 MessageFlags: (lnwire.ChanUpdateMsgFlags) 00000001,
 ChannelFlags: (lnwire.ChanUpdateChanFlags) 00000001,
 TimeLockDelta: (uint16) 144,
 HtlcMinimumMsat: (lnwire.MilliSatoshi) 1000 mSAT,
 BaseFee: (uint32) 0,
 FeeRate: (uint32) 1,
 HtlcMaximumMsat: (lnwire.MilliSatoshi) 1000000000 mSAT,
 ExtraOpaqueData: ([]uint8) <nil>
})
)
2019-07-08 21:11:54.665 [WRN] CRTR: Failed to find route for payment 8c859859c3eaa582720441cf286663ce43331b213a81110a2f29715642b7cd73: pre-built route already tried
2019-07-08 21:11:56.131 [ERR] CRTR: Attempt to send payment 8c859859c3eaa582720441cf286663ce43331b213a81110a2f29715642b7cd73 failed: TemporaryChannelFailure(update=(*lnwire.ChannelUpdate)(0xc001a5c210)({
 Signature: (lnwire.Sig) (len=64 cap=64) {
  00000000  f0 42 99 22 8e 1e 22 99  6c 9c 6f 5a 97 5e 6d 8f  |.B."..".l.oZ.^m.|
  00000010  0c 66 1b 1f 79 55 05 8d  86 12 39 af be 15 ce 03  |.f..yU....9.....|
  00000020  2b 29 0c 98 9f 76 07 77  5d 56 df de 64 0d 8a 26  |+)...v.w]V..d..&|
  00000030  a5 77 5b 60 00 2b 39 76  2e 71 a8 0d a6 d9 1a 5f  |.w[`.+9v.q....._|
 },
 ChainHash: (chainhash.Hash) (len=32 cap=32) 000000000019d6689c085ae165831e934ff763ae46a2a6c172b3f1b60a8ce26f,
 ShortChannelID: (lnwire.ShortChannelID) 565435:791:0,
 Timestamp: (uint32) 1562600399,
 MessageFlags: (lnwire.ChanUpdateMsgFlags) 00000001,
 ChannelFlags: (lnwire.ChanUpdateChanFlags) 00000001,
 TimeLockDelta: (uint16) 144,
 HtlcMinimumMsat: (lnwire.MilliSatoshi) 18 mSAT,
 BaseFee: (uint32) 0,
 FeeRate: (uint32) 1,
 HtlcMaximumMsat: (lnwire.MilliSatoshi) 15000000000 mSAT,
 ExtraOpaqueData: ([]uint8) <nil>
})
)
2019-07-08 21:11:56.132 [WRN] CRTR: Failed to find route for payment 8c859859c3eaa582720441cf286663ce43331b213a81110a2f29715642b7cd73: pre-built route already tried
2019-07-08 21:11:57.521 [ERR] CRTR: Attempt to send payment 8c859859c3eaa582720441cf286663ce43331b213a81110a2f29715642b7cd73 failed: TemporaryChannelFailure(update=(*lnwire.ChannelUpdate)(0xc001a5c0b0)({
 Signature: (lnwire.Sig) (len=64 cap=64) {
  00000000  8e e2 ff f6 d5 dd cb db  66 8a 18 8b 4e 9d 25 ad  |........f...N.%.|
  00000010  ed 37 54 dc d1 7e 1d 98  a3 4a c1 59 ce 78 b1 92  |.7T..~...J.Y.x..|
  00000020  62 06 cb e9 46 69 fc 99  57 63 39 d0 59 be 46 95  |b...Fi..Wc9.Y.F.|
  00000030  44 3e 93 2a d3 36 40 30  00 92 2c 8f 20 17 22 01  |D>.*.6@0..,. .".|
 },
 ChainHash: (chainhash.Hash) (len=32 cap=32) 000000000019d6689c085ae165831e934ff763ae46a2a6c172b3f1b60a8ce26f,
 ShortChannelID: (lnwire.ShortChannelID) 565730:996:1,
 Timestamp: (uint32) 1562598082,
 MessageFlags: (lnwire.ChanUpdateMsgFlags) 00000001,
 ChannelFlags: (lnwire.ChanUpdateChanFlags) 00000001,
 TimeLockDelta: (uint16) 144,
 HtlcMinimumMsat: (lnwire.MilliSatoshi) 18 mSAT,
 BaseFee: (uint32) 0,
 FeeRate: (uint32) 1,
 HtlcMaximumMsat: (lnwire.MilliSatoshi) 990000000 mSAT,
 ExtraOpaqueData: ([]uint8) <nil>
})
)
2019-07-08 21:11:57.522 [WRN] CRTR: Failed to find route for payment 8c859859c3eaa582720441cf286663ce43331b213a81110a2f29715642b7cd73: pre-built route already tried
2019-07-08 21:12:01.732 [ERR] CRTR: Attempt to send payment 8c859859c3eaa582720441cf286663ce43331b213a81110a2f29715642b7cd73 failed: UnknownPaymentHash(amt=99999250 mSAT)
2019-07-08 21:12:01.732 [ERR] CRTR: Payment 8c859859c3eaa582720441cf286663ce43331b213a81110a2f29715642b7cd73 failed with final outcome: UnknownPaymentHash(amt=99999250 mSAT)
Read more comments on GitHub >

github_iconTop Results From Across the Web

Unknown payment hash 000000000000000000 #2467 - GitHub
Prior to sending coins, they were able to pay each other using the same channel(s) without issue. This error started to occur after...
Read more >
channelmanager.rs - source - Docs.rs
Also, ensure that, in the case of an unknown payment hash, our payment logic has enough time to fail the HTLC backward //...
Read more >
lndclient - Go Packages
PaymentResultUnknownPaymentHash = "UnknownPaymentHash" // PaymentResultSuccess is the string result returned by SendPayment // when the ...
Read more >
[Lightning-dev] In-protocol liquidity probing and channel ...
A practice that is widely applied by lightning wallets is to probe routes with an unknown payment hash before making the actual payment....
Read more >
Improvements of the Balance Discovery Attack on Lightning ...
if response = UnknownPaymentHash then. 17: if bwidth.min < flow then. 18: bwidth.min ← flow. 19: end if. 20: else if response =...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found