{"record":{"id":"2d51da7faf8841ff","repo":"hashicorp/nomad","slug":"tagged-version-description-must-be-under-1000-char","errorCode":null,"errorMessage":"Tagged version description must be under 1000 characters, currently %d","messagePattern":"Tagged version description must be under 1000 characters, currently (.+?)","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"nomad/structs/structs.go","lineNumber":4820,"sourceCode":"\t} else {\n\t\tfor idx, spread := range j.Spreads {\n\t\t\tif err := spread.Validate(); err != nil {\n\t\t\t\touter := fmt.Errorf(\"Spread %d validation failed: %s\", idx+1, err)\n\t\t\t\tmErr.Errors = append(mErr.Errors, outer)\n\t\t\t}\n\t\t}\n\t}\n\n\tconst MaxDescriptionCharacters = 1000\n\tif j.UI != nil {\n\t\tif len(j.UI.Description) > MaxDescriptionCharacters {\n\t\t\tmErr.Errors = append(mErr.Errors, fmt.Errorf(\"UI description must be under 1000 characters, currently %d\", len(j.UI.Description)))\n\t\t}\n\t}\n\n\tif j.VersionTag != nil {\n\t\tif len(j.VersionTag.Description) > MaxDescriptionCharacters {\n\t\t\tmErr.Errors = append(mErr.Errors, fmt.Errorf(\"Tagged version description must be under 1000 characters, currently %d\", len(j.VersionTag.Description)))\n\t\t}\n\t}\n\n\t// Check for duplicate task groups\n\ttaskGroups := make(map[string]int)\n\tfor idx, tg := range j.TaskGroups {\n\t\tif tg.Name == \"\" {\n\t\t\tmErr.Errors = append(mErr.Errors, fmt.Errorf(\"Job task group %d missing name\", idx+1))\n\t\t} else if existing, ok := taskGroups[tg.Name]; ok {\n\t\t\tmErr.Errors = append(mErr.Errors, fmt.Errorf(\"Job task group %d redefines '%s' from group %d\", idx+1, tg.Name, existing+1))\n\t\t} else {\n\t\t\ttaskGroups[tg.Name] = idx\n\t\t}\n\n\t\tif tg.ShutdownDelay != nil && *tg.ShutdownDelay < 0 {\n\t\t\tmErr.Errors = append(mErr.Errors, errors.New(\"ShutdownDelay must be a positive value\"))\n\t\t}\n","sourceCodeStart":4802,"sourceCodeEnd":4838,"githubUrl":"https://github.com/hashicorp/nomad/blob/482b49bf1aec006f089bcfc7e632d8f6ac303e5e/nomad/structs/structs.go#L4802-L4838","documentation":"Job.Validate() enforces the same 1000-character limit (MaxDescriptionCharacters) on j.VersionTag.Description, appending this error when exceeded. Version tags annotate job versions in the UI, and their descriptions are size-bounded.","triggerScenarios":"Submitting a job with a version_tag block whose description exceeds 1000 characters.","commonSituations":"CI pipelines stamping job versions with full commit messages, git notes, or generated build reports as the version tag description.","solutions":["Shorten VersionTag.Description below 1000 characters","Summarize the change and link to full details externally","Truncate programmatically in the CI templating step","Validate the job spec with 'nomad job validate' before submit"],"exampleFix":"// before\nversion_tag {\n  description = \"<full 1500-char commit message>\"\n}\n// after\nversion_tag {\n  description = \"feat: add retry logic (abc1234)\"\n}","handlingStrategy":"validation","validationCode":"const maxDesc = 1000\nif job.VersionTag != nil && len(job.VersionTag.Description) > maxDesc {\n    return fmt.Errorf(\"version tag description is %d chars; max %d\", len(job.VersionTag.Description), maxDesc)\n}\nreturn nil","typeGuard":null,"tryCatchPattern":"if err := job.Validate(); err != nil {\n    if strings.Contains(err.Error(), \"Tagged version description\") {\n        return ErrVersionTagTooLong\n    }\n    return err\n}","preventionTips":["Use commit subject line only, not full message, for version tags","Truncate CI-generated tag descriptions to <= 999 chars","Validate tagged jobs before register in the release pipeline"],"tags":["nomad","job-validation","version-tag","description-length"],"backgroundTag":"nomad-job-validation-failed","analyzedSha":"482b49bf1aec006f089bcfc7e632d8f6ac303e5e","analyzedAt":"2026-09-04T07:54:14.808Z","contentChangedAt":"2026-09-04T07:54:14.808Z","schemaVersion":2},"datasetVersion":"2026-09-08T10:18:20.063Z"}