qemu-block
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2 5/5] python/aqmp: add socket bind step to legacy.py


From: Daniel P . Berrangé
Subject: Re: [PATCH v2 5/5] python/aqmp: add socket bind step to legacy.py
Date: Thu, 20 Jan 2022 09:13:19 +0000
User-agent: Mutt/2.1.3 (2021-09-10)

On Wed, Jan 19, 2022 at 02:39:16PM -0500, John Snow wrote:
> The old QMP library would actually bind to the server address during
> __init__(). The new library delays this to the accept() call, because
> binding occurs inside of the call to start_[unix_]server(), which is an
> async method -- so it cannot happen during __init__ anymore.
> 
> Python 3.7+ adds the ability to create the server (and thus the bind()
> call) and begin the active listening in separate steps, but we don't
> have that functionality in 3.6, our current minimum.
> 
> Therefore ... Add a temporary workaround that allows the synchronous
> version of the client to bind the socket in advance, guaranteeing that
> there will be a UNIX socket in the filesystem ready for the QEMU client
> to connect to without a race condition.
> 
> (Yes, it's ugly; fixing it more nicely will unfortunately have to wait
> until I can stipulate Python 3.7+ as our minimum version. Python 3.6 is
> EOL as of the beginning of this year, but I haven't checked if all of
> our supported build platforms have a properly modern Python available
> yet.)

RHEL-8 system python will remain 3.6 for the life of RHEL-8.

While you can bring in newer python versions in parallel,
IMHO it is highly desirable to remain compatible with the
system python as that's the one you can guarantee users
actually have available by default.


Regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|




reply via email to

[Prev in Thread] Current Thread [Next in Thread]