[gnome-continuous-yocto/gnomeostree-3.28-rocko: 1156/8267] scripts/lib/bsp/help.py: Fixed pager for yocto-bsp help



commit 71bc7fd8ce9ba4db13ca82f56ff7d8ab8b2a279f
Author: Humberto Ibarra <humberto ibarra lopez intel com>
Date:   Sat Jul 2 13:17:56 2016 -0500

    scripts/lib/bsp/help.py: Fixed pager for yocto-bsp help
    
    Python3 requires strings to be encoded as bytes before sending them through a subprocess pipe. The 
help.py file is not considering this and fails when issuing paged help commands. This patch adds this 
encoding to solve the problem.
    
    [YOCTO #9868]
    
    (From meta-yocto rev: 35b487a47f0cbb99fdee2ec9cc8b56b814c8860e)
    
    Signed-off-by: Ross Burton <ross burton intel com>
    Signed-off-by: Richard Purdie <richard purdie linuxfoundation org>

 scripts/lib/bsp/help.py |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/scripts/lib/bsp/help.py b/scripts/lib/bsp/help.py
index 85a09dd..311c5e4 100644
--- a/scripts/lib/bsp/help.py
+++ b/scripts/lib/bsp/help.py
@@ -42,7 +42,7 @@ def display_help(subcommand, subcommands):
 
     help = subcommands.get(subcommand, subcommand_error)[2]
     pager = subprocess.Popen('less', stdin=subprocess.PIPE)
-    pager.communicate(help)
+    pager.communicate(bytes(help, 'UTF-8'))
 
     return True
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]