fixed zip related bugs (notably in install grub uefi)

master 3.7.1.3
parent b5993c5616
commit 6ef7e912f3

@ -1100,11 +1100,11 @@ class PartitionDistributive(Distributive):
def getMultipartData(self): def getMultipartData(self):
"""Get multipartition data""" """Get multipartition data"""
mulipartData = zip(self.multipartition.getPartitions(), mulipartData = list(zip(self.multipartition.getPartitions(),
self.multipartition.getMountPoints(), self.multipartition.getMountPoints(),
self.multipartition.getFileSystems(), self.multipartition.getFileSystems(),
self.multipartition.getIsFormat(), self.multipartition.getIsFormat(),
self.multipartition.getPartitionTable()) self.multipartition.getPartitionTable()))
return mulipartData return mulipartData
def convertToDirectory(self): def convertToDirectory(self):

@ -405,7 +405,7 @@ class Install(MethodsInterface):
labels = ["calculate%d" % i for i in range(1, len(efidirs) + 1)] labels = ["calculate%d" % i for i in range(1, len(efidirs) + 1)]
else: else:
labels = ["calculate"] labels = ["calculate"]
for efiname, efidir in reversed(zip(labels, efidirs)): for efiname, efidir in reversed(list(zip(labels, efidirs))):
self._install_grub_uefi(cmd_grub_install, prefix_boot, target, self._install_grub_uefi(cmd_grub_install, prefix_boot, target,
efidir, efiname) efidir, efiname)
# удаляем устаревшие # удаляем устаревшие

@ -540,7 +540,7 @@ class VariableOsInstallNetRouteData(NetHelper, TableVariable):
if not x[1] in ("off", "dhcp")] if not x[1] in ("off", "dhcp")]
route_data = [] route_data = []
if staticInterface: if staticInterface:
staticInterface, skipNet = zip(*staticInterface) staticInterface, skipNet = list(zip(*staticInterface))
return [[x[0], return [[x[0],
x[1].get('via', ''), x[1].get('via', ''),
x[1].get('dev', ''), x[1].get('dev', ''),
@ -675,10 +675,10 @@ class VariableOsInstallNetRoute(NetHelper, ReadonlyVariable):
""" """
def performRouteData(self, performFunc): def performRouteData(self, performFunc):
routeMatrix = zip(self.Get('os_install_net_route_network'), routeMatrix = list(zip(self.Get('os_install_net_route_network'),
self.Get('os_install_net_route_gw'), self.Get('os_install_net_route_gw'),
self.Get('os_install_net_route_dev'), self.Get('os_install_net_route_dev'),
self.Get('os_install_net_route_src')) self.Get('os_install_net_route_src')))
DEV, IP, CIDR, NET = 0, 1, 2, 1 DEV, IP, CIDR, NET = 0, 1, 2, 1
return [performFunc(x[DEV], x[NET], routeMatrix) for x return [performFunc(x[DEV], x[NET], routeMatrix) for x
# ip and mask to ip/net # ip and mask to ip/net

Loading…
Cancel
Save