summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorMassimiliano Culpo <massimiliano.culpo@googlemail.com>2017-05-03 06:21:37 +0200
committerGitHub <noreply@github.com>2017-05-03 06:21:37 +0200
commitae9a9e019a73cb951d4d2a2585ac71a53f351c81 (patch)
tree34e2c1fb2c4b3f519c699a9c7ecba046be5a1698 /lib
parent72d45f7a446a6293ff675fce652a62f27ef2ed77 (diff)
downloadspack-ae9a9e019a73cb951d4d2a2585ac71a53f351c81.tar.gz
spack-ae9a9e019a73cb951d4d2a2585ac71a53f351c81.tar.bz2
spack-ae9a9e019a73cb951d4d2a2585ac71a53f351c81.tar.xz
spack-ae9a9e019a73cb951d4d2a2585ac71a53f351c81.zip
spack: no stacktrace if not in debug mode + fix emacs variant (#4098)
* spack: no stacktrace if not in debug mode + fix emacs variant * emacs: removed dead code
Diffstat (limited to 'lib')
-rw-r--r--lib/spack/spack/variant.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/spack/spack/variant.py b/lib/spack/spack/variant.py
index 7102676b69..2d02ab1253 100644
--- a/lib/spack/spack/variant.py
+++ b/lib/spack/spack/variant.py
@@ -389,9 +389,9 @@ class BoolValuedVariant(SingleValuedVariant):
self._original_value = value
self._value = False
else:
- msg = 'cannot construct a BoolValuedVariant from '
+ msg = 'cannot construct a BoolValuedVariant for "{0}" from '
msg += 'a value that does not represent a bool'
- raise ValueError(msg)
+ raise ValueError(msg.format(self.name))
def __contains__(self, item):
return item is self.value