feat(sdk): add AbortController support so user can cancel API request#998
Merged
mathio merged 5 commits intolingodotdev:mainfrom Jul 8, 2025
Merged
feat(sdk): add AbortController support so user can cancel API request#998mathio merged 5 commits intolingodotdev:mainfrom
mathio merged 5 commits intolingodotdev:mainfrom
Conversation
Contributor
@VAIBHAVSING I dont see any removed files 🤔 |
Contributor
Author
|
@mathio sorry for that I don't remove any files or clean. |
mathio
suggested changes
Jul 3, 2025
Contributor
mathio
left a comment
There was a problem hiding this comment.
Your PR description reminds me of output from an LLM. In this case it does not provide any value to the reviewer. Please do not reference files like this, they are viewable in "Files changed" tab of the PR.
Contributor
Author
|
@mathio PTAL |
Contributor
|
Testing locally, works as expected: > tsc && node dist/index.js
node:internal/deps/undici/undici:13510
Error.captureStackTrace(err);
^
DOMException [AbortError]: This operation was aborted
at node:internal/deps/undici/undici:13510:13
at async LingoDotDevEngine.localizeChunk (/Users/m/work/lingo.dev/packages/sdk/build/index.cjs:74:17)
at async LingoDotDevEngine._localizeRaw (/Users/m/work/lingo.dev/packages/sdk/build/index.cjs:48:37)
Node.js v22.17.0
ELIFECYCLE Command failed with exit code 1. |
mathio
approved these changes
Jul 8, 2025
17prateek12
pushed a commit
to 17prateek12/lingo.dev
that referenced
this pull request
Jan 23, 2026
…lingodotdev#998) The underlying `fetch` handles AbortSignal naturally.
This file contains hidden or 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
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.
fixes #567
This pull request introduces support for the
AbortControllerAPI across all public methods in theLingoDotDevEngineSDK, enabling consumers to cancel long-running operations. It also includes extensive refactoring to propagateAbortSignalthroughout internal methods and batch operations, along with comprehensive unit tests to validate the new functionality.