Antoni Segura Puimedon has posted comments on this change. Change subject: Prettify/simplify netinfo.py:get() ......................................................................
Patch Set 3: Code-Review-1 (1 comment) .................................................... File lib/vdsm/netinfo.py Line 529: def getNonHiddenLinks(): Line 530: for link in getLinks(): Line 531: if not link.isHidden(): Line 532: yield link Line 533: notHiddenLinks = (link for link in getLinks() if not link.isHidden()) That would preclude the need for the extra method, it is more efficient (generators with this syntax are) and conveys the same info in a more readable way. Line 534: d = defaultdict(dict) Line 535: gateways = getRoutes() Line 536: ipv6routes = getIPv6Routes() Line 537: paddr = permAddr() -- To view, visit http://gerrit.ovirt.org/21652 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I70379b24084fa8bec88425de9eca106e2a6ae8f0 Gerrit-PatchSet: 3 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Assaf Muller <[email protected]> Gerrit-Reviewer: Antoni Segura Puimedon <[email protected]> Gerrit-Reviewer: Assaf Muller <[email protected]> Gerrit-Reviewer: Dan Kenigsberg <[email protected]> Gerrit-Reviewer: Nir Soffer <[email protected]> Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes _______________________________________________ vdsm-patches mailing list [email protected] https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
