summaryrefslogtreecommitdiff
path: root/lib/spack/spack/spec.py
diff options
context:
space:
mode:
Diffstat (limited to 'lib/spack/spack/spec.py')
-rw-r--r--lib/spack/spack/spec.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/spack/spack/spec.py b/lib/spack/spack/spec.py
index 4e5226b0d6..3d3e23e253 100644
--- a/lib/spack/spack/spec.py
+++ b/lib/spack/spack/spec.py
@@ -2056,14 +2056,15 @@ class Spec(object):
# to be included. This is effectively the last chance we get to compute
# it accurately.
if self.concrete:
+ # all specs have at least a DAG hash
node[ht.dag_hash.name] = self.dag_hash()
+
else:
node['concrete'] = False
- if hash.name == 'process_hash':
- node[hash.name] = self.process_hash()
- elif hash.name == 'runtime_hash':
- node[hash.name] = self.runtime_hash()
+ # we can also give them other hash types if we want
+ if hash.name != ht.dag_hash.name:
+ node[hash.name] = self._cached_hash(hash)
return node