summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Silverstone <daniel.silverstone@codethink.co.uk>2018-10-23 16:43:01 +0100
committerDaniel Silverstone <daniel.silverstone@codethink.co.uk>2018-10-25 15:43:52 +0100
commit68ec9bcf4118173e11192a93c649e360b714723c (patch)
tree7428c0be6cf3ca797620d4337db5e90e25ca4cbb
parentb4645745b6c327dd5d8e7c22c0fe37c0ae85f73c (diff)
downloadbuildstream-68ec9bcf4118173e11192a93c649e360b714723c.tar.gz
source.py: Quiet several pylint issues with abstract methods
A number of times, abstract methods are called which pylint cannot possibly understand will only ever happen in subclasses which implement the abstract methods. This silences those specific warnings Signed-off-by: Daniel Silverstone <daniel.silverstone@codethink.co.uk>
-rw-r--r--buildstream/source.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/buildstream/source.py b/buildstream/source.py
index e42bad1a5..8839747b9 100644
--- a/buildstream/source.py
+++ b/buildstream/source.py
@@ -637,7 +637,7 @@ class Source(Plugin):
# Source consistency interrogations are silent.
context = self._get_context()
with context.silence():
- self.__consistency = self.get_consistency()
+ self.__consistency = self.get_consistency() # pylint: disable=assignment-from-no-return
# Return cached consistency
#
@@ -687,14 +687,14 @@ class Source(Plugin):
key['directory'] = self.__directory
if include_source:
- key['unique'] = self.get_unique_key()
+ key['unique'] = self.get_unique_key() # pylint: disable=assignment-from-no-return
return key
# Wrapper for set_ref(), also returns whether it changed.
#
def _set_ref(self, ref, node):
- current_ref = self.get_ref()
+ current_ref = self.get_ref() # pylint: disable=assignment-from-no-return
changed = False
# This comparison should work even for tuples and lists,
@@ -773,7 +773,7 @@ class Source(Plugin):
elif project.ref_storage == ProjectRefStorage.PROJECT_REFS:
# First warn if there is a ref already loaded, and reset it
- redundant_ref = self.get_ref()
+ redundant_ref = self.get_ref() # pylint: disable=assignment-from-no-return
if redundant_ref is not None:
self.set_ref(None, {})
@@ -883,7 +883,7 @@ class Source(Plugin):
else:
new_ref = self.__do_track()
- current_ref = self.get_ref()
+ current_ref = self.get_ref() # pylint: disable=assignment-from-no-return
if new_ref is None:
# No tracking, keep current ref
@@ -1046,7 +1046,7 @@ class Source(Plugin):
for uri in reversed(project.get_alias_uris(alias, first_pass=self.__first_pass)):
new_source = self.__clone_for_uri(uri)
try:
- ref = new_source.track(**kwargs)
+ ref = new_source.track(**kwargs) # pylint: disable=assignment-from-none
# FIXME: Need to consider temporary vs. permanent failures,
# and how this works with retries.
except BstError as e: