Bug Description
When trying to fetch a URL a fetch failed error is thrown with the code as
code: 'UND_ERR_CONNECT_TIMEOUT'
, This error is thrown at a request that barely takes 5 - 6 seconds to complete and other HTTP clients like axios and curl perform flawlessly on the same server
Reproducible By
Fetch any discord API url
Expected Behavior
The fetch should complete which is well below the 120s timeout
Logs & Screenshots
/home/arnav/Documents/tej.js/node_modules/undici/lib/fetch/index.js:197
Object.assign(new TypeError('fetch failed'), { cause: response.error })
^
TypeError: fetch failed
at Object.processResponse (/home/arnav/Documents/tej.js/node_modules/undici/lib/fetch/index.js:197:23)
at /home/arnav/Documents/tej.js/node_modules/undici/lib/fetch/index.js:930:38
at node:internal/process/task_queues:141:7
at AsyncResource.runInAsyncScope (node:async_hooks:201:9)
at AsyncResource.runMicrotask (node:internal/process/task_queues:138:8)
at processTicksAndRejections (node:internal/process/task_queues:96:5) {
cause: ConnectTimeoutError: Connect Timeout Error
at Timeout.onConnectTimeout [as _onTimeout] (/home/arnav/Documents/tej.js/node_modules/undici/lib/core/connect.js:108:24)
at listOnTimeout (node:internal/timers:561:11)
at processTimers (node:internal/timers:502:7) {
code: 'UND_ERR_CONNECT_TIMEOUT'
}
}
Environment
Gentoo, Node v17.6.0
Additional context
Happen on every discord API url and used to work some time back but suddenly just fails everywhere.
Bug Description
When trying to fetch a URL a
fetch failederror is thrown with the code ascode: 'UND_ERR_CONNECT_TIMEOUT'
, This error is thrown at a request that barely takes 5 - 6 seconds to complete and other HTTP clients like axios and curl perform flawlessly on the same server
Reproducible By
Fetch any discord API url
Expected Behavior
The fetch should complete which is well below the 120s timeout
Logs & Screenshots
Environment
Gentoo, Node v17.6.0
Additional context
Happen on every discord API url and used to work some time back but suddenly just fails everywhere.