Merge branch 'juerg/unused-cache-keys' into 'master'

Remove unused _cache_key variables and get_cache_key() methods

See merge request BuildStream/buildstream!1481
diff --git a/src/buildstream/_context.py b/src/buildstream/_context.py
index 1e45d77..bb9825f 100644
--- a/src/buildstream/_context.py
+++ b/src/buildstream/_context.py
@@ -20,7 +20,6 @@
 import os
 import shutil
 from . import utils
-from . import _cachekey
 from . import _site
 from . import _yaml
 from ._exceptions import LoadError, LoadErrorReason
@@ -154,7 +153,6 @@
         self.messenger = Messenger()
 
         # Private variables
-        self._cache_key = None
         self._artifactcache = None
         self._sourcecache = None
         self._projects = []
@@ -455,21 +453,6 @@
         # value which we cache here too.
         return self._strict_build_plan
 
-    # get_cache_key():
-    #
-    # Returns the cache key, calculating it if necessary
-    #
-    # Returns:
-    #    (str): A hex digest cache key for the Context
-    #
-    def get_cache_key(self):
-        if self._cache_key is None:
-
-            # Anything that alters the build goes into the unique key
-            self._cache_key = _cachekey.generate_key({})
-
-        return self._cache_key
-
     # set_artifact_directories_optional()
     #
     # This indicates that the current context (command or configuration)
diff --git a/src/buildstream/_project.py b/src/buildstream/_project.py
index a2ce5ae..6a2c0f3 100644
--- a/src/buildstream/_project.py
+++ b/src/buildstream/_project.py
@@ -24,7 +24,6 @@
 from pathlib import Path
 from pluginbase import PluginBase
 from . import utils
-from . import _cachekey
 from . import _site
 from . import _yaml
 from ._artifactelement import ArtifactElement
@@ -137,7 +136,6 @@
         self._default_mirror = default_mirror    # The name of the preferred mirror.
 
         self._cli_options = cli_options
-        self._cache_key = None
 
         self._fatal_warnings = []             # A list of warnings which should trigger an error
 
@@ -219,22 +217,6 @@
     def get_shell_config(self):
         return (self._shell_command, self._shell_environment, self._shell_host_files)
 
-    # get_cache_key():
-    #
-    # Returns the cache key, calculating it if necessary
-    #
-    # Returns:
-    #    (str): A hex digest cache key for the Context
-    #
-    def get_cache_key(self):
-        if self._cache_key is None:
-
-            # Anything that alters the build goes into the unique key
-            # (currently nothing here)
-            self._cache_key = _cachekey.generate_key({})
-
-        return self._cache_key
-
     # get_path_from_node()
     #
     # Fetches the project path from a dictionary node and validates it