]> git.ipfire.org Git - thirdparty/dnspython.git/commitdiff
lint
authorBob Halley <halley@dnspython.org>
Tue, 11 Aug 2020 14:42:07 +0000 (07:42 -0700)
committerBob Halley <halley@dnspython.org>
Tue, 11 Aug 2020 14:42:07 +0000 (07:42 -0700)
dns/immutable.py
dns/versioned.py

index 7cc39dd0a34a2164e9c978902c370bbe68da231b..db7abbcc13ab933aba6b11860c5b594d2bc16812 100644 (file)
@@ -32,12 +32,13 @@ class Dict(collections.abc.Mapping):
     def __getitem__(self, key):
         return self._odict.__getitem__(key)
 
-    def __hash__(self):
+    def __hash__(self):  # pylint: disable=invalid-hash-returned
         if self._hash is None:
             h = 0
             for key in sorted(self._odict.keys()):
                 h ^= hash(key)
             object.__setattr__(self, '_hash', h)
+        # this does return an int, but pylint doesn't figure that out
         return self._hash
 
     def __len__(self):
index 45ede79b3fd829e72a27ecb2aa8976b7ad3d93c0..cc2f71480a95085fdb99c9c7da4db0985a105a0e 100644 (file)
@@ -201,7 +201,7 @@ class Zone(dns.zone.Zone):
         self._write_waiters = collections.deque()
         self._commit_version_unlocked(WritableVersion(self), origin)
 
-    def reader(self, id=None, serial=None):
+    def reader(self, id=None, serial=None):  # pylint: disable=arguments-differ
         if id is not None and serial is not None:
             raise ValueError('cannot specify both id and serial')
         with self.version_lock: