Skip to content

Conversation

@Lederstrumpf
Copy link
Member

PeerConnection::connect_brontozaur(local_node, remote_node)
.expect("Unable to connect to the remote peer")

let mut connection = PeerConnection::connect_brontozaur(local_node, remote_node);
Copy link
Member

@sedited sedited Oct 5, 2022

Choose a reason for hiding this comment

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

This is a hard idea to realize. The way the patch is right now, the user will never understand what is going on when the connection is failing in the cli, or a future gui, and has to look at the logs for diagnostics. If you fail seconds later, the farcaster daemon will never report the failure either and expect the connection to come up eventually, because it expects the connection to be up within 1 second. If you move this to the farcaster call site, you add further dependence on the delay introduced for waiting on the connection.

I think the right thing to do here is refactor peerd to launch its internal zmq runtime no matter what and independently manage its remote session from within its runtime. Then it can send errors directly to farcasterd.

@sedited
Copy link
Member

sedited commented Nov 28, 2022

Closing this in favor of #792 - a failed to connect is now cleanly aborts taking a swap with an error message to the user.

@sedited sedited closed this Nov 28, 2022
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.

taker peerd panics if maker peerd times out during connection setup

2 participants