Skip to content

Commit c8970f4

Browse files
committed
Change UNKNOWN_CODE_PLEASE_REPORT to identify uknown code
Changes UNKNOWN_CODE_PLEASE_REPORT to include packet.errno in it. This makes it easier to identify what the code is even if the code is not yet supported: ``` (node:1) UnhandledPromiseRejectionWarning: Error: UNKNOWN_CODE_PLEASE_REPORT: Query execution was interrupted, query_timeout exceeded ```
1 parent 3430c51 commit c8970f4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/protocol/sequences/Sequence.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ Sequence.prototype.hasErrorHandler = function() {
4343
};
4444

4545
Sequence.prototype._packetToError = function(packet) {
46-
var code = ErrorConstants[packet.errno] || 'UNKNOWN_CODE_PLEASE_REPORT';
46+
var code = ErrorConstants[packet.errno] || 'UNKNOWN_CODE_PLEASE_REPORT: ' + packet.errno;
4747
var err = new Error(code + ': ' + packet.message);
4848
err.code = code;
4949
err.errno = packet.errno;

0 commit comments

Comments
 (0)