mirror of
https://github.com/microsoft/vscode.git
synced 2026-08-27 21:09:31 +01:00
* fix: handle 422 embeddings errors gracefully instead of throwing (fixes #318009) The remote embeddings endpoint can return 422 when the request payload is rejected (e.g. model unavailability, input validation failure). The error was already being logged to telemetry, but then re-thrown as an unhandled error that propagated to crash telemetry as a duplicate entry. Now, after logging the telemetry event, we log a warning and return partial results instead of throwing. This matches the existing pattern for other non-critical failures (no auth session, no-auth user) where empty embeddings are returned gracefully. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * fix: prevent delayed embeddings rejection from going unhandled Observe the predicted-tools promise as soon as it is created while preserving the existing later error handling and RemoteEmbeddingsComputer throwing semantics. Add regression coverage for rejection during concurrent grouping work. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --------- Co-authored-by: vs-code-engineering[bot] <122617954+vs-code-engineering[bot]@users.noreply.github.com> Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Co-authored-by: Dmitriy Vasyura <dmitriv@microsoft.com>