Missing XML-RPC to get list of test names

Bug #1052545 reported by Milo Casagrande
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
LAVA Dashboard (deprecated)
Fix Released
Undecided
Milo Casagrande

Bug Description

Hello,

as part of a Blueprint for the integration team, we would like to interact with LAVA and retrieve information about possible tests that a user can run.

After discussing with Andy, Michael and zyga, they pointed out that the only information that we can extract from LAVA at this point is just the list of tests ran by LAVA itself. Other works need to be taken in order to have the list of possible tests, maybe organized in some sort of logical group.

This bug is for keeping track of the progress toward achieving a simple XML-RPC call in lava-dashboard to extract the names of all the tests ran.

Related branches

Revision history for this message
Milo Casagrande (milo) wrote :

I added a MP marked as still in progress. I'm trying to get tests working locally for lava-dashboard, but am not able to.

Revision history for this message
Andy Doan (doanac) wrote :

I think you are on the right track here. However, rather than listing all tests, we could probably make this function take some params. For example, if we know:

 device-type (panda, vexpress, origen, etc)
 build-type (android / ubuntu)

You could actually filter down the list of tests more appropriately. Maybe make those two parameters above optional or something?

Revision history for this message
Milo Casagrande (milo) wrote : Re: [Bug 1052545] Re: Missing XML-RPC to get list of test names

Hello Andy,

thanks for the input!

On Wed, Sep 19, 2012 at 12:02 AM, Andy Doan <email address hidden> wrote:
> I think you are on the right track here. However, rather than listing
> all tests, we could probably make this function take some params. For
> example, if we know:
>
> device-type (panda, vexpress, origen, etc)
> build-type (android / ubuntu)
>
> You could actually filter down the list of tests more appropriately.

Something like that would be awesome for us, but I guess I need a
little bit of guidance here then.
Looking at the Test model in 'lava_dashboard/dashboard_app/models.py',
the model is pretty simple, there is no information about device or
build.

The only reference about hardware I found is in TestRun model, that
refers to HardwareDevice, but the latter is not really helpful.

> Maybe make those two parameters above optional or something?

I added them, although not used ATM, and pushed into the branch.
Thanks for all the help!

--
Milo Casagrande
Infrastructure Engineer
Linaro.org <www.linaro.org> │ Open source software for ARM SoCs

Revision history for this message
Andy Doan (doanac) wrote :

+Michael who's a DB query wizard.

On 09/19/2012 03:17 AM, Milo Casagrande wrote:
> Hello Andy,
>
> thanks for the input!
>
> On Wed, Sep 19, 2012 at 12:02 AM, Andy Doan <email address hidden> wrote:
>> I think you are on the right track here. However, rather than listing
>> all tests, we could probably make this function take some params. For
>> example, if we know:
>>
>> device-type (panda, vexpress, origen, etc)
>> build-type (android / ubuntu)
>>
>> You could actually filter down the list of tests more appropriately.
>
> Something like that would be awesome for us, but I guess I need a
> little bit of guidance here then.
> Looking at the Test model in 'lava_dashboard/dashboard_app/models.py',
> the model is pretty simple, there is no information about device or
> build.
>
> The only reference about hardware I found is in TestRun model, that
> refers to HardwareDevice, but the latter is not really helpful.
>

Michael - do you think there's a way to query for this semi-efficiently.
ie somehow doing a "SELECT test where device_type=='panda'"

Revision history for this message
Michael Hudson-Doyle (mwhudson) wrote :

Andy Doan <email address hidden> writes:

> +Michael who's a DB query wizard.
>
> On 09/19/2012 03:17 AM, Milo Casagrande wrote:
>> Hello Andy,
>>
>> thanks for the input!
>>
>> On Wed, Sep 19, 2012 at 12:02 AM, Andy Doan <email address hidden> wrote:
>>> I think you are on the right track here. However, rather than listing
>>> all tests, we could probably make this function take some params. For
>>> example, if we know:
>>>
>>> device-type (panda, vexpress, origen, etc)
>>> build-type (android / ubuntu)

FWIW, I don't see a particularly clean or reliable way to tell tests
that have run on android from tests that have run on ubuntu currently...

>>> You could actually filter down the list of tests more appropriately.
>>
>> Something like that would be awesome for us, but I guess I need a
>> little bit of guidance here then.
>> Looking at the Test model in 'lava_dashboard/dashboard_app/models.py',
>> the model is pretty simple, there is no information about device or
>> build.
>>
>> The only reference about hardware I found is in TestRun model, that
>> refers to HardwareDevice, but the latter is not really helpful.
>>
>
> Michael - do you think there's a way to query for this semi-efficiently.
> ie somehow doing a "SELECT test where device_type=='panda'"

models.Test.objects.filter(
    test_runs__attributes__name='target.device_type',
    test_runs__attributes__value='panda').distinct()

returns all the tests that have evey been run on panda and seems to be
reasonably efficient (0.1s or so). Is that what you meant?

Cheers,
mwh

Revision history for this message
Andy Doan (doanac) wrote :

On 09/19/2012 08:58 PM, Michael Hudson-Doyle wrote:
> models.Test.objects.filter(
> test_runs__attributes__name='target.device_type',
> test_runs__attributes__value='panda').distinct()
>
> returns all the tests that have evey been run on panda and seems to be
> reasonably efficient (0.1s or so). Is that what you meant?

Yeah, something like that helps.

Too bad we can filter android/ubuntu.

Revision history for this message
Milo Casagrande (milo) wrote :

Hello everyone!

Thanks for the suggestion! I updated the branch with that change.
Am still not able to make tests run locally, so for the moment the MP does not containt tests.

Milo Casagrande (milo)
Changed in lava-dashboard:
status: New → Fix Released
assignee: nobody → Milo Casagrande (milo)
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.