From d51af675ef345a191aa995b82609e5f6776184a3 Mon Sep 17 00:00:00 2001 From: Harmen Stoppels Date: Wed, 19 Apr 2023 23:17:47 +0200 Subject: make version(...) kwargs explicit (#36998) - [x] Replace `version(ver, checksum=None, **kwargs)` signature with `version(ver, checksum=None, *, sha256=..., ...)` explicitly listing all arguments. - [x] Fix various issues in packages: - `tags` instead of `tag` - `default` instead of `preferred` - `sha26` instead of `sha256` - etc Also, use `sha256=...` consistently. Note: setting `sha256` currently doesn't validate the checksum length, so you could do `sha256="a"*32` and it would get checked as `md5`... but that's something for another PR. --- var/spack/repos/builtin.mock/packages/fetch-options/package.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'var/spack/repos/builtin.mock/packages/fetch-options/package.py') diff --git a/var/spack/repos/builtin.mock/packages/fetch-options/package.py b/var/spack/repos/builtin.mock/packages/fetch-options/package.py index 94611ad5f8..74a1215074 100644 --- a/var/spack/repos/builtin.mock/packages/fetch-options/package.py +++ b/var/spack/repos/builtin.mock/packages/fetch-options/package.py @@ -17,6 +17,6 @@ class FetchOptions(Package): timeout = {"timeout": 65} cookie = {"cookie": "baz"} - version("1.2", "00000000000000000000000000000012", fetch_options=cookie) - version("1.1", "00000000000000000000000000000011", fetch_options=timeout) - version("1.0", "00000000000000000000000000000010") + version("1.2", md5="00000000000000000000000000000012", fetch_options=cookie) + version("1.1", md5="00000000000000000000000000000011", fetch_options=timeout) + version("1.0", md5="00000000000000000000000000000010") -- cgit v1.2.3-60-g2f50