local-ai-stack icon indicating copy to clipboard operation
local-ai-stack copied to clipboard

More descriptive error

Open luandro opened this issue 2 years ago • 1 comments

Can't really tell where this error is coming from when running node src/scripts/indexBlogLocal.mjs. Is it failing to connect to supabase?

node:internal/deps/undici/undici:11576
    Error.captureStackTrace(err, this);
          ^

TypeError: fetch failed
    at Object.fetch (node:internal/deps/undici/undici:11576:11)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async getModelFile (file:////local-ai-stack/node_modules/@xenova/transformers/src/utils/hub.js:468:24)
    at async constructSession (file:////local-ai-stack/node_modules/@xenova/transformers/src/models.js:119:18)
    at async Promise.all (index 1)
    at async BertModel.from_pretrained (file:////local-ai-stack/node_modules/@xenova/transformers/src/models.js:713:20)
    at async AutoModel.from_pretrained (file:////local-ai-stack/node_modules/@xenova/transformers/src/models.js:3767:20)
    at async Promise.all (index 1)
    at async loadItems (file:////local-ai-stack/node_modules/@xenova/transformers/src/pipelines.js:2305:5)
    at async pipeline (file:////local-ai-stack/node_modules/@xenova/transformers/src/pipelines.js:2251:19) {
  cause: ConnectTimeoutError: Connect Timeout Error
      at onConnectTimeout (node:internal/deps/undici/undici:8522:28)
      at node:internal/deps/undici/undici:8480:50
      at Immediate._onImmediate (node:internal/deps/undici/undici:8511:13)
      at process.processImmediate (node:internal/timers:476:21) {
    code: 'UND_ERR_CONNECT_TIMEOUT'
  }
}

Node.js v18.17.0

luandro avatar Nov 02 '23 13:11 luandro

I got the same error and resolved it by updating the version of supabase library per the open merge request, and by running npm update (it is possible that npm update alone would have been enough, so maybe try that first.)

svemir avatar Nov 05 '23 16:11 svemir