From b9b0e422fd7572f7c23347b239828ebf6ba94ca9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20B=C3=BChler?= Date: Tue, 12 Apr 2022 12:13:29 +0200 Subject: [PATCH] fix typing in ipneigh --- src/capport/utils/ipneigh.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/capport/utils/ipneigh.py b/src/capport/utils/ipneigh.py index b5db69f..0a2df3c 100644 --- a/src/capport/utils/ipneigh.py +++ b/src/capport/utils/ipneigh.py @@ -66,7 +66,7 @@ class NeighborController: return None raise - async def dump_neighbors(self, interface: str) -> typing.Generator[typing.Tuple[cptypes.MacAddress, cptypes.IPAddress]]: + async def dump_neighbors(self, interface: str) -> typing.AsyncGenerator[typing.Tuple[cptypes.MacAddress, cptypes.IPAddress], None]: ifindex = socket.if_nametoindex(interface) unicast_num = pr2modules.netlink.rtnl.rt_type['unicast'] # ip.neigh doesn't support AF_UNSPEC (as it is 0 and evaluates to `False` and gets forced to AF_INET)