<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/poky.git/meta/lib/oeqa/runtime/context.py, branch genericarm64</title>
<subtitle>Mirror of git.yoctoproject.org/poky</subtitle>
<id>https://git.enea.com/cgit/linux/poky.git/atom?h=genericarm64</id>
<link rel='self' href='https://git.enea.com/cgit/linux/poky.git/atom?h=genericarm64'/>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/'/>
<updated>2023-06-29T09:57:27+00:00</updated>
<entry>
<title>testimage/oeqa: Drop testimage_dump_host functionality</title>
<updated>2023-06-29T09:57:27+00:00</updated>
<author>
<name>Thomas Roos</name>
<email>throos@amazon.de</email>
</author>
<published>2023-05-17T14:36:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=f82c3bd37d62a3efc49fd33efa38a7f523e6c676'/>
<id>urn:sha1:f82c3bd37d62a3efc49fd33efa38a7f523e6c676</id>
<content type='text'>
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: dea37ba49a236029da73d5cfbfc069bffc38b508)

Signed-off-by: Thomas Roos &lt;throos@amazon.de&gt;
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>oeqa context.py: fix --target-ip comment to include ssh port number</title>
<updated>2023-02-08T10:29:01+00:00</updated>
<author>
<name>Mikko Rapeli</name>
<email>mikko.rapeli@linaro.org</email>
</author>
<published>2023-02-07T09:40:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=75b70b625706253bda360371441ae09922d59326'/>
<id>urn:sha1:75b70b625706253bda360371441ae09922d59326</id>
<content type='text'>
Providing ssh port number is supported too with
"--target-ip 192.168.0.10:22".

(From OE-Core rev: 637919b9df0abc06da5b2f9b389cf25376bd6b7c)

Signed-off-by: Mikko Rapeli &lt;mikko.rapeli@linaro.org&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>oeqa/runtime/context: remove duplicate sys.path entries when looking for modules</title>
<updated>2022-03-26T09:33:32+00:00</updated>
<author>
<name>Ross Burton</name>
<email>ross@burtonini.com</email>
</author>
<published>2022-03-25T12:29:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=596fcd883f7340a06d083597abf5d1873c695b7c'/>
<id>urn:sha1:596fcd883f7340a06d083597abf5d1873c695b7c</id>
<content type='text'>
sys.path can contain duplicate entries for each layer, which means that
the search in add_controller_list() will find the same name twice and
abort.

As duplicate directories should be harmless, remove any duplicates before
iterating through the entries.

(From OE-Core rev: e478381ac1cccc5f882198fd11c8757db7e3741a)

Signed-off-by: Ross Burton &lt;ross.burton@arm.com&gt;
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>oeqa/runtime: search sys.path explicitly for modules</title>
<updated>2021-10-23T16:42:28+00:00</updated>
<author>
<name>Ross Burton</name>
<email>ross@burtonini.com</email>
</author>
<published>2021-10-20T17:30:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=9fa83474ada96064b577b57c57c7dea0306467b9'/>
<id>urn:sha1:9fa83474ada96064b577b57c57c7dea0306467b9</id>
<content type='text'>
The controller module loading code needs to be told what directories
to search for modules via the target_modules_path keyword argument, which
is set to BBPATH.

However, as the actual module loading is done via importlib this relies
on the paths being on sys.path, which it is as base.bbclass puts each
layer's lib/ in sys.path.

Simplify the code by removing this indirection, and simply search
sys.path directly.

(From OE-Core rev: 570a19581f582f77e04d6892adb647cd649a6943)

Signed-off-by: Ross Burton &lt;ross.burton@arm.com&gt;
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>oeqa/runtime: load modules using importlib</title>
<updated>2021-10-23T16:42:28+00:00</updated>
<author>
<name>Ross Burton</name>
<email>ross@burtonini.com</email>
</author>
<published>2021-10-20T17:30:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=c7d6f9965ebed60f7c5a28cadc8b26ed8f8828f9'/>
<id>urn:sha1:c7d6f9965ebed60f7c5a28cadc8b26ed8f8828f9</id>
<content type='text'>
Instead of using __import__() which is low-level and discouraged, use
importlib.

