Skip to content

feat: auto-swaps #1266

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 41 commits into
base: master
Choose a base branch
from
Open

feat: auto-swaps #1266

wants to merge 41 commits into from

Conversation

reneaaron
Copy link
Contributor

@reneaaron reneaaron commented Apr 16, 2025

TODOs

  • Do final testing with LDK/LND on mainnet
  • Improve fee display on the frontend, currently looks scary
  • Shift Swaps from settings (Agreeed to do in follow-up)
  • Add option to do one-time swaps (Agreeed to do in follow-up)

Minor

  • LDK_NETWORK config var should now be NETWORK
  • Use LNClient method to publish transactions (Do in follow-up?)

Testing

  • Phoenix
  • Cashu
  • Wails

@im-adithya im-adithya marked this pull request as ready for review April 18, 2025 13:05
@rolznz rolznz added this to the 1.17.0 milestone Apr 24, 2025
@jackstar12
Copy link

You can take this as a reference for implementing the fee check: BoltzExchange/boltz-client#423

@reneaaron reneaaron changed the title [WIP] feat: auto-swaps feat: auto-swaps Apr 29, 2025
@reneaaron reneaaron marked this pull request as draft April 29, 2025 08:22
@im-adithya im-adithya marked this pull request as ready for review April 30, 2025 13:55
@@ -435,7 +435,7 @@ func getMaxTotalRoutingFeeLimit(amountMsat uint64) ldk_node.MaxTotalRoutingFeeLi
}
}

func (ls *LDKService) SendPaymentSync(ctx context.Context, invoice string, amount *uint64) (*lnclient.PayInvoiceResponse, error) {
func (ls *LDKService) SendPaymentSync(ctx context.Context, invoice string, amount *uint64, isHoldInvoice bool) (*lnclient.PayInvoiceResponse, error) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure this is the best way to do it. This method is SendPaymentSync but now we are basically doing an async payment, right?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

edit: can we change it to timeout rather than isHoldInvoice?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants