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
The current implementation does not return the correct mac address. In my scenario the MAC address returned is in Hex-String format. It throws a
TypeError: 'str' object cannot be interpreted as an integer
Which is correct since the mac_address function uses ":".join([hex(c).lstrip("0x").zfill(2) for c in string])
which is correct since hex(c) expects an integer not a string.
I tried bypassing the function all together but that too doesn't return the expected output. The mac address seems to be encoded.
Is there a way to get the actual value returned by the SNMP get/walk?
In my own implementation of mac_address the correct address is returned by the following code: ':'.join(mac[i:i + 2] for i in range(2, 12, 2))
But this too won't work unless the actual raw value or value.prettyPrint() is passed to it.
The text was updated successfully, but these errors were encountered:
The current implementation does not return the correct mac address. In my scenario the MAC address returned is in Hex-String format. It throws a
Which is correct since the mac_address function uses
":".join([hex(c).lstrip("0x").zfill(2) for c in string])
which is correct since hex(c) expects an integer not a string.
I tried bypassing the function all together but that too doesn't return the expected output. The mac address seems to be encoded.
Is there a way to get the actual value returned by the SNMP get/walk?
In my own implementation of mac_address the correct address is returned by the following code:
':'.join(mac[i:i + 2] for i in range(2, 12, 2))
But this too won't work unless the actual raw value or value.prettyPrint() is passed to it.
The text was updated successfully, but these errors were encountered: