googleapis/mcp-toolbox · error
unable to execute query: %w
Error message
unable to execute query: %w
What it means
Error "unable to execute query: %w" thrown in googleapis/mcp-toolbox.
Source
Thrown at internal/sources/cloudsqlpg/cloud_sql_pg.go:122
}
func (s *Source) SourceType() string {
return SourceType
}
func (s *Source) ToConfig() sources.SourceConfig {
return s.Config
}
func (s *Source) PostgresPool() *pgxpool.Pool {
return s.Pool
}
func (s *Source) RunSQL(ctx context.Context, statement string, params []any) (any, error) {
statement = sqlcommenter.PrependComment(ctx, statement, SourceType, s.SQLCommenter)
results, err := s.PostgresPool().Query(ctx, statement, params...)
if err != nil {
return nil, fmt.Errorf("unable to execute query: %w", err)
}
defer results.Close()
fields := results.FieldDescriptions()
out := []any{}
for results.Next() {
values, err := results.Values()
if err != nil {
return nil, fmt.Errorf("unable to parse row: %w", err)
}
row := orderedmap.Row{}
for i, f := range fields {
val := sources.NormalizeValue(values[i], f.DataTypeOID)
row.Add(f.Name, val)
}
out = append(out, row)
}
// this will catch actual query execution errorsView on GitHub (pinned to 8cc6e09de2)
When it happens
Trigger: Thrown at internal/sources/cloudsqlpg/cloud_sql_pg.go:122 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/b7e639b61681464d.
Report an issue: GitHub.