pylint: make unsupported-assignment-operation check local

unsupported-assignment-operation is useful at times, make it only
local, not global.

https://pagure.io/freeipa/issue/6874

Reviewed-By: Alexander Bokovoy <abokovoy@redhat.com>
This commit is contained in:
Stanislav Laznicka
2017-08-22 14:06:22 +02:00
parent 33f13b6df9
commit f2701f3a0b
6 changed files with 11 additions and 3 deletions

View File

@@ -999,7 +999,9 @@ class Collector(object):
value = v + (value,)
else:
value = (v, value)
# pylint: disable=unsupported-assignment-operation
self.__options[name] = value
# pylint: enable=unsupported-assignment-operation
object.__setattr__(self, name, value)
def __todict__(self):

View File

@@ -273,7 +273,9 @@ class Env(object):
if type(value) not in (unicode, int, float, bool, type(None), DN):
raise TypeError(key, value)
object.__setattr__(self, key, value)
# pylint: disable=unsupported-assignment-operation
self.__d[key] = value
# pylint: enable=unsupported-assignment-operation
def __getitem__(self, key):
"""