You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I suspect this issue is also why the test for isup in test_linux.py was disabled - the test was looking for the RUNNING flag but the code was looking at the UP flag. Thus if there was an interface that was administratively up but didn't have a cable connected, it would fail the test suite. In this case, the test failing was correct since the code wasn't actually checking the correct flag.
This same issue is also mentioned in relation to OSX Wireless status in #805.
The text was updated successfully, but these errors were encountered:
I cannot disconnect the Ethernet cable on Windows because it's virtualized, but I did ipconfig /release (release IP address assigned by DHCP) and the status keeps being MIB_IF_OPER_STATUS_OPERATIONAL, which seems correct (the same as on Linux). As such, it appears Windows code is fine as it is.
Platform
Bug description
On Linux, the value of
isup
for network interfaces isn't accurate to the operational state of the interface (i.e. link is up).Currently the code looks for the flag
IFF_UP
to set the value ofisup
. However, theIFF_UP
flag only represents the interface being administratively up (i.e. not disabled) but not the operational state (i.e. connected). The operational state is represented by theIFF_RUNNING
flag.https://www.kernel.org/doc/Documentation/networking/operstates.txt
https://stackoverflow.com/questions/11679514/what-is-the-difference-between-iff-up-and-iff-running
I suspect this issue is also why the test for
isup
intest_linux.py
was disabled - the test was looking for theRUNNING
flag but the code was looking at theUP
flag. Thus if there was an interface that was administratively up but didn't have a cable connected, it would fail the test suite. In this case, the test failing was correct since the code wasn't actually checking the correct flag.This same issue is also mentioned in relation to OSX Wireless status in #805.
The text was updated successfully, but these errors were encountered: