summaryrefslogtreecommitdiffhomepage
path: root/internal/llm/provider
diff options
context:
space:
mode:
authorKujtim Hoxha <[email protected]>2025-04-25 14:42:21 +0200
committerKujtim Hoxha <[email protected]>2025-04-25 14:42:47 +0200
commit170c7ad67abd840fd89aef3c79b5eff32e3aec5c (patch)
treed6d869c46bab7ddfbe6ca2957360a90d74f1509d /internal/llm/provider
parent7a62ab7675dd042266611205c43e9869a2da1664 (diff)
downloadopencode-170c7ad67abd840fd89aef3c79b5eff32e3aec5c.tar.gz
opencode-170c7ad67abd840fd89aef3c79b5eff32e3aec5c.zip
small fixes
Diffstat (limited to 'internal/llm/provider')
-rw-r--r--internal/llm/provider/anthropic.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/internal/llm/provider/anthropic.go b/internal/llm/provider/anthropic.go
index e5c478a7f..bb120b6ad 100644
--- a/internal/llm/provider/anthropic.go
+++ b/internal/llm/provider/anthropic.go
@@ -213,7 +213,7 @@ func (a *anthropicClient) send(ctx context.Context, messages []message.Message,
return nil, retryErr
}
if retry {
- logging.WarnPersist("Retrying due to rate limit... attempt %d of %d", logging.PersistTimeArg, time.Millisecond*time.Duration(after+100))
+ logging.WarnPersist(fmt.Sprintf("Retrying due to rate limit... attempt %d of %d", attempts, maxRetries), logging.PersistTimeArg, time.Millisecond*time.Duration(after+100))
select {
case <-ctx.Done():
return nil, ctx.Err()
@@ -351,7 +351,7 @@ func (a *anthropicClient) stream(ctx context.Context, messages []message.Message
return
}
if retry {
- logging.WarnPersist("Retrying due to rate limit... attempt %d of %d", logging.PersistTimeArg, time.Millisecond*time.Duration(after+100))
+ logging.WarnPersist(fmt.Sprintf("Retrying due to rate limit... attempt %d of %d", attempts, maxRetries), logging.PersistTimeArg, time.Millisecond*time.Duration(after+100))
select {
case <-ctx.Done():
// context cancelled