Re: [Qemu-devel] [PATCH for-3.1] qemu-iotests: Adapt to moved location of StringIO module in py3

2018-07-18 Thread Eduardo Habkost
On Wed, Jul 18, 2018 at 12:22:19PM -0300, Philippe Mathieu-Daudé wrote: > On 07/18/2018 12:05 PM, Eduardo Habkost wrote: > > On Wed, Jul 18, 2018 at 12:02:39PM -0300, Philippe Mathieu-Daudé wrote: > >> Hi Eduardo, > >> > >> On 07/18/2018 11:53 AM, Eduardo Habkost wrote: > >>> On Tue, Jul 17, 2018 a

Re: [Qemu-devel] [PATCH for-3.1] qemu-iotests: Adapt to moved location of StringIO module in py3

2018-07-18 Thread Philippe Mathieu-Daudé
On 07/18/2018 12:05 PM, Eduardo Habkost wrote: > On Wed, Jul 18, 2018 at 12:02:39PM -0300, Philippe Mathieu-Daudé wrote: >> Hi Eduardo, >> >> On 07/18/2018 11:53 AM, Eduardo Habkost wrote: >>> On Tue, Jul 17, 2018 at 08:40:15PM -0300, Philippe Mathieu-Daudé wrote: >>> [...] -import StringI

Re: [Qemu-devel] [PATCH for-3.1] qemu-iotests: Adapt to moved location of StringIO module in py3

2018-07-18 Thread Eduardo Habkost
On Wed, Jul 18, 2018 at 12:02:39PM -0300, Philippe Mathieu-Daudé wrote: > Hi Eduardo, > > On 07/18/2018 11:53 AM, Eduardo Habkost wrote: > > On Tue, Jul 17, 2018 at 08:40:15PM -0300, Philippe Mathieu-Daudé wrote: > > [...] > >> -import StringIO > >> +try: > >> +from StringIO import

Re: [Qemu-devel] [PATCH for-3.1] qemu-iotests: Adapt to moved location of StringIO module in py3

2018-07-18 Thread Philippe Mathieu-Daudé
Hi Eduardo, On 07/18/2018 11:53 AM, Eduardo Habkost wrote: > On Tue, Jul 17, 2018 at 08:40:15PM -0300, Philippe Mathieu-Daudé wrote: > [...] >> -import StringIO >> +try: >> +from StringIO import StringIO >> +except ImportError: >> +from io import StringIO > > Why do we

Re: [Qemu-devel] [PATCH for-3.1] qemu-iotests: Adapt to moved location of StringIO module in py3

2018-07-18 Thread Eduardo Habkost
On Tue, Jul 17, 2018 at 08:40:15PM -0300, Philippe Mathieu-Daudé wrote: [...] > -import StringIO > +try: > +from StringIO import StringIO > +except ImportError: > +from io import StringIO Why do we need this? Python 2.7 has io.StringIO. -- Eduardo

Re: [Qemu-devel] [PATCH for-3.1] qemu-iotests: Adapt to moved location of StringIO module in py3

2018-07-18 Thread Daniel P . Berrangé
On Tue, Jul 17, 2018 at 08:40:15PM -0300, Philippe Mathieu-Daudé wrote: > Since 356dc290f the Fedora image default to Python3. > > This fixes: > > $ make docker-test-block@fedora > [...] > 045 [failed, exit status 1] - output mismatch (see 045.out.bad) > --- /tmp/qemu-test/src/tes

[Qemu-devel] [PATCH for-3.1] qemu-iotests: Adapt to moved location of StringIO module in py3

2018-07-17 Thread Philippe Mathieu-Daudé
Since 356dc290f the Fedora image default to Python3. This fixes: $ make docker-test-block@fedora [...] 045 [failed, exit status 1] - output mismatch (see 045.out.bad) --- /tmp/qemu-test/src/tests/qemu-iotests/045.out 2018-07-17 16:56:18.0 + +++ /tmp/qemu-test/