All of lore.kernel.org
 help / color / mirror / Atom feed
From: Fabiano Rosas <farosas@suse.de>
To: "Daniel P. Berrangé" <berrange@redhat.com>
Cc: Thomas Huth <thuth@redhat.com>, Ani Sinha <anisinha@redhat.com>,
	qemu-devel <qemu-devel@nongnu.org>
Subject: Re: artifact download for qtest
Date: Mon, 08 Jun 2026 17:02:01 -0300	[thread overview]
Message-ID: <87se6w6bt2.fsf@suse.de> (raw)
In-Reply-To: <aicYc6GGapIJTKdi@redhat.com>

Daniel P. Berrangé <berrange@redhat.com> writes:

> On Mon, Jun 08, 2026 at 04:13:02PM -0300, Fabiano Rosas wrote:
>> Thomas Huth <thuth@redhat.com> writes:
>> 
>> > On 30/05/2026 16.56, Ani Sinha wrote:
>> >> Hi,
>> >> 
>> >> I am trying to write a qtest for which I need an IGVM file. I have the
>> >> file, about 54 MiB in size.
>> >
>> > 54 MiB is quite big, I agree that we likely don't want to check that into 
>> > the main repository, especially if it is for a test only...
>> > (BTW, what's its compressed size?)
>> >
>> >> Instead of committing this IGVM binary
>> >> file with the test, I wanted to check if I can put it somewhere, say
>> >> in a gitlab repo and then make the test download it. This would be
>> >> similar to asset downloads for functional tests. No this test cannot
>> >> be a python functional test.  I am wondering if anyone has faced this
>> >> situation before and what the best way to solve this problem is.
>> >
>> > I'm not maintaining the qtests anymore, but I assume that there is no 
>> > interest in duplicating all the asset downloading logic there.
>> >
>> 
>> It would be nice if we could extract the existing code into a little
>> asset library that could be invoked from the other test frameworks.
>
> IMHO that isn't really practical, all the asset handling is in python.
> It'd be mad to re-implement that in C and then call it from python,
> and the C isn't really going to call the current python either....
>

What about a standalone downloader? I'm still thinking about reusing
more of the common operations between test frameworks. Is it feasible to
have a cmdline app that can be invoked by qtest and place artifacts in a
common place?

>> > What's the exact reason why you cannot do it as a functional test instead? 
>> > You could maybe also start the qemu binary there with "-accel qtest -qtest 
>> > ..." to fake a qtest environment - a little bit cumbersome, but certainly 
>> > doable, I think.
>
> ..if we didn't have the historical baggage already, then I'd that
> qtests should conceptually just be a subset of the functional
> tests. Writing them in python would be nicer than doing them in C.
>

But could we make _working_ with them in python be equivalent to C? I
agree it's nice to write tests in a higher level language, but python
specifically is a big pain when it comes to actually finding out why a
test is failing. And debugging is even worse.

The tradeoff is that unittest is clearly superior to glib as a test
runner. Having a more modern way of generating command-lines would be
nice too.

> The qtest service is integrated in QEMU, what's missing is
>
>  * the client side to talk the qtest protocol

python/qemu/machine/qtest.py?

>  * the various bus specific helper APIs
>
> I don't know how hard it would be to bootstrap the client side in
> python, but the general qtest protocol is 2000 lines of C, so
> probably more like 500 lines of python to replace it, plus whatever
> helpers you might want on top. Probably not terribly much work to
> get something useful kickstarted.
>
> NB, I am *not* sugggesting re-writing the actual existing tests,
> just make it possible to write new qtests in python.
>
> With regards,
> Daniel


  reply	other threads:[~2026-06-08 20:03 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-30 14:56 artifact download for qtest Ani Sinha
2026-06-08 17:13 ` Thomas Huth
2026-06-08 19:13   ` Fabiano Rosas
2026-06-08 19:30     ` Daniel P. Berrangé
2026-06-08 20:02       ` Fabiano Rosas [this message]
2026-06-09  2:24   ` Ani Sinha
2026-06-09  3:46     ` Ani Sinha

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87se6w6bt2.fsf@suse.de \
    --to=farosas@suse.de \
    --cc=anisinha@redhat.com \
    --cc=berrange@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=thuth@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.