qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Eduardo Habkost <ehabkost@redhat.com>
To: "Daniel P. Berrange" <berrange@redhat.com>
Cc: qemu-devel@nongnu.org, "Fam Zheng" <famz@redhat.com>,
	"Philippe Mathieu-Daudé" <f4bug@amsat.org>,
	"Markus Armbruster" <armbru@redhat.com>,
	"Paolo Bonzini" <pbonzini@redhat.com>,
	"Alex Bennée" <alex.bennee@linaro.org>
Subject: Re: [Qemu-devel] [PATCH v5 00/14] Support building with py2 or py3
Date: Fri, 19 Jan 2018 15:09:54 -0200	[thread overview]
Message-ID: <20180119170954.GA15832@localhost.localdomain> (raw)
In-Reply-To: <20180116134217.8725-1-berrange@redhat.com>


On Tue, Jan 16, 2018 at 01:42:03PM +0000, Daniel P. Berrange wrote:
> This is an update for my previously posted series:
> 
>  v2: https://lists.gnu.org/archive/html/qemu-devel/2017-08/msg06528.html
>  v3: https://lists.gnu.org/archive/html/qemu-devel/2018-01/msg02978.html
>  v4: https://lists.gnu.org/archive/html/qemu-devel/2018-01/msg03150.html
> 
> This series enables some level of CI testing for py3 so that our CI jobs will
> get coverage of both py2 and py3 builds to avoid bitrot.
> 

I'm queueing this on python-next.  Thanks!



> I did a test travis build with py 3.0 and py 3.6 and got success:
> 
>   https://travis-ci.org/berrange/qemu/builds/328223261
> 
> The goal was to achieve the following
> 
>   ./configure --python=/usr/bin/python3
>   make
>   make check
> 
> This still requires passing python path to configure explicitly. A
> further improvement would be for configure to automatically detect
> a pythjon 3 binary and use it preferentially to python 2.
> 
> I have not attempted to fix/validate the block I/O tests. I would expect
> them to be broken, but easily fixable with the similar kind of scope
> changes as seen here. I felt it better to tackle that separately to
> avoid this initial series getting too large.
> 
> Although the Python 2 EOL date is 2020, we already have distros which
> are not shipping Python 2 by default (Fedora >= 26 has dropped Py2 from
> the default install). Any new releases of long life and/or enterprise
> distros may well not ship Python 2 given that it would go EOL long
> before the EOL of the distro itself. IOW QEMU does have a fairly pressing
> need to be able to support Python 3 for building.
> 
> A request for py3 is tracked here:
> 
>    https://bugs.launchpad.net/qemu/+bug/1708462
> 
> If, rather than supporting py2+py3 in parallel, we wish to entirely drop
> py2 support, this series would not change significantly
> 
>  - The "from __future__ import print_function" line can be removed
>    from patch 1.
>  - The code in patches 2, 3, 4 to deal with changed module names
>    for a few functions can be simpified to only try the py3 location
>  - The travis + docker jobs would be fully updated to install py3,
>    or delete jobs which can't support py3
> 
> Given how little code is removed should we drop py2 support, I don't
> believe it is in our immediate interests to do this. It would create
> extra pain for consumers of QEMU, with little benefit to QEMU code
> maintainance. The key thing is ensuring our travis+docker jobs provide
> satisfactory automated test coverage for the variety of python versions
> in the distros we care about targetting.
> 
> NB, Patch 11 here is not related to python 3 work - it was just a
> temporary pre-requisite of pulling in the keycodemapdb update.
> 
> Changes since v4:
> 
>  - Fix broken rebase which accidentally squashed first two
>    patches together
>  - Unset LC_ALL, and set LANG + LC_CTYPE, instead of only LANG (Eric)
> 
> Changes since v3:
> 
>  - Remove space before '(' in print() function calls (Phillippe)
>  - Force use of en_US.UTF-8 for QAPI code generation (Patchew)
> 
> Changes since v2:
> 
>  - Pull in fix for keycodemapdb
>  - Enable testing with Travis
>  - Enable testing with Fedora Docker images
>  - Fix for sort ordering to fix 'make check-qapi-schema'
>  - Fix for signrom data
> 
> Daniel P. Berrange (13):
>   qapi: convert to use python print function instead of statement
>   qapi: use items()/values() intead of iteritems()/itervalues()
>   qapi: Use OrderedDict from standard library if available
>   qapi: adapt to moved location of StringIO module in py3
>   qapi: Adapt to moved location of 'maketrans' function in py3
>   qapi: remove '-q' arg to diff when comparing QAPI output
>   qapi: ensure stable sort ordering when checking QAPI entities
>   qapi: force a UTF-8 locale for running Python
>   scripts: ensure signrom treats data as bytes
>   configure: allow use of python 3
>   ui: update keycodemapdb to get py3 fixes
>   travis: improve python version test coverage
>   docker: change Fedora images to run with python3
> 
> Miika S (1):
>   input: add missing JIS keys to virtio input
> 
>  .travis.yml                            | 14 +++++++----
>  Makefile                               | 22 +++++++++--------
>  configure                              |  5 ++--
>  hw/input/virtio-input-hid.c            |  7 ++++++
>  qapi/ui.json                           |  5 +++-
>  scripts/qapi.py                        | 43 ++++++++++++++++++++--------------
>  scripts/qapi2texi.py                   | 11 +++++----
>  scripts/signrom.py                     |  4 ++--
>  tests/Makefile.include                 |  6 ++---
>  tests/docker/dockerfiles/fedora.docker |  3 ++-
>  tests/qapi-schema/test-qapi.py         | 43 +++++++++++++++++-----------------
>  ui/keycodemapdb                        |  2 +-
>  12 files changed, 96 insertions(+), 69 deletions(-)
> 
> -- 
> 2.14.3
> 
> 

