googleapis/mcp-toolbox · error
invalid source for %q tool: source %q is not a compatible ty
Error message
invalid source for %q tool: source %q is not a compatible type
What it means
The modify-spec vector tool's ValidateSource guard rejected the configured source because it does not implement compatibleSource — the tool is bound to a source that is not a Cloud SQL for Postgres source (with pgvector).
Source
Thrown at internal/tools/cloudsqlpg/vectorassistmodifyspec/vectorassistmodifyspec.go:151
resp, err := source.RunSQL(ctx, modifySpecQuery, []any{namedArgs})
if err != nil {
return nil, util.ProcessGeneralError(err)
}
return resp, nil
}
func (t Tool) GetSourceName() string {
return t.Cfg.Source
}
func (t Tool) ToConfig() tools.ToolConfig {
return t.Cfg
}
func (t Tool) ValidateSource(source sources.Source) error {
_, ok := source.(compatibleSource)
if !ok {
return fmt.Errorf("invalid source for %q tool: source %q is not a compatible type", t.Cfg.Type, t.Cfg.Source)
}
return nil
}
View on GitHub (pinned to 8cc6e09de2)
Solutions
- Point the tool's `source` at a Cloud SQL for Postgres source
- Check the source name for typos
- Verify the source `type` matches what this tool requires
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at internal/tools/cloudsqlpg/vectorassistmodifyspec/vectorassistmodifyspec.go:151 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of googleapis/mcp-toolbox@8cc6e09de2 (2026-09-05).
Data as JSON: /api/errors/e55ac0b1026616fa.
Report an issue: GitHub.