grafana/k6 · error

scenario %s has configuration errors: %s

Error message

scenario %s has configuration errors: %s

What it means

Aggregating error from ScenarioConfigs.Validate: it runs each scenario's own Validate and, when any scenario returns validation errors, wraps them all (joined with commas) under the scenario's name. The real cause is in the nested errors.

Source

Thrown at lib/executors.go:203

		}
		config, err := GetParsedExecutorConfig(k, v.executorType, v.rawJSON)
		if err != nil {
			return err
		}
		result[k] = config
	}

	*scs = result

	return nil
}

// Validate checks if all of the specified executor options make sense
func (scs ScenarioConfigs) Validate() (errors []error) {
	for name, exec := range scs {
		if execErr := exec.Validate(); len(execErr) != 0 {
			errors = append(errors,
				fmt.Errorf("scenario %s has configuration errors: %s", name, ConcatErrors(execErr, ", ")))
		}
	}
	return errors
}

// GetSortedConfigs returns a slice with the executor configurations,
// sorted in a consistent and predictable manner. It is useful when we want or
// have to avoid using maps with string keys (and tons of string lookups in
// them) and avoid the unpredictable iterations over Go maps. Slices allow us
// constant-time lookups and ordered iterations.
//
// The configs in the returned slice will be sorted by their start times in an
// ascending order, and alphabetically by their names (which are unique) if
// there are ties.
func (scs ScenarioConfigs) GetSortedConfigs() []ExecutorConfig {
	configs := make([]ExecutorConfig, len(scs))

	// Populate the configs slice with sorted executor configs

View on GitHub (pinned to 01ffac6f24)

Solutions

  1. Read the nested error details to find which scenario option is invalid
  2. Fix each reported scenario's options (VU counts, durations, rates, stages)
  3. Re-run k6 until per-scenario validation passes
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at lib/executors.go:203 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of grafana/k6@01ffac6f24 (2026-08-18). Data as JSON: /api/errors/c8e54ab3b7ddfa7b. Report an issue: GitHub.