mirror of
https://git.yoctoproject.org/poky
synced 2026-09-13 09:49:32 +02:00
testimage/oeqa: Drop testimage_dump_host functionality
The intent behind these functions was to dump the system state when issues occured but it has never really worked as we'd planned. Regular monitoring as the build runs has largely replaced this as that allows a trend to be seen rather than a spot value which was never really useful. The code is bitrotting and not functioning correctly so drop it. [YOCTO #13872] RP: Reword commit message (From OE-Core rev: 8d1bc34cffdd9f054e51db4e880747c79bf834fe) Signed-off-by: Thomas Roos <throos@amazon.de> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit dea37ba49a236029da73d5cfbfc069bffc38b508) Signed-off-by: Steve Sakoman <steve@sakoman.com>
This commit is contained in:
committed by
Steve Sakoman
parent
4c02657a44
commit
4f1eb64d15
@@ -51,9 +51,7 @@ class BaseDumper(object):
|
||||
self.dump_dir = dump_dir
|
||||
|
||||
def _construct_filename(self, command):
|
||||
if isinstance(self, HostDumper):
|
||||
prefix = "host"
|
||||
elif isinstance(self, TargetDumper):
|
||||
if isinstance(self, TargetDumper):
|
||||
prefix = "target"
|
||||
elif isinstance(self, MonitorDumper):
|
||||
prefix = "qmp"
|
||||
@@ -76,22 +74,6 @@ class BaseDumper(object):
|
||||
with open(fullname, 'w') as dump_file:
|
||||
dump_file.write(output)
|
||||
|
||||
class HostDumper(BaseDumper):
|
||||
""" Class to get dumps from the host running the tests """
|
||||
|
||||
def __init__(self, cmds, parent_dir):
|
||||
super(HostDumper, self).__init__(cmds, parent_dir)
|
||||
|
||||
def dump_host(self, dump_dir=""):
|
||||
if dump_dir:
|
||||
self.dump_dir = dump_dir
|
||||
env = os.environ.copy()
|
||||
env['PATH'] = '/usr/sbin:/sbin:/usr/bin:/bin'
|
||||
env['COLUMNS'] = '9999'
|
||||
for cmd in self.cmds:
|
||||
result = runCmd(cmd, ignore_status=True, env=env)
|
||||
self._write_dump(cmd.split()[0], result.output)
|
||||
|
||||
class TargetDumper(BaseDumper):
|
||||
""" Class to get dumps from target, it only works with QemuRunner.
|
||||
Will give up permanently after 5 errors from running commands over
|
||||
|
||||
Reference in New Issue
Block a user