Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upAvoid adding all private channels with the same peer as hop hints in new invoices #4520
Comments
|
This is critical when displaying an invoice in QR code. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment


Background
When a node has multiple private channels with the same peer, the hop hints in their payment requests will be populated with multiple channels. The purpose of these hop hints is to specify the next node's key and indicate the fees and cltv delta needed for route construction.
In pathfinding, due to non-strict forwarding, an LND node paying to this destination will only use the maximal policy values across these multiple hinted channels.
Since it only uses the maximal policy values in order to be an acceptable forward over any channel, the creator of the invoice may as well save some space in the payment request by pre-calculating the maximal policy values and compressing multiple private channels with the same peer into a single set of edge policy values
Your environment
Steps to reproduce
Expected behavior
Actual behavior