buildcache: ignore errors of newer buildcache version (#40279)
Currently buildcaches are forward incompatible in an annoying way: spack errors out when trying to use them. With this change, you just get a warning.
This commit is contained in:
parent
a9dcba76ce
commit
6c4ce379ca
1 changed files with 2 additions and 2 deletions
|
@ -216,11 +216,11 @@ def _associate_built_specs_with_mirror(self, cache_key, mirror_url):
|
|||
with self._index_file_cache.read_transaction(cache_key):
|
||||
db._read_from_file(cache_path)
|
||||
except spack_db.InvalidDatabaseVersionError as e:
|
||||
msg = (
|
||||
tty.warn(
|
||||
f"you need a newer Spack version to read the buildcache index for the "
|
||||
f"following mirror: '{mirror_url}'. {e.database_version_message}"
|
||||
)
|
||||
raise BuildcacheIndexError(msg) from e
|
||||
return
|
||||
|
||||
spec_list = db.query_local(installed=False, in_buildcache=True)
|
||||
|
||||
|
|
Loading…
Reference in a new issue