Conversation
|
🧪 Testing To try out this version of the SDK: Expires at: Mon, 06 Apr 2026 15:46:51 GMT |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
| // If the API asks us to wait a certain amount of time (and it's a reasonable amount), | ||
| // just do what it says. | ||
|
|
||
| if retryAfterDelay, ok := parseRetryAfterHeader(res); ok && 0 <= retryAfterDelay && retryAfterDelay < time.Minute { |
There was a problem hiding this comment.
Removed upper bound allows unbounded retry delay
Medium Severity
The retryDelay function previously capped server-provided Retry-After values at under one minute, falling through to exponential backoff (max 8 seconds) for larger values. The new code removes that upper bound entirely, meaning a server sending a large Retry-After value (e.g., hours or days) will cause the client to block for that entire duration. While ctx.Done() in the select provides protection when a context deadline is set, callers without a deadline could experience unbounded blocking.
7338e85 to
ee5e3db
Compare
ee5e3db to
28c58ac
Compare


Automated Release PR
0.42.2 (2026-03-07)
Full Changelog: v0.42.1...v0.42.2
Chores
This pull request is managed by Stainless's GitHub App.
The semver version number is based on included commit messages. Alternatively, you can manually set the version number in the title of this pull request.
For a better experience, it is recommended to use either rebase-merge or squash-merge when merging this pull request.
🔗 Stainless website
📚 Read the docs
🙋 Reach out for help or questions
Note
Medium Risk
Changes retry backoff behavior by always honoring
Retry-After/Retry-After-Ms(clamped to non-negative), which can materially affect request timing and throughput under error conditions. Other updates are CI gating and routine release/version bumps.Overview
Releases
v0.42.2. Updates version metadata (internal/version.go,.release-please-manifest.json), documentation (README.md), andCHANGELOG.md.CI artifact uploads are now skipped on internal
stl/*branches. Thebuildjob only fetches an OIDC token and uploads the tarball when the ref does not start withrefs/heads/stl/.Retry behavior change:
internal/requestconfig.retryDelaynow always uses the server-provided retry delay (viaRetry-Afterheaders) and clamps negative values to0, instead of ignoring large values.Test fixtures update placeholder upload content strings from "some file contents" to "Example data".
Written by Cursor Bugbot for commit 28c58ac. This will update automatically on new commits. Configure here.