A failed fallback read of the listening sockets now raises instead of reading as "nothing listens".
fix(sockets): when the root read fails, the fallback read runs through _read, which raises with the command's error on a non-zero exit.
Tested: fixtures only (TestListeningSockets::test_a_failed_fallback_raises_instead_of_reading_as_no_sockets, failed before the fix). pytest, ruff, mypy, napalm-standard check/ratchet green.
A failed fallback read of the listening sockets now raises instead of reading as "nothing listens".
- `fix(sockets)`: when the root read fails, the fallback read runs through `_read`, which raises with the command's error on a non-zero exit.
Tested: fixtures only (`TestListeningSockets::test_a_failed_fallback_raises_instead_of_reading_as_no_sockets`, failed before the fix). pytest, ruff, mypy, `napalm-standard check`/`ratchet` green.
Closes #11
When the root reading failed, get_listening_sockets ran the fallback
without root and parsed its output without looking at the exit status.
A failing sockstat or netstat returned an empty list, which a caller
reads as every port closed. The fallback now goes through the reader
check and raises with the command's error.
Closes#11
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
A failed fallback read of the listening sockets now raises instead of reading as "nothing listens".
fix(sockets): when the root read fails, the fallback read runs through_read, which raises with the command's error on a non-zero exit.Tested: fixtures only (
TestListeningSockets::test_a_failed_fallback_raises_instead_of_reading_as_no_sockets, failed before the fix). pytest, ruff, mypy,napalm-standard check/ratchetgreen.Closes #11