grafana/k6 · error
an invalid type ( ) is specified for an InfluxDB field ( )
Error message
an invalid type (%s) is specified for an InfluxDB field (%s)
What it means
A tag listed in K6_INFLUXDB_TAGS_AS_FIELDS was given a type suffix that is not one of string, bool, float or int. MakeFieldKinds switches on the declared field type and falls through to this error for the named field.
Solutions
- Use one of the supported types: string, bool, float or int
- Example: K6_INFLUXDB_TAGS_AS_FIELDS=check_name:string,check_duration:float
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at internal/output/influxdb/util.go:86 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/1bdf6e14f2488e3b.
Report an issue: GitHub.
Appendix: source
Thrown at internal/output/influxdb/util.go:86
fieldType = "string"
}
err := checkDuplicatedTypeDefinitions(fieldKinds, fieldName)
if err != nil {
return nil, err
}
switch fieldType {
case "string":
fieldKinds[fieldName] = String
case "bool":
fieldKinds[fieldName] = Bool
case "float":
fieldKinds[fieldName] = Float
case "int":
fieldKinds[fieldName] = Int
default:
return nil, fmt.Errorf("an invalid type (%s) is specified for an InfluxDB field (%s)",
fieldType, fieldName)
}
}
return fieldKinds, nil
}
View on GitHub (pinned to 01ffac6f24)