(From OE-Core rev: 9f501d22eab5dbd565f3f5783f4f484a6d1f70a2)

Signed-off-by: Ross Burton &lt;ross.burton@arm.com&gt;
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>oeqa: default runtime json results for testexport</title>
<updated>2020-03-29T11:05:31+00:00</updated>
<author>
<name>Stefan Kral</name>
<email>sk@typedivision.de</email>
</author>
<published>2020-03-25T23:11:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=80c1002c2e4dd7cdaa6ef40a5d37addcc27ca3da'/>
<id>urn:sha1:80c1002c2e4dd7cdaa6ef40a5d37addcc27ca3da</id>
<content type='text'>
Set the json result output dir in the oeqe runtime context to create
testresults.json file by default for exported runtime test runs.

Use current datetime for the json result property name (not DATETIME
from build) to allow multiple result entries.

(From OE-Core rev: e6c73ed8d3c5d45f387cab619ca73c21e850582f)

Signed-off-by: Stefan Kral &lt;sk@typedivision.de&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>oeqa/runtime/context.py: fix typo</title>
<updated>2020-03-12T12:46:09+00:00</updated>
<author>
<name>Stefan Kral</name>
<email>sk@typedivision.de</email>
</author>
<published>2020-03-11T16:36:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=5c8a1312fa74aebfb152a5d265a2b0c7af77498b'/>
<id>urn:sha1:5c8a1312fa74aebfb152a5d265a2b0c7af77498b</id>
<content type='text'>
(From OE-Core rev: bf959e6fd175d0841a1c042bf925c54200bea3d4)

Signed-off-by: Stefan Kral &lt;sk@typedivision.de&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>oeqa/runtime/context.py: support listening port in TEST_SERVER_IP</title>
<updated>2019-12-16T23:25:49+00:00</updated>
<author>
<name>André Draszik</name>
<email>git@andred.net</email>
</author>
<published>2019-12-12T21:52:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=ae6c729a53111b6477903f429efd5a58e3f2b575'/>
<id>urn:sha1:ae6c729a53111b6477903f429efd5a58e3f2b575</id>
<content type='text'>
Similar to the existing possibility to specify a port in
TEST_TARGET_IP, allow TEST_SERVER_IP to also contain a
port.

The intention is for this port to be passed into e.g.
the http server from the apt / dnf / opkg tests, or
any other (custom) tests that might need the target to
connect to a service spawned by bitbake / oeqa, where
bitbake is actually running inside a docker container.

(From OE-Core rev: 9f401cd8b010ca613a151d0323b251f2243f399f)

