[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH RFC 21/32] python//machine.py: remove logging configuration
From: |
Philippe Mathieu-Daudé |
Subject: |
Re: [PATCH RFC 21/32] python//machine.py: remove logging configuration |
Date: |
Sun, 31 May 2020 12:03:52 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.5.0 |
On 5/14/20 7:53 AM, John Snow wrote:
> Python 3.5 and above do not print a warning when logging is not
> configured. As a library, it's best practice to leave logging
> configuration to the client executable.
>
> Signed-off-by: John Snow <jsnow@redhat.com>
> ---
> python/qemu/lib/machine.py | 3 ---
> 1 file changed, 3 deletions(-)
>
> diff --git a/python/qemu/lib/machine.py b/python/qemu/lib/machine.py
> index c31bf7cabb..e92afe8649 100644
> --- a/python/qemu/lib/machine.py
> +++ b/python/qemu/lib/machine.py
> @@ -110,9 +110,6 @@ def __init__(self, binary, args=None, wrapper=None,
> name=None,
> self._console_socket = None
> self._remove_files = []
>
> - # just in case logging wasn't configured by the main script:
> - logging.basicConfig()
> -
> def __enter__(self):
> return self
>
>
Thanks, applied to my python-next tree:
https://gitlab.com/philmd/qemu/commits/python-next
- [PATCH RFC 15/32] python//qmp.py: Define common types, (continued)
- [PATCH RFC 15/32] python//qmp.py: Define common types, John Snow, 2020/05/14
- [PATCH RFC 17/32] python//qmp.py: Do not return None from cmd_obj, John Snow, 2020/05/14
- [PATCH RFC 18/32] python//qmp.py: add casts to JSON deserialization, John Snow, 2020/05/14
- [PATCH RFC 20/32] python//qmp.py: assert sockfile is not None, John Snow, 2020/05/14
- [PATCH RFC 21/32] python//machine.py: remove logging configuration, John Snow, 2020/05/14
- [PATCH RFC 22/32] python//machine.py: Fix monitor address typing, John Snow, 2020/05/14
- [PATCH RFC 23/32] python//machine.py: reorder __init__, John Snow, 2020/05/14
- [PATCH RFC 24/32] python//machine.py: Don't modify state in _base_args(), John Snow, 2020/05/14
- [PATCH RFC 25/32] python//machine.py: Handle None events in event_wait, John Snow, 2020/05/14
- [PATCH RFC 26/32] python//machine.py: use qmp.command, John Snow, 2020/05/14
- [PATCH RFC 28/32] python//machine.py: fix _popen access, John Snow, 2020/05/14
- [PATCH RFC 27/32] python//machine.py: Add _qmp access shim, John Snow, 2020/05/14
- [PATCH RFC 29/32] python//qtest.py: Check before accessing _qtest, John Snow, 2020/05/14