OpenAI Whisper Error is Considered Successful

I am using the OpenAI > Transcribe Audio step, which returns an error. But the outcome is still considered successful, and the whole flow continues, but I think it shouldn’t. I am pasting my input and output below. Note that the output contains the bearer token, which may be censored as done in the input (I’ve censored it below myself).

Input

{
  "auth": "**CENSORED**",
  "audio": "file://step_1/1D9HtVdLnNMN311L1RoDnEvD-uvrT-Y6j.caf",
  "language": "en"
}

Output

{
  "_requestBody": {
    "_overheadLength": 391,
    "_valueLength": 1501285,
    "_valuesToMeasure": [],
    "writable": false,
    "readable": true,
    "dataSize": 0,
    "maxDataSize": 2097152,
    "pauseStreams": true,
    "_released": true,
    "_streams": [],
    "_currentStream": null,
    "_insideLoop": false,
    "_pendingNext": false,
    "_boundary": "--------------------------729484399270751121097038",
    "_events": {},
    "_eventsCount": 3
  },
  "_err": {
    "message": "Request failed with status code 400",
    "name": "AxiosError",
    "stack": "AxiosError: Request failed with status code 400\n    at settle (/usr/src/app/dist/cache/sandbox/FLOW-flowVersionId-9KA3gK5FFpv8h0g2IBHM5/node_modules/.pnpm/axios@1.4.0/node_modules/axios/lib/core/settle.js:19:12)\n    at IncomingMessage.handleStreamEnd (/usr/src/app/dist/cache/sandbox/FLOW-flowVersionId-9KA3gK5FFpv8h0g2IBHM5/node_modules/.pnpm/axios@1.4.0/node_modules/axios/lib/adapters/http.js:570:11)\n    at IncomingMessage.emit (node:events:526:35)\n    at endReadableNT (node:internal/streams/readable:1359:12)\n    at process.processTicksAndRejections (node:internal/process/task_queues:82:21)",
    "config": {
      "transitional": {
        "silentJSONParsing": true,
        "forcedJSONParsing": true,
        "clarifyTimeoutError": false
      },
      "adapter": ["xhr", "http"],
      "transformRequest": [null],
      "transformResponse": [null],
      "timeout": 0,
      "xsrfCookieName": "XSRF-TOKEN",
      "xsrfHeaderName": "X-XSRF-TOKEN",
      "maxContentLength": -1,
      "maxBodyLength": -1,
      "env": {},
      "headers": {
        "Accept": "application/json",
        "Content-Type": "multipart/form-data; boundary=--------------------------729484399270751121097038",
        "Authorization": "**CENSORED**",
        "User-Agent": "axios/1.4.0",
        "Content-Length": "1501732",
        "Accept-Encoding": "gzip, compress, deflate, br"
      },
      "method": "post",
      "url": "https://api.openai.com/v1/audio/transcriptions",
      "data": {
        "_overheadLength": 391,
        "_valueLength": 1501285,
        "_valuesToMeasure": [],
        "writable": false,
        "readable": true,
        "dataSize": 0,
        "maxDataSize": 2097152,
        "pauseStreams": true,
        "_released": true,
        "_streams": [],
        "_currentStream": null,
        "_insideLoop": false,
        "_pendingNext": false,
        "_boundary": "--------------------------729484399270751121097038",
        "_events": {},
        "_eventsCount": 3
      }
    },
    "code": "ERR_BAD_REQUEST",
    "status": 400
  }
}

Hi @axgr

Yes you are correct, but something I am not sure if it’s clear, is the expected behavior in this case to fail? if not can you please tell us how to reproduce it? does it happen with certain audio files?

The expected behavior is that the step succeeds with the input file I have read during the previous step. It is a M4A with 1.7 MB in size, so there shouldn’t be any issues. I did what I had described above: delete the file and upload it again, and this time, the whole flow worked without any issues.

I am not sure why that is, but I am happy to help in debugging this.

Hello @axgr, please check remove your step and add it again and test now, you should have it failing with the correct error message.

Thanks! I run a self-hosted instance. Is there a new Docker image available?

@axgr pieces are loaded directly from npmjs.com , It should be automtically upgraded.

Cool, didn’t know that, thanks!

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.