From 5ab273a3f6d8b27c9035c972286b0bf40a3550b2 Mon Sep 17 00:00:00 2001 From: Gilles DAVID Date: Fri, 31 Mar 2017 11:58:13 +0200 Subject: [PATCH] [PY3] Remove obsolete imports --- module_generator/pycompo.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/module_generator/pycompo.py b/module_generator/pycompo.py index 1879666..74218d2 100644 --- a/module_generator/pycompo.py +++ b/module_generator/pycompo.py @@ -24,15 +24,14 @@ import os from module_generator.gener import Component, Invalid from module_generator.pyth_tmpl import pyinitService, pyService, pyCompoEXE, pyCompo, cmake_src_compo_py import textwrap -from string import split,rstrip,join def indent(text, prefix=' '): """Indent text by prepending a given prefix to each line.""" if not text: return '' - lines = split(text, '\n') + lines = text.split('\n') lines = list(map(lambda line, prefix=prefix: prefix + line, lines)) - if lines: lines[-1] = rstrip(lines[-1]) - return join(lines, '\n') + if lines: lines[-1] = lines[-1].rstrip() + return '\n'.join(lines) class PYComponent(Component): """ -- 2.39.2