Dd-trace-js: Error: ENOENT: no such file or directory, access 'internal/process/task_queues.js.map

Created on 14 Apr 2020  路  6Comments  路  Source: DataDog/dd-trace-js

We recently found this error in our datadog traces:

Error: ENOENT: no such file or directory, access 'internal/process/task_queues.js.map'
    at Object.accessSync (fs.js:195:3)
    at /usr/src/app/node_modules/dd-trace/packages/dd-trace/src/tracer.js:91:53
    at /usr/src/app/node_modules/dd-trace/packages/dd-trace/src/tracer.js:43:56
    at Scope._activate (/usr/src/app/node_modules/dd-trace/packages/dd-trace/src/scope/async_hooks.js:51:14)
    at Scope.activate (/usr/src/app/node_modules/dd-trace/packages/dd-trace/src/scope/base.js:12:19)
    at DatadogTracer.trace (/usr/src/app/node_modules/dd-trace/packages/dd-trace/src/tracer.js:43:35)
    at Object.accessSync (/usr/src/app/node_modules/dd-trace/packages/dd-trace/src/tracer.js:91:23)
    at isReadableFile (/usr/src/app/node_modules/get-stack-trace/src/isReadableFile.js:7:8)
    at resolveCallSiteSourceCodeLocation (/usr/src/app/node_modules/get-stack-trace/src/resolveCallSiteSourceCodeLocation.js:36:7)
    at /usr/src/app/node_modules/get-stack-trace/src/getStackTrace.js:40:18
    at tryCatcher (/usr/src/app/node_modules/bluebird/js/release/util.js:16:23)
    at MappingPromiseArray._promiseFulfilled (/usr/src/app/node_modules/bluebird/js/release/map.js:68:38)
    at MappingPromiseArray.PromiseArray._iterate (/usr/src/app/node_modules/bluebird/js/release/promise_array.js:115:31)
    at MappingPromiseArray.init (/usr/src/app/node_modules/bluebird/js/release/promise_array.js:79:10)
    at MappingPromiseArray._asyncInit (/usr/src/app/node_modules/bluebird/js/release/map.js:37:10)
    at _drainQueueStep (/usr/src/app/node_modules/bluebird/js/release/async.js:97:12)

it's been hard to find exact reproduction steps, but I can try getting more details on the sample maybe.
this is on a span created for the fs automatic instrumentation.

Environment
production

  • Operation system:
    alpine-node:12.13.1

  • Node version:
    v12.13.1

  • Tracer version:
    0.17.0

  • Agent version:
    0.17.0

bug community core

Most helpful comment

@pcothenet That file is definitely what originally put this on our radar, since it basically happens for anyone using aws-sdk.

I'll do a release by the end of the week with the fix.

All 6 comments

At a glance this looks like it could be an error from fs being used by a dependency (bluebird?). The tracer captures the error which is then handled by the library. It doesn't cause an actual exception since the library handled the error, but the tracer already captured the error at that point. This is a known issue and for now we have removed errors from the fs plugin completely to avoid confusion. This will be in the next version.

For the record, I'm seeing this for a different file as well: ENOENT: no such file or directory, open '/tmp/.aws/config'

@pcothenet That file is definitely what originally put this on our radar, since it basically happens for anyone using aws-sdk.

I'll do a release by the end of the week with the fix.

Released in 0.19.1.

thank you!! 馃憦

Update on this, I think this issue actually relates to https://github.com/gajus/get-stack-trace/issues/4 and will be solved with https://github.com/gajus/get-stack-trace/pull/5

Was this page helpful?
0 / 5 - 0 ratings

Related issues

vecerek picture vecerek  路  3Comments

pauldraper picture pauldraper  路  6Comments

icirellik picture icirellik  路  5Comments

shortcircuit3 picture shortcircuit3  路  6Comments

nickpresta picture nickpresta  路  5Comments