Conversation
8bd7915 to
e8ded67
Compare
e8ded67 to
98fe444
Compare
98fe444 to
b62d5d4
Compare
b62d5d4 to
14ff965
Compare
14ff965 to
ef22972
Compare
ef22972 to
67b2c1e
Compare
67b2c1e to
dde6e53
Compare
dde6e53 to
e9717d6
Compare
e9717d6 to
f891d52
Compare
f891d52 to
c706e22
Compare
c706e22 to
cda41d6
Compare
cda41d6 to
8920203
Compare
6706f92 to
daebcfe
Compare
daebcfe to
e6aee21
Compare
| logprobs?: CompletionsAPI.LogProbs; | ||
|
|
||
| text?: string; | ||
| } |
There was a problem hiding this comment.
Prompt interface defined in wrong namespace breaks ChatCompletion
High Severity
The ChatCompletion interface references ChatCompletion.Prompt at line 67, but the Prompt interface was placed inside the ChatCompletionAssistantMessageParam namespace instead of the ChatCompletion namespace. The ChatCompletion namespace only contains Choice and Warning. By contrast, Completion.Prompt in src/resources/completions.ts is correctly placed inside the Completion namespace. This is a code generation error that will prevent compilation.
Additional Locations (1)
e6aee21 to
8af489b
Compare
8af489b to
29dde16
Compare
29dde16 to
3cf30de
Compare
| if (!(timeoutMillis && 0 <= timeoutMillis && timeoutMillis < 60 * 1000)) { | ||
| // If the API asks us to wait a certain amount of time, just do what it | ||
| // says, but otherwise calculate a default | ||
| if (timeoutMillis === undefined) { |
There was a problem hiding this comment.
Retry delay accepts NaN and negative timeout values
Medium Severity
The retry timeout guard was changed from if (!(timeoutMillis && 0 <= timeoutMillis && timeoutMillis < 60 * 1000)) to if (timeoutMillis === undefined). The old condition also caught NaN, negative, and zero values, falling back to the default exponential backoff. The new condition only catches undefined, so if Date.parse(retryAfterHeader) - Date.now() produces NaN (invalid date) or a negative number (past date), sleep receives that value, bypassing backoff and causing immediate rapid retries.
3cf30de to
ff6d308
Compare
ff6d308 to
2981fbb
Compare
2981fbb to
ce7192e
Compare
ce7192e to
71cb006
Compare
71cb006 to
e193864
Compare
e193864 to
85451cf
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Free Tier Details
Your team is on the Bugbot Free tier. On this plan, Bugbot will review limited PRs each billing cycle for each member of your team.
To receive Bugbot reviews on all of your PRs, visit the Cursor dashboard to activate Pro and start your 14-day free trial.
Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
| * `logprobs` is also provided, log probability information is provided on the | ||
| * prompt. | ||
| */ | ||
| prompt: Array<Completion.Prompt>; |
There was a problem hiding this comment.
Conditional prompt field incorrectly marked as required
Medium Severity
The prompt field on Completion was changed from optional (prompt?) to required (prompt), but the docstring states "When echo is true, the prompt is included in the response." Since this field is only populated when echo is enabled, marking it as required misleads TypeScript users into assuming it's always present — leading to potential runtime TypeError when accessing completion.prompt without echo: true.
85451cf to
ef67ce3
Compare
ef67ce3 to
54abcc5
Compare


Automated Release PR
0.38.0 (2026-03-10)
Full Changelog: v0.37.0...v0.38.0
Features
Bug Fixes
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
Touches core HTTP client behavior (URL/query building, retries, request body encoding, abort handling), which can subtly affect request semantics; remaining changes are mostly generated type/docs and CI/test maintenance.
Overview
Releases
0.38.0with refreshed generated API surface: stronger/updated typings and docs across chat/completions (logprobs fields,promptecho typing), fine-tuning (nullabletraining_type,wandb_entity), files (removeLineCount, tightenFileResponse), and beta deployments/clusters/jig (structured autoscaling configs, volume versioning, queue response schemas).Client/runtime fixes include extracting
stringifyQuerytointernal/utils/query, preserving existing URL query params when building URLs, addingapplication/x-www-form-urlencodedbody encoding support, adjusting retry delay behavior to better respect server-providedRetry-After, and avoiding premature abort-listener cleanup.Build/test/ops updates: CI skips artifact upload on
stl/*internal branches,scripts/mockgains deterministic startup timeout/logging, several mock-server-incompatible tests are skipped/adjusted, and deps are pinned viaminimatchoverrides/resolutions (lockfile updated).Written by Cursor Bugbot for commit 54abcc5. This will update automatically on new commits. Configure here.