Skip to contentSkip to conversation

rootfs.py: fix logic error so that warnings are checked

PATCH New Chen Qi 1 participant 2 messages Mar 12, 2015

lore
Share & tools
lore

Chen Qi

author
#0 lore raw

cover rootfs.py: fix logic error so that warnings are checked

The following changes since commit 99f209a49a4390192b95184ff86bd6f973010111:

layer.conf: bump version as error-report interface changed (2015-03-10 17:44:56 +0000)

are available in the git repository at:

git://git.openembedded.org/openembedded-core-contrib ChenQi/rootfs-log-check
http://cgit.openembedded.org/cgit.cgi/openembedded-core-contrib/log/?h=ChenQi/rootfs-log-check

Chen Qi (1):
rootfs.py: fix logic error so that warnings are checked

 meta/lib/oe/rootfs.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Signature · 1 line
1.9.1
author
#1 lore raw

PATCH 1/1 rootfs.py: fix logic error so that warnings are checked

The following commit caused log checking for warnings not working for RPM rootfs.

rootfs.py: ignore "NOTE:" when catching warnings

The problem is that checking for warnings is always skipped because the following statement is always true.

if 'log_check' or 'NOTE:' in line:

This patch fixes the above problem so that warning checking in RPM rootfs can work again.

---
 meta/lib/oe/rootfs.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/lib/oe/rootfs.py +1 -1
index dd7aa44..7e8d5d1 100644
@@ -359,7 +359,7 @@ class RpmRootfs(Rootfs):
         log_path = self.d.expand("${T}/log.do_rootfs")
         with open(log_path, 'r') as log:
             for line in log.read().split('\n'):
-                if 'log_check' or 'NOTE:' in line:
+                if 'log_check' in line or 'NOTE:' in line:
                     continue
 
                 m = r.search(line)
Signature · 1 line
1.9.1