diff options
author | Harmen Stoppels <harmenstoppels@gmail.com> | 2021-10-25 15:55:51 +0200 |
---|---|---|
committer | Massimiliano Culpo <massimiliano.culpo@gmail.com> | 2021-10-25 17:07:56 +0200 |
commit | 276e637522619c83fee027ba8ffa4bab874c6304 (patch) | |
tree | 27f9fe8f169d63043550b66e60021b726644f6db /lib | |
parent | b51e0b363e1b051ed29ab49e59b6f43d418eddcf (diff) | |
download | spack-276e637522619c83fee027ba8ffa4bab874c6304.tar.gz spack-276e637522619c83fee027ba8ffa4bab874c6304.tar.bz2 spack-276e637522619c83fee027ba8ffa4bab874c6304.tar.xz spack-276e637522619c83fee027ba8ffa4bab874c6304.zip |
Reduce verbosity of module files warning
1. Currently it prints not just the spec name, but the dependencies +
their variants + their compilers + their architectures + ...
2. It's clear from the context what spec the message applies to, so,
let's not print the spec at all.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/spack/spack/modules/common.py | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/spack/spack/modules/common.py b/lib/spack/spack/modules/common.py index 0e9c8eac68..7c34a5338e 100644 --- a/lib/spack/spack/modules/common.py +++ b/lib/spack/spack/modules/common.py @@ -836,9 +836,7 @@ class BaseModuleFileWriter(object): # Print a warning in case I am accidentally overwriting # a module file that is already there (name clash) if not overwrite and os.path.exists(self.layout.filename): - message = 'Module file already exists : skipping creation\n' - message += 'file : {0.filename}\n' - message += 'spec : {0.spec}' + message = 'Module file {0.filename} exists and will not be overwritten' tty.warn(message.format(self.layout)) return |