You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Getting the error "Cannot call method "indexOf" of undefined" for any error. It apparently fails to execute err.stack.indexOf where err.stack is not set.
"Cannot call method "indexOf" of undefined": TypeError: Cannot call method "indexOf" of undefined at /node_modules/rds/node_modules/mysql/lib/protocol/sequences/Sequence.js:63 at /node_modules/rds/node_modules/mysql/lib/protocol/sequences/Sequence.js:78 at /node_modules/rds/node_modules/mysql/lib/protocol/sequences/Query.js:94 at /node_modules/rds/node_modules/mysql/lib/protocol/Protocol.js:274 at /node_modules/rds/node_modules/mysql/lib/protocol/Parser.js:77 at /node_modules/rds/node_modules/mysql/lib/protocol/Protocol.js:39 at write (_stream_readable.js:601) at flow (_stream_readable.js:610) at pipeOnReadable (_stream_r
When I printed the error packet:
{"fieldCount":255,"errno":1062,"sqlStateMarker":"#","sqlState":"23000","message":"Duplicate entry 'xxxxxx' for key 'xxxxxx'"}
The text was updated successfully, but these errors were encountered:
Hi! Unfortunately I don't seem to be able to reproduce. Is there a way you could put together a very simple file that, when I run it, produces the error above?
The issue seems to be because of different Javascript engine being used.
We are using rhino and that apparently does not seem to add 'stack' when you do 'new Error()'. It seems it is v8's feature. So in Sequence.js, in _addLongStackTrace() it fails on the following line, because err.stack is undefined:
if (err.stack.indexOf(delimiter) > -1) {
return;
}
Would it be possible to add a check whether err.stack exists?
Ah, I see. This library has various issues with Rhino in general, and only fully functions in Node.js (v8). Adding this would get you past this issue, but not others. Can you run our entire test suite in Rhino and validate what does and doesn't work before we make any effort to support Rhino?
Getting the error "Cannot call method "indexOf" of undefined" for any error. It apparently fails to execute
err.stack.indexOf
whereerr.stack
is not set.When I printed the error packet:
The text was updated successfully, but these errors were encountered: