TestOpenClose.test_open_raises_connection_exception_on_error (tests/unit/test_driver.py:128-136) builds a driver for hostname="unreachable.invalid" and calls drv.open() without patching anything. open() creates a real requests.Session and GETs /api/core/system/status, so the unit test resolves the name through the machine's resolver and depends on it failing quickly. On a host with a slow or unreachable resolver the test waits for the resolver timeout; with a search domain or a resolver that answers every name, it tries to connect.
napalm-fritzbox's test of the same name patches the connection instead.
Expected
The test patches requests.Session.get (or _get) to raise requests.ConnectionError and asserts ConnectionException and session is None. No unit test touches the network.
Priority: P4 — a non-hermetic unit test.
Found during the bug sweep of 2026-11-01.
## What happens
`TestOpenClose.test_open_raises_connection_exception_on_error` (`tests/unit/test_driver.py:128-136`) builds a driver for `hostname="unreachable.invalid"` and calls `drv.open()` without patching anything. `open()` creates a real `requests.Session` and GETs `/api/core/system/status`, so the unit test resolves the name through the machine's resolver and depends on it failing quickly. On a host with a slow or unreachable resolver the test waits for the resolver timeout; with a search domain or a resolver that answers every name, it tries to connect.
napalm-fritzbox's test of the same name patches the connection instead.
## Expected
The test patches `requests.Session.get` (or `_get`) to raise `requests.ConnectionError` and asserts `ConnectionException` and `session is None`. No unit test touches the network.
Priority: P4 — a non-hermetic unit test.
Found during the bug sweep of 2026-11-01.
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.
What happens
TestOpenClose.test_open_raises_connection_exception_on_error(tests/unit/test_driver.py:128-136) builds a driver forhostname="unreachable.invalid"and callsdrv.open()without patching anything.open()creates a realrequests.Sessionand GETs/api/core/system/status, so the unit test resolves the name through the machine's resolver and depends on it failing quickly. On a host with a slow or unreachable resolver the test waits for the resolver timeout; with a search domain or a resolver that answers every name, it tries to connect.napalm-fritzbox's test of the same name patches the connection instead.
Expected
The test patches
requests.Session.get(or_get) to raiserequests.ConnectionErrorand assertsConnectionExceptionandsession is None. No unit test touches the network.Priority: P4 — a non-hermetic unit test.
Found during the bug sweep of 2026-11-01.