hapijs / hoek

Node utilities shared among the extended hapi universe
Other
480 stars 171 forks source link

Stack overflow in clone in v6.2.3 #300

Closed dhalbrook closed 5 years ago

dhalbrook commented 5 years ago

When updating to 6.2.3, we're seeing the following stack overflow:

(node:28550) UnhandledPromiseRejectionWarning: RangeError: Maximum call stack size exceeded
    at Object.exports.clone (/Users/dolan.halbrook/development/plugins/angular-li/limuirs/node_modules/@hapi/hoek/lib/index.js:25:26)
    at Object.exports.clone (/Users/dolan.halbrook/development/plugins/angular-li/limuirs/node_modules/@hapi/hoek/lib/index.js:116:36)
    at Object.exports.clone (/Users/dolan.halbrook/development/plugins/angular-li/limuirs/node_modules/@hapi/hoek/lib/index.js:116:36)
    at Object.exports.clone (/Users/dolan.halbrook/development/plugins/angular-li/limuirs/node_modules/@hapi/hoek/lib/index.js:116:36)
    at Object.exports.clone (/Users/dolan.halbrook/development/plugins/angular-li/limuirs/node_modules/@hapi/hoek/lib/index.js:116:36)
    at Object.exports.clone (/Users/dolan.halbrook/development/plugins/angular-li/limuirs/node_modules/@hapi/hoek/lib/index.js:116:36)
    at Object.exports.clone (/Users/dolan.halbrook/development/plugins/angular-li/limuirs/node_modules/@hapi/hoek/lib/index.js:116:36)
    at Object.exports.clone (/Users/dolan.halbrook/development/plugins/angular-li/limuirs/node_modules/@hapi/hoek/lib/index.js:116:36)
    at Object.exports.clone (/Users/dolan.halbrook/development/plugins/angular-li/limuirs/node_modules/@hapi/hoek/lib/index.js:116:36)
    at Object.exports.clone (/Users/dolan.halbrook/development/plugins/angular-li/limuirs/node_modules/@hapi/hoek/lib/index.js:116:36)

Our hapi modules:

    "@hapi/boom": "^7.2.1",
    "@hapi/h2o2": "^8.1.1",
    "@hapi/hapi": "^18.1.0",
    "@hapi/inert": "^5.1.0",
    "@hapi/joi": "^15.0.2",

If I pin @hapi/hoek to 6.2.2 this issue doesn't happen, so it's possibly caused by the changeset that was merged in https://github.com/hapijs/hoek/commit/76a16ee3e3ce50ca6052f1808d63290ee8057ab9

dhalbrook commented 5 years ago

Thanks for the quick fix!

lock[bot] commented 4 years ago

This thread has been automatically locked due to inactivity. Please open a new issue for related bugs or questions following the new issue template instructions.