Patchwork [bitbake-devel,1/1] bitbake-layers: fix duplicated help info

mail settings
Submitter Robert Yang
Date March 6, 2013, 5:36 a.m.
Message ID <>
Download mbox | patch
Permalink /patch/45577/
State New
Headers show


Robert Yang - March 6, 2013, 5:36 a.m.
There are two "help" lines when run bitbake help under python 2.6.6
(perhaps all python 2.6):

$ bitbake-layers help
    display general help or help on a specified command
    display general help or help on a specified command

This is because the in python 2.6.6 also has a do_help() function
as our bitbake-layers, and the cmd.Cmd.get_names() doesn't consider the
overload, this has been fixed in python 2.7, use set() to remove the
duplicated would fix the problem.

[YOCTO #3428]

Signed-off-by: Robert Yang <>
 bitbake/bin/bitbake-layers |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)


diff --git a/bitbake/bin/bitbake-layers b/bitbake/bin/bitbake-layers
index b48590f..86da268 100755
--- a/bitbake/bin/bitbake-layers
+++ b/bitbake/bin/bitbake-layers
@@ -73,7 +73,7 @@  class Commands(cmd.Cmd):
             sys.stdout.write("usage: bitbake-layers <command> [arguments]\n\n")
             sys.stdout.write("Available commands:\n")
-            procnames = self.get_names()
+            procnames = list(set(self.get_names()))
             for procname in procnames:
                 if procname[:3] == 'do_':
                     sys.stdout.write("  %s\n" % procname[3:].replace('_', '-'))