-- 
Eduardo

      parent reply	other threads:[~2018-01-19 17:10 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-16 13:42 [Qemu-devel] [PATCH v5 00/14] Support building with py2 or py3 Daniel P. Berrange
2018-01-16 13:42 ` [Qemu-devel] [PATCH v5 01/14] qapi: convert to use python print function instead of statement Daniel P. Berrange
2018-01-16 13:42 ` [Qemu-devel] [PATCH v5 02/14] qapi: use items()/values() intead of iteritems()/itervalues() Daniel P. Berrange
2018-01-16 13:42 ` [Qemu-devel] [PATCH v5 03/14] qapi: Use OrderedDict from standard library if available Daniel P. Berrange
2018-01-16 13:42 ` [Qemu-devel] [PATCH v5 04/14] qapi: adapt to moved location of StringIO module in py3 Daniel P. Berrange
2018-01-16 13:42 ` [Qemu-devel] [PATCH v5 05/14] qapi: Adapt to moved location of 'maketrans' function " Daniel P. Berrange
2018-01-16 13:42 ` [Qemu-devel] [PATCH v5 06/14] qapi: remove '-q' arg to diff when comparing QAPI output Daniel P. Berrange
2018-02-09 23:39   ` Eric Blake
2018-02-10  6:27     ` Markus Armbruster
2018-02-12 16:45     ` Daniel P. Berrangé
2018-01-16 13:42 ` [Qemu-devel] [PATCH v5 07/14] qapi: ensure stable sort ordering when checking QAPI entities Daniel P. Berrange
2018-01-16 13:42 ` [Qemu-devel] [PATCH v5 08/14] qapi: force a UTF-8 locale for running Python Daniel P. Berrange
2018-01-16 14:45   ` Eric Blake
2018-01-16 13:42 ` [Qemu-devel] [PATCH v5 09/14] scripts: ensure signrom treats data as bytes Daniel P. Berrange
2018-01-16 13:42 ` [Qemu-devel] [PATCH v5 10/14] configure: allow use of python 3 Daniel P. Berrange
2018-01-16 14:51   ` Eric Blake
2018-01-16 13:42 ` [Qemu-devel] [PATCH v5 11/14] input: add missing JIS keys to virtio input Daniel P. Berrange
2018-01-16 14:54   ` Eric Blake
2018-02-01 20:46   ` Eduardo Habkost
2018-02-02 13:13     ` Daniel P. Berrangé
2018-02-02 14:52       ` Eduardo Habkost
2018-01-16 13:42 ` [Qemu-devel] [PATCH v5 12/14] ui: update keycodemapdb to get py3 fixes Daniel P. Berrange
2018-01-16 14:56   ` Eric Blake
2018-01-16 13:42 ` [Qemu-devel] [PATCH v5 13/14] travis: improve python version test coverage Daniel P. Berrange
2018-05-31 16:09   ` Philippe Mathieu-Daudé
2018-06-01 11:47     ` Daniel P. Berrangé
2018-05-31 20:17   ` Alex Bennée
2018-06-01 11:48     ` Daniel P. Berrangé
2018-01-16 13:42 ` [Qemu-devel] [PATCH v5 14/14] docker: change Fedora images to run with python3 Daniel P. Berrange
2018-01-19 17:09 ` Eduardo Habkost [this message]

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=20180119170954.GA15832@localhost.localdomain \
    --to=ehabkost@redhat.com \
    --cc=alex.bennee@linaro.org \
    --cc=armbru@redhat.com \
    --cc=berrange@redhat.com \
    --cc=f4bug@amsat.org \
    --cc=famz@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).