lightningnetwork / lnd

Lightning Network Daemon ⚡️
MIT License
7.7k stars 2.09k forks source link

[feature]: More Descriptive Error on Attempted Spend from Reserve #8957

Open levmi opened 3 months ago

levmi commented 3 months ago

Is your feature request related to a problem? Please describe. I've heard from developers that users get frustrated when they're onboarding to Lightning, set up a channel, then try to spend the an amount below the reserve threshold of that channel, but run into the channel reserve requirement. When they try to spend the full amount, the error returns as insufficient balance. The developer who flagged this actually believes that it could be impacting initial Lightning usage as people try Lightning out, it fails and they just move on.

Describe the solution you'd like It would be nice to have a more descriptive error here like Cannot Spend due to Channel Reserve or something along those lines. This would allow for developers to give more context to end users about what went wrong and better educate them on how to use Lightning.

Additional context Comes from the Voltage team

ziggie1984 commented 3 months ago

I think this relates to https://github.com/lightningnetwork/lnd/issues/8817, which would be even better to give devs the exact amount they can send on that channel.

jegamboafuentes commented 4 weeks ago

Hey @levmi! 👋

I saw your awesome issue and thought I'd let you know about Lightning Bounties! 🚀 It's a super easy-to-use app where you can add a Bitcoin reward to this issue, encouraging devs to jump in and help you solve it.

Here’s a quick tutorial to get started: Lightning Bounties Tutorial. 💡 You can post your issue there, set up a bounty, and whoever cracks the code gets rewarded instantly in Bitcoin. 🔥

Let me know if you have any questions or need help setting it up!

Cheers! ⚡