projectdiscovery/nuclei · error
errors occurred during template validation
Error message
errors occurred during template validation
What it means
Error "errors occurred during template validation" thrown in projectdiscovery/nuclei.
Source
Thrown at pkg/catalog/loader/loader.go:644
workflowPaths, errs := store.config.Catalog.GetTemplatesPath(store.finalWorkflows)
store.logErroredTemplates(errs)
templatePathsMap := make(map[string]struct{}, len(templatePaths))
for _, path := range templatePaths {
templatePathsMap[path] = struct{}{}
}
workflowPathsMap := make(map[string]struct{}, len(workflowPaths))
for _, path := range workflowPaths {
workflowPathsMap[path] = struct{}{}
}
if store.areTemplatesValid(templatePathsMap) && store.areWorkflowsValid(workflowPathsMap) {
return nil
}
return errors.New("errors occurred during template validation")
}
func (store *Store) areWorkflowsValid(filteredWorkflowPaths map[string]struct{}) bool {
return store.areWorkflowOrTemplatesValid(filteredWorkflowPaths, true, func(templatePath string, tagFilter *templates.TagFilter) (bool, error) {
return store.config.ExecutorOptions.Parser.LoadWorkflow(templatePath, store.config.Catalog)
})
}
func (store *Store) areTemplatesValid(filteredTemplatePaths map[string]struct{}) bool {
return store.areWorkflowOrTemplatesValid(filteredTemplatePaths, false, func(templatePath string, tagFilter *templates.TagFilter) (bool, error) {
return store.config.ExecutorOptions.Parser.LoadTemplate(templatePath, store.tagFilter, nil, store.config.Catalog)
})
}
func (store *Store) areWorkflowOrTemplatesValid(filteredTemplatePaths map[string]struct{}, isWorkflow bool, load func(templatePath string, tagFilter *templates.TagFilter) (bool, error)) bool {
areTemplatesValid := true
for templatePath := range filteredTemplatePaths {View on GitHub (pinned to 265b3a3dec)
When it happens
Trigger: Thrown at pkg/catalog/loader/loader.go:644 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of projectdiscovery/nuclei@265b3a3dec (2026-08-15).
Data as JSON: /api/errors/612d9d5948f9571c.
Report an issue: GitHub.