Conversation
erikh
left a comment
There was a problem hiding this comment.
These are suggestions I have for the betterment of the user experience, I hope you agree they are worthwhile changes.
Thanks!
tests/service/mod.rs
Outdated
| let (tcp_socket, udp_socket) = match Server::bind(ip.ip()).await { | ||
| Ok(x) => x, | ||
| Err(_) => { | ||
| panic!("Could not bind port"); |
There was a problem hiding this comment.
might be better to change the sig of the return value to return Result<Vec<_>, anyhow::Error> so the original error doesn't get swallowed.
There was a problem hiding this comment.
Took a stab at that but then I'd have to change the signature Service::new and then of every test, so...
People running zeronsd tests can figure it out :)
There was a problem hiding this comment.
I'm not sure that's the best way, but I won't argue with you. :P
7c59e43 to
9a75376
Compare
|
Thanks. I couldn't get that to work for some reason and you motivated me to fix it. Now it makes errors that look like this: |
tokio is was eating the panics and continuing on with no socket listening on 53 making tokio crash would take a bunch of rewrite i think, so i moved the `bind` calls out to a different, non-async fn
9a75376 to
7a67efa
Compare
|
Glad to be of help! I hadn't used |
tokio is was eating the panics and continuing on
with no socket listening on 53
making tokio crash would take a bunch of rewrite,
i think, so i moved the
bindcalls out to a different fnThe error looks like this: