Skip to content

Connect Timeout Error when parsing NMR data from URL #137

Description

@NishaSharma14

Describe the bug
The /spectra/parse/url API endpoint fails with a Connect Timeout Error when attempting to fetch and parse NMR data from a URL.

To Reproduce
Steps to reproduce the behavior:

  1. Make a POST request to /spectra/parse/url
  2. Use the following request body:
{
  "auto_detection": true,
  "auto_processing": true,
  "capture_snapshot": true,
  "url": "https://s3.uni-jena.de/nmrxiv/production/archive/1368b8fd-3af7-48f7-8b6d-13de9c1ecf8b/492-62-6.zip"
}
  1. Observe the error response

Error Details
The API returns a detailed error message:

NMR CLI error: node:internal/deps/undici/undici:14902
      Error.captureStackTrace(err);
            ^

TypeError: fetch failed
    at node:internal/deps/undici/undici:14902:13
    at process.processTicksAndRejections (node:internal/process/task_queues:105:5)
    at async Object.arrayBuffer (file:///app/node_modules/file-collection/lib/append/sourceItemToExtendedSourceItem.js:35:26)
    at async fileItemUnzip (file:///app/node_modules/file-collection/lib/utilities/expand/fileItemUnzip.js:26:20)
    at async expandAndFilter (file:///app/node_modules/file-collection/lib/utilities/expand/expandAndFilter.js:17:23)
    at async FileCollection.appendExtendedSource (file:///app/node_modules/file-collection/lib/FileCollection.js:62:23)
    at async Promise.all (index 0)
    at async appendSource (file:///app/node_modules/file-collection/lib/append/appendSource.js:23:5)
    at async FileCollection.appendSource (file:///app/node_modules/file-collection/lib/FileCollection.js:133:9)
    at async FileCollection.fromSource (file:///app/node_modules/file-collection/lib/FileCollection.js:229:9)

Root Cause:

ConnectTimeoutError: Connect Timeout Error (attempted address: s3.uni-jena.de:443, timeout: 10000ms)
    at onConnectTimeout (node:internal/deps/undici/undici:2718:28)
    at Immediate._onImmediate (node:internal/deps/undici/undici:2699:11)
    at process.processImmediate (node:internal/timers:485:21)

Metadata

Metadata

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions