-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add chat streaming helpers #190
Merged
Merged
+5,794
−547
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dgellow
reviewed
Apr 2, 2025
src/error.ts
Outdated
Comment on lines
132
to
142
export class LengthFinishReasonError extends WriterError { | ||
constructor() { | ||
super(`Could not parse response content as the length limit was reached`); | ||
} | ||
} | ||
|
||
export class ContentFilterFinishReasonError extends WriterError { | ||
constructor() { | ||
super(`Could not parse response content as the request was rejected by the content filter`); | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@sarahcstringer Those 2 errors will need to be moved to src/core/error.ts
Merged
sarahcstringer
added a commit
that referenced
this pull request
Apr 2, 2025
* docs: update URLs from stainlessapi.com to stainless.com (#176) More details at https://www.stainless.com/changelog/stainless-com * chore(client): only accept standard types for file uploads (#178) * chore(internal): fix tests failing on node v18 (#179) * chore(internal): constrain synckit dev dependency (#180) * fix(client): fix TypeError with undefined File (#181) * fix(internal): clean up undefined File test (#182) * fix(tests): manually reset node:buffer File (#183) * chore(types): improved go to definition on fetchOptions (#184) * chore(docs): improve docs for withResponse/asResponse (#185) * feat: add SKIP_BREW env var to ./scripts/bootstrap (#187) * feat(client): accept RFC6838 JSON content types (#188) * docs(api): updates to API spec (#189) * chore(internal): remove extra empty newlines (#191) * fix(exports): ensure resource imports don't require /index (#192) * fix(internal): add mts file + crypto shim types (#193) * chore(internal): minor client file refactoring (#194) * chore(exports): cleaner resource index imports (#195) * chore(exports): stop using path fallbacks (#196) * chore(docs): fix typo (#197) * chore(docs): migration guide re-ordering (#198) * docs(api): updates to API spec (#199) * chore(internal): Fix README samples. (#200) * feat(api): Add Vision endpoint. (#202) * feat(api): Add Vision endpoint. (#203) * docs(api): updates to API spec (#204) * codegen metadata * chore(client): more accurate streaming errors (#205) * chore(internal): codegen related update (#206) * docs(api): updates to API spec (#207) * feat: add chat streaming helpers (#190) * feat: add streaming helpers * fix missing errors * lint --------- Co-authored-by: Samuel El-Borai <[email protected]> Co-authored-by: Sarah Deaton <[email protected]> Co-authored-by: Reid <[email protected]> * release: 2.1.0-rc.1 --------- Co-authored-by: stainless-app[bot] <142633134+stainless-app[bot]@users.noreply.github.com> Co-authored-by: Samuel El-Borai <[email protected]> Co-authored-by: Sarah Deaton <[email protected]> Co-authored-by: Reid <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.