Describe the bug
Using batch.transcribe()
When a batch transcribe job is rejected because of Language identification could not identify any language with sufficient confidence, an error is thrown but it does not bubble up to caller
The following node warning is logged:
[UnhandledPromiseRejection: This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason "[object Array]".] {
code: 'ERR_UNHANDLED_REJECTION'
}
Steps to reproduce
Get an audio file with insufficient audio for auto-detect to return a language
Call batch.transcibe with the following:
Describe the bug Using
batch.transcribe()
When a batch transcribe job is rejected because ofLanguage identification could not identify any language with sufficient confidence
, an error is thrown but it does not bubble up to callerThe following node warning is logged:
Steps to reproduce Get an audio file with insufficient audio for auto-detect to return a language Call batch.transcibe with the following:
Expected behavior The caller of the
batch.transcribe
method should be able to catch the error in their catch block.Additional context SDK version 3.1.1 Node.js v18.18.0
Doesn't affect invalid audio files so is probably related to the code that polls for the job response