fix: add detail to error message to allow better debugging
commit84cd37f69a4b09f833ba2ed73a53fec10c28191d
authorAndrey Nering <andreynering@users.noreply.github.com>
dateThu 23 Oct 2025, 13:59 (1 year ago)
parent4efb4ef
internal/agent/coordinator.go+2−1
@@ -6,6 +6,7 @@ import (
66 "context"
77 "encoding/json"
88 "errors"
9+ "fmt"
910 "io"
1011 "log/slog"
1112 "slices"
@@ -605,7 +606,7 @@ func (c *coordinator) buildProvider(providerCfg config.ProviderConfig, model con
605606 case openaicompat.Name:
606607 return c.buildOpenaiCompatProvider(baseURL, apiKey, headers)
607608 default:
608− return nil, errors.New("provider type not supported")
609+ return nil, fmt.Errorf("provider type not supported: %q", providerCfg.Type)
609610 }
610611}
611612