Skip to content
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

swaps: Update submarine swap nostr relays dynamically and remove redundant query #9640

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

f321x
Copy link
Member

@f321x f321x commented Mar 14, 2025

Dynamically update the nostr relays used for submarine swaps so the client connects to relays provided by the swap provider. This allows the client to use a swap provider even if they have non overlapping relays and the client just got the announcement of the provider because it spreaded to the clients relay.
Also removes redundant query (get_pairs() and renames previous get_offers() to get_pairs()) when initializing NostrTransport, there is no need to query all announcements and additionally query the announcement from a specific npub, we can just use the announcement returned by the broad query we run anyways.

@f321x f321x changed the title Update submarine swap nostr relays dynamically Update submarine swap nostr relays dynamically and remove redundant query Mar 19, 2025
@f321x f321x force-pushed the swap_dm_relays branch 2 times, most recently from 53a7854 to 5ee4e56 Compare March 19, 2025 16:21
@f321x f321x marked this pull request as ready for review March 19, 2025 16:37
@f321x f321x force-pushed the swap_dm_relays branch 3 times, most recently from 99d7978 to dfca7a1 Compare March 20, 2025 15:04
@hany246

This comment was marked as spam.

@hany246

This comment was marked as spam.

@f321x f321x force-pushed the swap_dm_relays branch 3 times, most recently from 884e470 to 8ca5b16 Compare March 21, 2025 08:30
@f321x f321x changed the title Update submarine swap nostr relays dynamically and remove redundant query swaps: Update submarine swap nostr relays dynamically and remove redundant query Mar 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants