1
0

Merge pull request #9433 from f321x/change_onion_message

Change OnionFailureCode returned when failing trampoline forwarding
This commit is contained in:
ThomasV
2025-01-15 13:46:41 +01:00
committed by GitHub

View File

@@ -2016,7 +2016,7 @@ class Peer(Logger, EventListener):
self.logger.debug(
f"maybe_forward_trampoline. PaymentFailure for {payment_hash.hex()=}, {payment_secret.hex()=}: {e!r}")
# FIXME: adapt the error code
raise OnionRoutingFailure(code=OnionFailureCode.UNKNOWN_NEXT_PEER, data=b'')
raise OnionRoutingFailure(code=OnionFailureCode.TRAMPOLINE_FEE_INSUFFICIENT, data=b'')
def _maybe_refuse_to_forward_htlc_that_corresponds_to_payreq_we_created(self, payment_hash: bytes) -> bool:
"""Returns True if the HTLC should be failed.