Closed felinira closed 2 years ago
Oh wow that code path has a lot of missing error handling :see_no_evil:
Fixes are on dev
. Let me know if that way of error handling is appropriate for you.
Thanks! Error handling looks fine to me, everything that is not a panic makes me happy^^.
It appears to have not been enough though for this particular problem: https://gitlab.gnome.org/felinira/warp/-/issues/8#note_1460858
It seems to panic here now 🙊
thread 'smol-1' panicked at 'assertion failed: socket.is_some() == our_abilities.can_direct()', /run/build/warp/cargo/vendor/magic-wormhole/src/transit.rs:1036:9
Oops forgot about that one, sorry ^^. Technically that assertion is redundant anyways, but it could also be weakened to the implication assert!(socket.is_none() || our_abilities.can_direct());
.
That being said, I don't feel happy about this progression. It feels like some weird silent failure case but also without a good possibility to expose the error. Maybe I'll try building in a fallback that is not IPv6 specific to make this work again.
Are there any other scenarios where binding a local port may fail but the transfer can still take place?
This seems to have fixed it.
Currently the library panics if IPv6 is disabled via sysctl.
thread 'smol-1' panicked at 'called `Result::unwrap()` on an `Err` value: Os { code: 97, kind: Uncategorized, message: "Address family not supported by protocol" }', /run/build/warp/cargo/vendor/magic-wormhole/src/transit.rs:752:30