-
Notifications
You must be signed in to change notification settings - Fork 65
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
Examples on MacOS #170
Comments
Hi, thanks for giving it a try on mac. If you give us the commands you are using to setup the two nodes we can better look into it |
I confirmed that the error has been reproduced with the commands (on mac): # Node1
cargo run --example find_nodes -- \
--enr-ip4 127.0.0.1 \
--port 9000 # Node2
RUST_LOG=trace cargo run --example find_nodes -- \
--enr-ip4 127.0.0.1 \
--port 9001 \
--remote-peer=(Node1 ENR) Then the TRACE log below occurs in Node2.
Also I confirmed that this issue doesn't occur on the two-sockets branch we are working on. |
Oh nice. So I guess the best solution is to get the two-socket branch down. |
Hey @arsenron could you give this a try again using master? You can run |
@divagant-martian Everything now works, thanks! |
Hi! I tried to run
find_nodes
example on MacOS to setup two "nodes" on localhost and it was a little bit unclear how to setup this. On Linux everything worked fine.The problem is that by default
SocketKind
is dual stack (ip4 + ip6), so I supposed it should work when I bind to "ip6 socket" , which is by default, and try to send packets to the "ip4 socket". But I failed it to work and was getting an IO error:Error: Os { code: 22, kind: InvalidInput, message: "Invalid argument" }
. The solution is to bind to the ip4 socket, but the error itself is very unclear and maybe it should be addressed to tokio itself, but could we make it more clear in the example documentation for MacOS? Or find some other ways like adding conditional compilation and require to specifySocketKind
when#[cfg(target_os = "macos")]
?The text was updated successfully, but these errors were encountered: