hashicorp/nomad · error
unsupported checksum type: %s
Error message
unsupported checksum type: %s
What it means
Artifact checksum validation error: the checksum prefix before the ':' is not one of the recognized types (md5, sha1, sha256, sha512, file). Nomad cannot pick a digest length or verifier for an unknown algorithm name.
Source
Thrown at nomad/structs/structs.go:10001
expectedLength := 0
switch checksumType {
case "md5":
if fips140.Enabled() {
return fmt.Errorf("md5 checksums are not supported in FIPS-140 mode")
}
expectedLength = md5.Size
case "sha1":
if fips140.Enabled() {
return fmt.Errorf("sha1 checksums are not supported in FIPS-140 mode")
}
expectedLength = sha1.Size
case "sha256":
expectedLength = sha256.Size
case "sha512":
expectedLength = sha512.Size
default:
return fmt.Errorf("unsupported checksum type: %s", checksumType)
}
if len(checksumBytes) != expectedLength {
return fmt.Errorf("invalid %s checksum: %v", checksumType, checksumVal)
}
return nil
}
const (
ConstraintDistinctProperty = "distinct_property"
ConstraintDistinctHosts = "distinct_hosts"
ConstraintRegex = "regexp"
ConstraintVersion = "version"
ConstraintSemver = "semver"
ConstraintSetContains = "set_contains"
ConstraintSetContainsAll = "set_contains_all"
ConstraintSetContainsAny = "set_contains_any"View on GitHub (pinned to 482b49bf1a)
Solutions
- Use a supported type: md5, sha1, sha256, or sha512 (prefer sha256).
- Fix typos such as 'sha265' -> 'sha256'.
- Use checksum = "file:<url>" if the remote side provides a checksum file go-getter can consume.
Example fix
// before checksum = "sha384:abcd..." // after checksum = "sha256:abcd..."
Defensive patterns
Strategy: validation
Validate before calling
var validTypes = map[string]bool{"md5":true,"sha1":true,"sha256":true,"sha512":true,"file":true}
type := strings.SplitN(checksum, ":", 2)[0]
if !validTypes[type] { return fmt.Errorf("unsupported checksum type %q", type) } Prevention
- Keep a canonical list of supported types in your job templating code
- Spell-check algorithm names; watch for sha265-style typos
- Prefer sha256 by convention
When it happens
Trigger: checksum = "sha384:<hex>", "crc32:...", "blake2:...", or a misspelled type like "sha265:<hex>" in an artifact block.
Common situations: Typo'd algorithm names; algorithms supported by other tools (sha384, blake3) assumed supported here; copy-paste from docs of a different product.
Related errors
- checksum value cannot be empty
- http_max_size not a valid size: %w
- checksum must be given as "type:value"; got %q
- invalid checksum: %v
- invalid %s checksum: %v
AI-assisted analysis of hashicorp/nomad@482b49bf1a (2026-09-04).
Data as JSON: /api/errors/6731f8f041f98edc.
Report an issue: GitHub.