Signed-off-by: André Draszik &lt;git@andred.net&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>oeqa/runtime/context.py: ignore more files when loading controllers</title>
<updated>2019-10-23T15:30:36+00:00</updated>
<author>
<name>André Draszik</name>
<email>git@andred.net</email>
</author>
<published>2019-10-21T10:30:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=f0f2a492f372e7f02393070f6dfca14eb1e170c8'/>
<id>urn:sha1:f0f2a492f372e7f02393070f6dfca14eb1e170c8</id>
<content type='text'>
When loading controllers as (external) modules, the code currently
tries to load all files ending with .py. This is a problem when
during development using an editor that creates a lock-file
in the same directory as the .py file, as the lock file is
typically called '.#xxxx.py'.
Python will try to load the lock file and fail miserably with
an exception:

    The stack trace of python calls that resulted in this exception/failure was:
    File: 'exec_python_func() autogenerated', lineno: 2, function: &lt;module&gt;
         0001:
     *** 0002:do_testimage(d)
         0003:
    File: 'poky/meta/classes/testimage.bbclass', lineno: 114, function: do_testimage
         0110:    netstat -an
         0111:}
         0112:
         0113:python do_testimage() {
     *** 0114:    testimage_main(d)
         0115:}
         0116:
         0117:addtask testimage
         0118:do_testimage[nostamp] = "1"
    File: 'poky/meta/classes/testimage.bbclass', lineno: 294, function: testimage_main
         0290:
         0291:    # the robot dance
         0292:    target = OERuntimeTestContextExecutor.getTarget(
         0293:        d.getVar("TEST_TARGET"), logger, d.getVar("TEST_TARGET_IP"),
     *** 0294:        d.getVar("TEST_SERVER_IP"), **target_kwargs)
         0295:
         0296:    # test context
         0297:    tc = OERuntimeTestContext(td, logger, target, host_dumper,
         0298:                              image_packages, extract_dir)
    File: 'poky/meta/lib/oeqa/runtime/context.py', lineno: 116, function: getTarget
         0112:            # XXX: Don't base your targets on this code it will be refactored
         0113:            # in the near future.
         0114:            # Custom target module loading
         0115:            target_modules_path = kwargs.get('target_modules_path', '')
     *** 0116:            controller = OERuntimeTestContextExecutor.getControllerModule(target_type, target_modules_path)
         0117:            target = controller(logger, target_ip, server_ip, **kwargs)
         0118:
         0119:        return target
         0120:
    File: 'poky/meta/lib/oeqa/runtime/context.py', lineno: 128, function: getControllerModule
         0124:    # ImportError raised if a provided module can not be imported.
         0125:    @staticmethod
         0126:    def getControllerModule(target, target_modules_path):
         0127:        controllerslist = OERuntimeTestContextExecutor._getControllerModulenames(target_modules_path)
     *** 0128:        controller = OERuntimeTestContextExecutor._loadControllerFromName(target, controllerslist)
         0129:        return controller
         0130:
         0131:    # Return a list of all python modules in lib/oeqa/controllers for each
         0132:    # layer in bbpath
    File: 'poky/meta/lib/oeqa/runtime/context.py', lineno: 163, function: _loadControllerFromName
         0159:    # Raise ImportError if a provided module can not be imported
         0160:    @staticmethod
         0161:    def _loadControllerFromName(target, modulenames):
         0162:        for name in modulenames:
     *** 0163:            obj = OERuntimeTestContextExecutor._loadControllerFromModule(target, name)
         0164:            if obj:
         0165:                return obj
         0166:        raise AttributeError("Unable to load {0} from available modules: {1}".format(target, str(modulenames)))
         0167:
    File: 'poky/meta/lib/oeqa/runtime/context.py', lineno: 173, function: _loadControllerFromModule
         0169:    @staticmethod
         0170:    def _loadControllerFromModule(target, modulename):
         0171:        obj = None
         0172:        # import module, allowing it to raise import exception
     *** 0173:        module = __import__(modulename, globals(), locals(), [target])
         0174:        # look for target class in the module, catching any exceptions as it
         0175:        # is valid that a module may not have the target class.
         0176:        try:
         0177:            obj = getattr(module, target)
    Exception: ImportError: No module named 'oeqa.controllers.'

Simply ignore those when collecting the list of files to try
to load.

(From OE-Core rev: 682f223cf2e2dabe8cf60634b6779bb2d5e359bd)

Signed-off-by: André Draszik &lt;git@andred.net&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>meta/lib+scripts: Convert to SPDX license headers</title>
<updated>2019-05-09T15:31:55+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2019-05-08T17:22:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=ffae400179fd0b64f8882cf79d78e1c0f2d74bee'/>
<id>urn:sha1:ffae400179fd0b64f8882cf79d78e1c0f2d74bee</id>
<content type='text'>
This adds SPDX license headers in place of the wide assortment of things
currently in our script headers. We default to GPL-2.0-only except for the
oeqa code where it was clearly submitted and marked as MIT on the most part
or some scripts which had the "or later" GPL versioning.

The patch also drops other obsolete bits of file headers where they were
encoountered such as editor modelines, obsolete maintainer information or
the phrase "All rights reserved" which is now obsolete and not required in
copyright headers (in this case its actually confusing for licensing as all
rights were not reserved).

More work is needed for OE-Core but this takes care of the bulk of the scripts
and meta/lib directories.

The top level LICENSE files are tweaked to match the new structure and the
SPDX naming.

(From OE-Core rev: f8c9c511b5f1b7dbd45b77f345cb6c048ae6763e)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
</feed>
