python/machine: disable warning for Popen in _launch()
authorJohn Snow <jsnow@redhat.com>
Thu, 27 May 2021 21:16:50 +0000 (17:16 -0400)
committerJohn Snow <jsnow@redhat.com>
Tue, 1 Jun 2021 20:21:21 +0000 (16:21 -0400)
We handle this resource rather meticulously in
shutdown/kill/wait/__exit__ et al, through the laborious mechanisms in
_do_shutdown().

Quiet this pylint warning here.

Signed-off-by: John Snow <jsnow@redhat.com>
Reviewed-by: Cleber Rosa <crosa@redhat.com>
Message-id: 20210527211715.394144-7-jsnow@redhat.com
Message-id: 20210517184808.3562549-7-jsnow@redhat.com
Signed-off-by: John Snow <jsnow@redhat.com>
python/qemu/machine.py

index c66bc6a9c6979f46bd9f2d727b076dc108b300b2..5d72c4ca36905c5ffd87850b08578695ded7a90f 100644 (file)
@@ -405,6 +405,9 @@ class QEMUMachine:
                   self._args)
         )
         LOG.debug('VM launch command: %r', ' '.join(self._qemu_full_args))
+
+        # Cleaning up of this subprocess is guaranteed by _do_shutdown.
+        # pylint: disable=consider-using-with
         self._popen = subprocess.Popen(self._qemu_full_args,
                                        stdin=subprocess.DEVNULL,
                                        stdout=self._qemu_log_file,