hashicorp/packer · error

builder type not found: %s

Error message

builder type not found: %s

What it means

Builders.Start returned no error but a nil builder — a defensive check for a plugin registry inconsistency where the launched plugin did not yield a builder implementation. Packer reports the builder type as 'not found'.

Source

Thrown at packer/core.go:483

		)

		if sugg := didyoumean.NameSuggestion(configBuilder.Type, c.components.PluginConfig.Builders.List()); sugg != "" {
			err = fmt.Errorf("Did you mean to use %q?", sugg)
		}

		return nil, err
	}

	// the Start command launches the builder plugin of the given type without
	// calling Prepare() or passing any build-specific details.
	builder, err := c.components.PluginConfig.Builders.Start(configBuilder.Type)
	if err != nil {
		return nil, fmt.Errorf(
			"error initializing builder '%s': %s",
			configBuilder.Type, err)
	}
	if builder == nil {
		return nil, fmt.Errorf(
			"builder type not found: %s", configBuilder.Type)
	}

	// rawName is the uninterpolated name that we use for various lookups
	rawName := configBuilder.Name

	// Setup the provisioners for this build
	provisioners := make([]CoreBuildProvisioner, 0, len(c.Template.Provisioners))
	for _, rawP := range c.Template.Provisioners {
		// If we're skipping this, then ignore it
		if rawP.OnlyExcept.Skip(rawName) {
			continue
		}
		cbp, err := c.generateCoreBuildProvisioner(rawP, rawName)
		if err != nil {
			return nil, err
		}

View on GitHub (pinned to eb36e3c3e4)

Solutions

  1. Reinstall the plugin providing the builder type to restore a working factory.
  2. Check for duplicate/conflicting plugin registrations of the same type name.
  3. Upgrade Packer core; if reproducible with a stock builder, file an upstream bug.
  4. Use an alternate builder type as a workaround.
Defensive patterns

Strategy: try-catch

Try / catch

if _, err := core.Build(n); err != nil {
    if strings.Contains(err.Error(), "builder type not found") {
        return fmt.Errorf("plugin for %s returned no builder; reinstall the plugin", builderType)
    }
    return err
}

Prevention

When it happens

Trigger: Core.Build: c.components.PluginConfig.Builders.Start(configBuilder.Type) returns (nil, nil), typically due to a misregistered builtin/custom plugin factory returning nil. Raised during `packer build`.

Common situations: Custom or embedded plugin builds overriding a builtin builder with a nil factory; internal wiring bugs; corrupted plugin distributions. Rare for end users.

Related errors


AI-assisted analysis of hashicorp/packer@eb36e3c3e4 (2026-09-05). Data as JSON: /api/errors/56b55555f574b76e. Report an issue: GitHub.