Skip to content

Commit

Permalink
paytest: Fix issue with payments destined for the current node
Browse files Browse the repository at this point in the history
See previous commit for details.
  • Loading branch information
cdecker authored and m-schmoock committed Mar 25, 2021
1 parent fb77c49 commit efd1b7e
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
2 changes: 1 addition & 1 deletion paytest/paytest.py
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ def on_htlc_accepted(onion, htlc, request, plugin, *args, **kwargs):
)
)
# If this is not a test payment, pass it on
if onion["short_channel_id"] != "1x1x1":
if 'short_channel_id' not in onion or onion["short_channel_id"] != "1x1x1":
return request.set_result({"result": "continue"})

# Decode the onion so we get the details the virtual recipient
Expand Down
1 change: 0 additions & 1 deletion paytest/test_paytest.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@ def test_mpp_pay(node_factory):
assert len(is16399) >= 1


@pytest.mark.xfail(strict=True)
def test_incoming_payment(node_factory):
"""Ensure that we don't fail if the payment is not a paytest.
"""
Expand Down

0 comments on commit efd1b7e

Please sign in to comment.