[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v5 25/36] qapi/source.py: delint with pylint
From: |
John Snow |
Subject: |
[PATCH v5 25/36] qapi/source.py: delint with pylint |
Date: |
Mon, 5 Oct 2020 15:51:47 -0400 |
Shush an error and leave a hint for future cleanups when we're allowed
to use Python 3.7+.
Signed-off-by: John Snow <jsnow@redhat.com>
Reviewed-by: Eduardo Habkost <ehabkost@redhat.com>
Reviewed-by: Cleber Rosa <crosa@redhat.com>
Tested-by: Cleber Rosa <crosa@redhat.com>
---
scripts/qapi/pylintrc | 1 -
scripts/qapi/source.py | 3 +++
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/scripts/qapi/pylintrc b/scripts/qapi/pylintrc
index 507f15537ab..d840b150313 100644
--- a/scripts/qapi/pylintrc
+++ b/scripts/qapi/pylintrc
@@ -7,7 +7,6 @@ ignore-patterns=error.py,
gen.py,
parser.py,
schema.py,
- source.py,
types.py,
visit.py,
diff --git a/scripts/qapi/source.py b/scripts/qapi/source.py
index 1cc6a5b82dc..ba991d798fe 100644
--- a/scripts/qapi/source.py
+++ b/scripts/qapi/source.py
@@ -15,6 +15,9 @@
class QAPISchemaPragma:
+ # Replace with @dataclass in Python 3.7+
+ # pylint: disable=too-few-public-methods
+
def __init__(self) -> None:
# Are documentation comments required?
self.doc_required = False
--
2.26.2
- Re: [PATCH v5 19/36] qapi/events.py: add type hint annotations, (continued)
[PATCH v5 20/36] qapi/events.py: Move comments into docstrings, John Snow, 2020/10/05
[PATCH v5 22/36] qapi/commands.py: add type hint annotations, John Snow, 2020/10/05
[PATCH v5 21/36] qapi/commands.py: Don't re-bind to variable of different type, John Snow, 2020/10/05
[PATCH v5 23/36] qapi/commands.py: enable checking with mypy, John Snow, 2020/10/05
[PATCH v5 25/36] qapi/source.py: delint with pylint,
John Snow <=
[PATCH v5 26/36] qapi/gen.py: Fix edge-case of _is_user_module, John Snow, 2020/10/05
[PATCH v5 28/36] qapi/gen.py: Enable checking with mypy, John Snow, 2020/10/05
[PATCH v5 24/36] qapi/source.py: add type hint annotations, John Snow, 2020/10/05