Patchwork [bitbake-devel] cooker: Get rid of duplicate 'import re'

login
register
mail settings
Submitter Namhyung Kim
Date July 30, 2014, 2:17 a.m.
Message ID <1406686640-8785-1-git-send-email-namhyung@gmail.com>
Download mbox | patch
Permalink /patch/76891/
State New
Headers show

Comments

Namhyung Kim - July 30, 2014, 2:17 a.m.
The re module was imported at the top, no need to do it again.

Signed-off-by: Namhyung Kim <namhyung@gmail.com>
---
 lib/bb/cooker.py | 2 --
 1 file changed, 2 deletions(-)

Patch

diff --git a/lib/bb/cooker.py b/lib/bb/cooker.py
index ecb3f9b..2c7788e 100644
--- a/lib/bb/cooker.py
+++ b/lib/bb/cooker.py
@@ -818,7 +818,6 @@  class BBCooker:
         or to find all machine configuration files one could call:
         findFilesMatchingInDir(self, 'conf/machines', 'conf')
         """
-        import re
 
         matches = []
         p = re.compile(re.escape(filepattern))
@@ -1228,7 +1227,6 @@  class BBCooker:
         '''
         Create a new image with a "require"/"inherit" base_image statement
         '''
-        import re
         if timestamp:
             image_name = os.path.splitext(image)[0]
             timestr = time.strftime("-%Y%m%d-%H%M%S")