|
From: | Emanuele Giuseppe Esposito |
Subject: | Re: [PATCH] qemu-iotests: fix pylint 2.8 consider-using-with error |
Date: | Mon, 10 May 2021 10:36:17 +0200 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1 |
On 07/05/2021 17:39, Max Reitz wrote:
On 06.05.21 10:48, Emanuele Giuseppe Esposito wrote:pylint 2.8 introduces consider-using-with error, suggesting to use the 'with' block statement when possible. http://pylint.pycqa.org/en/latest/whatsnew/2.8.html Modify all subprocess.Popen calls to use the 'with' statement, except one in __init__ of QemuIoInteractive class, since the return value is assigned to a class field and used in other methods. Signed-off-by: Emanuele Giuseppe Esposito <eesposit@redhat.com> --- tests/qemu-iotests/iotests.py | 63 ++++++++++++++++---------------- tests/qemu-iotests/testrunner.py | 22 +++++------ 2 files changed, 42 insertions(+), 43 deletions(-)Thanks, looks good, functionally. But I just can’t keep myself from nagging about indentation (I wouldn’t have, but flake8 says I may be justified):
No problem , I expected that there would be style problems :) I will fix the indentation and send v2. Thank you, Emanuele
[Prev in Thread] | Current Thread | [Next in Thread] |