From dfc0dd83572069849f8e544a82467ec228404993 Mon Sep 17 00:00:00 2001 From: Alessandro Del Prete Date: Sun, 17 Mar 2024 17:37:59 +0100 Subject: [PATCH] - removed forced method from get_mac --- custom_components/sinapsi_alfa/api.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/custom_components/sinapsi_alfa/api.py b/custom_components/sinapsi_alfa/api.py index e42c0df..c0a978a 100644 --- a/custom_components/sinapsi_alfa/api.py +++ b/custom_components/sinapsi_alfa/api.py @@ -105,6 +105,7 @@ def get_mac_address(self) -> str: """Get mac address from ip/hostname.""" mac_address = None i = 0 + # we want to ensure a mac address if found, sometimes it takes more than 1 try while not mac_address and i < 10: if self.check_port(): _LOGGER.debug( @@ -115,7 +116,6 @@ def get_mac_address(self) -> str: f"Get_Mac_Address (ERROR): port not available on {self._host}:{self._port}" ) # Get MAC address from the ARP cache using the hostname - getmac.FORCE_METHOD = "ArpVariousArgs" mac_address = getmac.get_mac_address( hostname=self._host, network_request=False )