]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
devshell.bbclass: Exceptions displayed within devpyshell
authorDorinda Bassey <dorindabassey@gmail.com>
Thu, 18 Mar 2021 15:49:40 +0000 (16:49 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Sat, 20 Mar 2021 18:50:05 +0000 (18:50 +0000)
If you type something into devpyshell, an exception should be triggered,
but that exception isn't printed out because it is not being flushed out
of the buffer. This patch fixes that issue.

[YOCTO #12156]

Signed-off-by: Dorinda Bassey <dorindabassey@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/devshell.bbclass

index fdf7dc100fa8e34c01032f21f478b69cf0ef3bf2..76dd0b42eea2aef64010b37cb976fdedc1af308c 100644 (file)
@@ -128,6 +128,7 @@ def devpyshell(d):
                     more = i.runsource(source, "<pyshell>")
                     if not more:
                         buf = []
+                    sys.stderr.flush()
                     prompt(more)
             except KeyboardInterrupt:
                 i.write("\nKeyboardInterrupt\n")