1<!DOCTYPE html> 2<html lang="en"> 3<head> 4 <meta charset="utf-8"> 5 <meta name="viewport" content="width=device-width"> 6 <meta name="nodejs.org:node-version" content="v18.18.2"> 7 <title>Errors | Node.js v18.18.2 Documentation</title> 8 <link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Lato:400,700,400italic&display=fallback"> 9 <link rel="stylesheet" href="assets/style.css"> 10 <link rel="stylesheet" href="assets/hljs.css"> 11 <link rel="canonical" href="https://nodejs.org/api/errors.html"> 12 <script async defer src="assets/api.js" type="text/javascript"></script> 13 14</head> 15<body class="alt apidoc" id="api-section-errors"> 16 <div id="content" class="clearfix"> 17 <div id="column2" class="interior"> 18 <div id="intro" class="interior"> 19 <a href="/" title="Go back to the home page"> 20 Node.js 21 </a> 22 </div> 23 <ul> 24<li><a href="documentation.html" class="nav-documentation">About this documentation</a></li> 25<li><a href="synopsis.html" class="nav-synopsis">Usage and example</a></li> 26</ul> 27<hr class="line"> 28<ul> 29<li><a href="assert.html" class="nav-assert">Assertion testing</a></li> 30<li><a href="async_context.html" class="nav-async_context">Asynchronous context tracking</a></li> 31<li><a href="async_hooks.html" class="nav-async_hooks">Async hooks</a></li> 32<li><a href="buffer.html" class="nav-buffer">Buffer</a></li> 33<li><a href="addons.html" class="nav-addons">C++ addons</a></li> 34<li><a href="n-api.html" class="nav-n-api">C/C++ addons with Node-API</a></li> 35<li><a href="embedding.html" class="nav-embedding">C++ embedder API</a></li> 36<li><a href="child_process.html" class="nav-child_process">Child processes</a></li> 37<li><a href="cluster.html" class="nav-cluster">Cluster</a></li> 38<li><a href="cli.html" class="nav-cli">Command-line options</a></li> 39<li><a href="console.html" class="nav-console">Console</a></li> 40<li><a href="corepack.html" class="nav-corepack">Corepack</a></li> 41<li><a href="crypto.html" class="nav-crypto">Crypto</a></li> 42<li><a href="debugger.html" class="nav-debugger">Debugger</a></li> 43<li><a href="deprecations.html" class="nav-deprecations">Deprecated APIs</a></li> 44<li><a href="diagnostics_channel.html" class="nav-diagnostics_channel">Diagnostics Channel</a></li> 45<li><a href="dns.html" class="nav-dns">DNS</a></li> 46<li><a href="domain.html" class="nav-domain">Domain</a></li> 47<li><a href="errors.html" class="nav-errors active">Errors</a></li> 48<li><a href="events.html" class="nav-events">Events</a></li> 49<li><a href="fs.html" class="nav-fs">File system</a></li> 50<li><a href="globals.html" class="nav-globals">Globals</a></li> 51<li><a href="http.html" class="nav-http">HTTP</a></li> 52<li><a href="http2.html" class="nav-http2">HTTP/2</a></li> 53<li><a href="https.html" class="nav-https">HTTPS</a></li> 54<li><a href="inspector.html" class="nav-inspector">Inspector</a></li> 55<li><a href="intl.html" class="nav-intl">Internationalization</a></li> 56<li><a href="modules.html" class="nav-modules">Modules: CommonJS modules</a></li> 57<li><a href="esm.html" class="nav-esm">Modules: ECMAScript modules</a></li> 58<li><a href="module.html" class="nav-module">Modules: <code>node:module</code> API</a></li> 59<li><a href="packages.html" class="nav-packages">Modules: Packages</a></li> 60<li><a href="net.html" class="nav-net">Net</a></li> 61<li><a href="os.html" class="nav-os">OS</a></li> 62<li><a href="path.html" class="nav-path">Path</a></li> 63<li><a href="perf_hooks.html" class="nav-perf_hooks">Performance hooks</a></li> 64<li><a href="permissions.html" class="nav-permissions">Permissions</a></li> 65<li><a href="process.html" class="nav-process">Process</a></li> 66<li><a href="punycode.html" class="nav-punycode">Punycode</a></li> 67<li><a href="querystring.html" class="nav-querystring">Query strings</a></li> 68<li><a href="readline.html" class="nav-readline">Readline</a></li> 69<li><a href="repl.html" class="nav-repl">REPL</a></li> 70<li><a href="report.html" class="nav-report">Report</a></li> 71<li><a href="single-executable-applications.html" class="nav-single-executable-applications">Single executable applications</a></li> 72<li><a href="stream.html" class="nav-stream">Stream</a></li> 73<li><a href="string_decoder.html" class="nav-string_decoder">String decoder</a></li> 74<li><a href="test.html" class="nav-test">Test runner</a></li> 75<li><a href="timers.html" class="nav-timers">Timers</a></li> 76<li><a href="tls.html" class="nav-tls">TLS/SSL</a></li> 77<li><a href="tracing.html" class="nav-tracing">Trace events</a></li> 78<li><a href="tty.html" class="nav-tty">TTY</a></li> 79<li><a href="dgram.html" class="nav-dgram">UDP/datagram</a></li> 80<li><a href="url.html" class="nav-url">URL</a></li> 81<li><a href="util.html" class="nav-util">Utilities</a></li> 82<li><a href="v8.html" class="nav-v8">V8</a></li> 83<li><a href="vm.html" class="nav-vm">VM</a></li> 84<li><a href="wasi.html" class="nav-wasi">WASI</a></li> 85<li><a href="webcrypto.html" class="nav-webcrypto">Web Crypto API</a></li> 86<li><a href="webstreams.html" class="nav-webstreams">Web Streams API</a></li> 87<li><a href="worker_threads.html" class="nav-worker_threads">Worker threads</a></li> 88<li><a href="zlib.html" class="nav-zlib">Zlib</a></li> 89</ul> 90<hr class="line"> 91<ul> 92<li><a href="https://github.com/nodejs/node" class="nav-https-github-com-nodejs-node">Code repository and issue tracker</a></li> 93</ul> 94 </div> 95 96 <div id="column1" data-id="errors" class="interior"> 97 <header class="header"> 98 <div class="header-container"> 99 <h1>Node.js v18.18.2 documentation</h1> 100 <button class="theme-toggle-btn" id="theme-toggle-btn" title="Toggle dark mode/light mode" aria-label="Toggle dark mode/light mode" hidden> 101 <svg xmlns="http://www.w3.org/2000/svg" class="icon dark-icon" height="24" width="24"> 102 <path fill="none" d="M0 0h24v24H0z" /> 103 <path d="M11.1 12.08c-2.33-4.51-.5-8.48.53-10.07C6.27 2.2 1.98 6.59 1.98 12c0 .14.02.28.02.42.62-.27 1.29-.42 2-.42 1.66 0 3.18.83 4.1 2.15A4.01 4.01 0 0111 18c0 1.52-.87 2.83-2.12 3.51.98.32 2.03.5 3.11.5 3.5 0 6.58-1.8 8.37-4.52-2.36.23-6.98-.97-9.26-5.41z"/> 104 <path d="M7 16h-.18C6.4 14.84 5.3 14 4 14c-1.66 0-3 1.34-3 3s1.34 3 3 3h3c1.1 0 2-.9 2-2s-.9-2-2-2z"/> 105 </svg> 106 <svg xmlns="http://www.w3.org/2000/svg" class="icon light-icon" height="24" width="24"> 107 <path d="M0 0h24v24H0z" fill="none" /> 108 <path d="M6.76 4.84l-1.8-1.79-1.41 1.41 1.79 1.79 1.42-1.41zM4 10.5H1v2h3v-2zm9-9.95h-2V3.5h2V.55zm7.45 3.91l-1.41-1.41-1.79 1.79 1.41 1.41 1.79-1.79zm-3.21 13.7l1.79 1.8 1.41-1.41-1.8-1.79-1.4 1.4zM20 10.5v2h3v-2h-3zm-8-5c-3.31 0-6 2.69-6 6s2.69 6 6 6 6-2.69 6-6-2.69-6-6-6zm-1 16.95h2V19.5h-2v2.95zm-7.45-3.91l1.41 1.41 1.79-1.8-1.41-1.41-1.79 1.8z"/> 109 </svg> 110 </button> 111 </div> 112 <div id="gtoc"> 113 <ul> 114 <li class="pinned-header">Node.js v18.18.2</li> 115 116 <li class="picker-header"> 117 <a href="#"> 118 <span class="collapsed-arrow">►</span><span class="expanded-arrow">▼</span> 119 Table of contents 120 </a> 121 122 <div class="picker"><div class="toc"><ul> 123<li><a href="#errors">Errors</a> 124<ul> 125<li><a href="#error-propagation-and-interception">Error propagation and interception</a></li> 126<li><a href="#class-error">Class: <code>Error</code></a> 127<ul> 128<li><a href="#new-errormessage-options"><code>new Error(message[, options])</code></a></li> 129<li><a href="#errorcapturestacktracetargetobject-constructoropt"><code>Error.captureStackTrace(targetObject[, constructorOpt])</code></a></li> 130<li><a href="#errorstacktracelimit"><code>Error.stackTraceLimit</code></a></li> 131<li><a href="#errorcause"><code>error.cause</code></a></li> 132<li><a href="#errorcode"><code>error.code</code></a></li> 133<li><a href="#errormessage"><code>error.message</code></a></li> 134<li><a href="#errorstack"><code>error.stack</code></a></li> 135</ul> 136</li> 137<li><a href="#class-assertionerror">Class: <code>AssertionError</code></a></li> 138<li><a href="#class-rangeerror">Class: <code>RangeError</code></a></li> 139<li><a href="#class-referenceerror">Class: <code>ReferenceError</code></a></li> 140<li><a href="#class-syntaxerror">Class: <code>SyntaxError</code></a></li> 141<li><a href="#class-systemerror">Class: <code>SystemError</code></a> 142<ul> 143<li><a href="#erroraddress"><code>error.address</code></a></li> 144<li><a href="#errorcode_1"><code>error.code</code></a></li> 145<li><a href="#errordest"><code>error.dest</code></a></li> 146<li><a href="#errorerrno"><code>error.errno</code></a></li> 147<li><a href="#errorinfo"><code>error.info</code></a></li> 148<li><a href="#errormessage_1"><code>error.message</code></a></li> 149<li><a href="#errorpath"><code>error.path</code></a></li> 150<li><a href="#errorport"><code>error.port</code></a></li> 151<li><a href="#errorsyscall"><code>error.syscall</code></a></li> 152<li><a href="#common-system-errors">Common system errors</a></li> 153</ul> 154</li> 155<li><a href="#class-typeerror">Class: <code>TypeError</code></a></li> 156<li><a href="#exceptions-vs-errors">Exceptions vs. errors</a></li> 157<li><a href="#openssl-errors">OpenSSL errors</a> 158<ul> 159<li><a href="#erroropensslerrorstack"><code>error.opensslErrorStack</code></a></li> 160<li><a href="#errorfunction"><code>error.function</code></a></li> 161<li><a href="#errorlibrary"><code>error.library</code></a></li> 162<li><a href="#errorreason"><code>error.reason</code></a></li> 163</ul> 164</li> 165<li><a href="#nodejs-error-codes">Node.js error codes</a> 166<ul> 167<li><a href="#abort_err"><code>ABORT_ERR</code></a></li> 168<li><a href="#err_access_denied"><code>ERR_ACCESS_DENIED</code></a></li> 169<li><a href="#err_ambiguous_argument"><code>ERR_AMBIGUOUS_ARGUMENT</code></a></li> 170<li><a href="#err_arg_not_iterable"><code>ERR_ARG_NOT_ITERABLE</code></a></li> 171<li><a href="#err_assertion"><code>ERR_ASSERTION</code></a></li> 172<li><a href="#err_async_callback"><code>ERR_ASYNC_CALLBACK</code></a></li> 173<li><a href="#err_async_type"><code>ERR_ASYNC_TYPE</code></a></li> 174<li><a href="#err_brotli_compression_failed"><code>ERR_BROTLI_COMPRESSION_FAILED</code></a></li> 175<li><a href="#err_brotli_invalid_param"><code>ERR_BROTLI_INVALID_PARAM</code></a></li> 176<li><a href="#err_buffer_context_not_available"><code>ERR_BUFFER_CONTEXT_NOT_AVAILABLE</code></a></li> 177<li><a href="#err_buffer_out_of_bounds"><code>ERR_BUFFER_OUT_OF_BOUNDS</code></a></li> 178<li><a href="#err_buffer_too_large"><code>ERR_BUFFER_TOO_LARGE</code></a></li> 179<li><a href="#err_cannot_watch_sigint"><code>ERR_CANNOT_WATCH_SIGINT</code></a></li> 180<li><a href="#err_child_closed_before_reply"><code>ERR_CHILD_CLOSED_BEFORE_REPLY</code></a></li> 181<li><a href="#err_child_process_ipc_required"><code>ERR_CHILD_PROCESS_IPC_REQUIRED</code></a></li> 182<li><a href="#err_child_process_stdio_maxbuffer"><code>ERR_CHILD_PROCESS_STDIO_MAXBUFFER</code></a></li> 183<li><a href="#err_closed_message_port"><code>ERR_CLOSED_MESSAGE_PORT</code></a></li> 184<li><a href="#err_console_writable_stream"><code>ERR_CONSOLE_WRITABLE_STREAM</code></a></li> 185<li><a href="#err_construct_call_invalid"><code>ERR_CONSTRUCT_CALL_INVALID</code></a></li> 186<li><a href="#err_construct_call_required"><code>ERR_CONSTRUCT_CALL_REQUIRED</code></a></li> 187<li><a href="#err_context_not_initialized"><code>ERR_CONTEXT_NOT_INITIALIZED</code></a></li> 188<li><a href="#err_crypto_custom_engine_not_supported"><code>ERR_CRYPTO_CUSTOM_ENGINE_NOT_SUPPORTED</code></a></li> 189<li><a href="#err_crypto_ecdh_invalid_format"><code>ERR_CRYPTO_ECDH_INVALID_FORMAT</code></a></li> 190<li><a href="#err_crypto_ecdh_invalid_public_key"><code>ERR_CRYPTO_ECDH_INVALID_PUBLIC_KEY</code></a></li> 191<li><a href="#err_crypto_engine_unknown"><code>ERR_CRYPTO_ENGINE_UNKNOWN</code></a></li> 192<li><a href="#err_crypto_fips_forced"><code>ERR_CRYPTO_FIPS_FORCED</code></a></li> 193<li><a href="#err_crypto_fips_unavailable"><code>ERR_CRYPTO_FIPS_UNAVAILABLE</code></a></li> 194<li><a href="#err_crypto_hash_finalized"><code>ERR_CRYPTO_HASH_FINALIZED</code></a></li> 195<li><a href="#err_crypto_hash_update_failed"><code>ERR_CRYPTO_HASH_UPDATE_FAILED</code></a></li> 196<li><a href="#err_crypto_incompatible_key"><code>ERR_CRYPTO_INCOMPATIBLE_KEY</code></a></li> 197<li><a href="#err_crypto_incompatible_key_options"><code>ERR_CRYPTO_INCOMPATIBLE_KEY_OPTIONS</code></a></li> 198<li><a href="#err_crypto_initialization_failed"><code>ERR_CRYPTO_INITIALIZATION_FAILED</code></a></li> 199<li><a href="#err_crypto_invalid_auth_tag"><code>ERR_CRYPTO_INVALID_AUTH_TAG</code></a></li> 200<li><a href="#err_crypto_invalid_counter"><code>ERR_CRYPTO_INVALID_COUNTER</code></a></li> 201<li><a href="#err_crypto_invalid_curve"><code>ERR_CRYPTO_INVALID_CURVE</code></a></li> 202<li><a href="#err_crypto_invalid_digest"><code>ERR_CRYPTO_INVALID_DIGEST</code></a></li> 203<li><a href="#err_crypto_invalid_iv"><code>ERR_CRYPTO_INVALID_IV</code></a></li> 204<li><a href="#err_crypto_invalid_jwk"><code>ERR_CRYPTO_INVALID_JWK</code></a></li> 205<li><a href="#err_crypto_invalid_key_object_type"><code>ERR_CRYPTO_INVALID_KEY_OBJECT_TYPE</code></a></li> 206<li><a href="#err_crypto_invalid_keylen"><code>ERR_CRYPTO_INVALID_KEYLEN</code></a></li> 207<li><a href="#err_crypto_invalid_keypair"><code>ERR_CRYPTO_INVALID_KEYPAIR</code></a></li> 208<li><a href="#err_crypto_invalid_keytype"><code>ERR_CRYPTO_INVALID_KEYTYPE</code></a></li> 209<li><a href="#err_crypto_invalid_messagelen"><code>ERR_CRYPTO_INVALID_MESSAGELEN</code></a></li> 210<li><a href="#err_crypto_invalid_scrypt_params"><code>ERR_CRYPTO_INVALID_SCRYPT_PARAMS</code></a></li> 211<li><a href="#err_crypto_invalid_state"><code>ERR_CRYPTO_INVALID_STATE</code></a></li> 212<li><a href="#err_crypto_invalid_tag_length"><code>ERR_CRYPTO_INVALID_TAG_LENGTH</code></a></li> 213<li><a href="#err_crypto_job_init_failed"><code>ERR_CRYPTO_JOB_INIT_FAILED</code></a></li> 214<li><a href="#err_crypto_jwk_unsupported_curve"><code>ERR_CRYPTO_JWK_UNSUPPORTED_CURVE</code></a></li> 215<li><a href="#err_crypto_jwk_unsupported_key_type"><code>ERR_CRYPTO_JWK_UNSUPPORTED_KEY_TYPE</code></a></li> 216<li><a href="#err_crypto_operation_failed"><code>ERR_CRYPTO_OPERATION_FAILED</code></a></li> 217<li><a href="#err_crypto_pbkdf2_error"><code>ERR_CRYPTO_PBKDF2_ERROR</code></a></li> 218<li><a href="#err_crypto_scrypt_invalid_parameter"><code>ERR_CRYPTO_SCRYPT_INVALID_PARAMETER</code></a></li> 219<li><a href="#err_crypto_scrypt_not_supported"><code>ERR_CRYPTO_SCRYPT_NOT_SUPPORTED</code></a></li> 220<li><a href="#err_crypto_sign_key_required"><code>ERR_CRYPTO_SIGN_KEY_REQUIRED</code></a></li> 221<li><a href="#err_crypto_timing_safe_equal_length"><code>ERR_CRYPTO_TIMING_SAFE_EQUAL_LENGTH</code></a></li> 222<li><a href="#err_crypto_unknown_cipher"><code>ERR_CRYPTO_UNKNOWN_CIPHER</code></a></li> 223<li><a href="#err_crypto_unknown_dh_group"><code>ERR_CRYPTO_UNKNOWN_DH_GROUP</code></a></li> 224<li><a href="#err_crypto_unsupported_operation"><code>ERR_CRYPTO_UNSUPPORTED_OPERATION</code></a></li> 225<li><a href="#err_debugger_error"><code>ERR_DEBUGGER_ERROR</code></a></li> 226<li><a href="#err_debugger_startup_error"><code>ERR_DEBUGGER_STARTUP_ERROR</code></a></li> 227<li><a href="#err_dlopen_disabled"><code>ERR_DLOPEN_DISABLED</code></a></li> 228<li><a href="#err_dlopen_failed"><code>ERR_DLOPEN_FAILED</code></a></li> 229<li><a href="#err_dir_closed"><code>ERR_DIR_CLOSED</code></a></li> 230<li><a href="#err_dir_concurrent_operation"><code>ERR_DIR_CONCURRENT_OPERATION</code></a></li> 231<li><a href="#err_dns_set_servers_failed"><code>ERR_DNS_SET_SERVERS_FAILED</code></a></li> 232<li><a href="#err_domain_callback_not_available"><code>ERR_DOMAIN_CALLBACK_NOT_AVAILABLE</code></a></li> 233<li><a href="#err_domain_cannot_set_uncaught_exception_capture"><code>ERR_DOMAIN_CANNOT_SET_UNCAUGHT_EXCEPTION_CAPTURE</code></a></li> 234<li><a href="#err_duplicate_startup_snapshot_main_function"><code>ERR_DUPLICATE_STARTUP_SNAPSHOT_MAIN_FUNCTION</code></a></li> 235<li><a href="#err_encoding_invalid_encoded_data"><code>ERR_ENCODING_INVALID_ENCODED_DATA</code></a></li> 236<li><a href="#err_encoding_not_supported"><code>ERR_ENCODING_NOT_SUPPORTED</code></a></li> 237<li><a href="#err_eval_esm_cannot_print"><code>ERR_EVAL_ESM_CANNOT_PRINT</code></a></li> 238<li><a href="#err_event_recursion"><code>ERR_EVENT_RECURSION</code></a></li> 239<li><a href="#err_execution_environment_not_available"><code>ERR_EXECUTION_ENVIRONMENT_NOT_AVAILABLE</code></a></li> 240<li><a href="#err_falsy_value_rejection"><code>ERR_FALSY_VALUE_REJECTION</code></a></li> 241<li><a href="#err_feature_unavailable_on_platform"><code>ERR_FEATURE_UNAVAILABLE_ON_PLATFORM</code></a></li> 242<li><a href="#err_fs_cp_dir_to_non_dir"><code>ERR_FS_CP_DIR_TO_NON_DIR</code></a></li> 243<li><a href="#err_fs_cp_eexist"><code>ERR_FS_CP_EEXIST</code></a></li> 244<li><a href="#err_fs_cp_einval"><code>ERR_FS_CP_EINVAL</code></a></li> 245<li><a href="#err_http_body_not_allowed"><code>ERR_HTTP_BODY_NOT_ALLOWED</code></a></li> 246<li><a href="#err_http_content_length_mismatch"><code>ERR_HTTP_CONTENT_LENGTH_MISMATCH</code></a></li> 247<li><a href="#err_fs_cp_fifo_pipe"><code>ERR_FS_CP_FIFO_PIPE</code></a></li> 248<li><a href="#err_fs_cp_non_dir_to_dir"><code>ERR_FS_CP_NON_DIR_TO_DIR</code></a></li> 249<li><a href="#err_fs_cp_socket"><code>ERR_FS_CP_SOCKET</code></a></li> 250<li><a href="#err_fs_cp_symlink_to_subdirectory"><code>ERR_FS_CP_SYMLINK_TO_SUBDIRECTORY</code></a></li> 251<li><a href="#err_fs_cp_unknown"><code>ERR_FS_CP_UNKNOWN</code></a></li> 252<li><a href="#err_fs_eisdir"><code>ERR_FS_EISDIR</code></a></li> 253<li><a href="#err_fs_file_too_large"><code>ERR_FS_FILE_TOO_LARGE</code></a></li> 254<li><a href="#err_fs_invalid_symlink_type"><code>ERR_FS_INVALID_SYMLINK_TYPE</code></a></li> 255<li><a href="#err_http_headers_sent"><code>ERR_HTTP_HEADERS_SENT</code></a></li> 256<li><a href="#err_http_invalid_header_value"><code>ERR_HTTP_INVALID_HEADER_VALUE</code></a></li> 257<li><a href="#err_http_invalid_status_code"><code>ERR_HTTP_INVALID_STATUS_CODE</code></a></li> 258<li><a href="#err_http_request_timeout"><code>ERR_HTTP_REQUEST_TIMEOUT</code></a></li> 259<li><a href="#err_http_socket_assigned"><code>ERR_HTTP_SOCKET_ASSIGNED</code></a></li> 260<li><a href="#err_http_socket_encoding"><code>ERR_HTTP_SOCKET_ENCODING</code></a></li> 261<li><a href="#err_http_trailer_invalid"><code>ERR_HTTP_TRAILER_INVALID</code></a></li> 262<li><a href="#err_http2_altsvc_invalid_origin"><code>ERR_HTTP2_ALTSVC_INVALID_ORIGIN</code></a></li> 263<li><a href="#err_http2_altsvc_length"><code>ERR_HTTP2_ALTSVC_LENGTH</code></a></li> 264<li><a href="#err_http2_connect_authority"><code>ERR_HTTP2_CONNECT_AUTHORITY</code></a></li> 265<li><a href="#err_http2_connect_path"><code>ERR_HTTP2_CONNECT_PATH</code></a></li> 266<li><a href="#err_http2_connect_scheme"><code>ERR_HTTP2_CONNECT_SCHEME</code></a></li> 267<li><a href="#err_http2_error"><code>ERR_HTTP2_ERROR</code></a></li> 268<li><a href="#err_http2_goaway_session"><code>ERR_HTTP2_GOAWAY_SESSION</code></a></li> 269<li><a href="#err_http2_header_single_value"><code>ERR_HTTP2_HEADER_SINGLE_VALUE</code></a></li> 270<li><a href="#err_http2_headers_after_respond"><code>ERR_HTTP2_HEADERS_AFTER_RESPOND</code></a></li> 271<li><a href="#err_http2_headers_sent"><code>ERR_HTTP2_HEADERS_SENT</code></a></li> 272<li><a href="#err_http2_info_status_not_allowed"><code>ERR_HTTP2_INFO_STATUS_NOT_ALLOWED</code></a></li> 273<li><a href="#err_http2_invalid_connection_headers"><code>ERR_HTTP2_INVALID_CONNECTION_HEADERS</code></a></li> 274<li><a href="#err_http2_invalid_header_value"><code>ERR_HTTP2_INVALID_HEADER_VALUE</code></a></li> 275<li><a href="#err_http2_invalid_info_status"><code>ERR_HTTP2_INVALID_INFO_STATUS</code></a></li> 276<li><a href="#err_http2_invalid_origin"><code>ERR_HTTP2_INVALID_ORIGIN</code></a></li> 277<li><a href="#err_http2_invalid_packed_settings_length"><code>ERR_HTTP2_INVALID_PACKED_SETTINGS_LENGTH</code></a></li> 278<li><a href="#err_http2_invalid_pseudoheader"><code>ERR_HTTP2_INVALID_PSEUDOHEADER</code></a></li> 279<li><a href="#err_http2_invalid_session"><code>ERR_HTTP2_INVALID_SESSION</code></a></li> 280<li><a href="#err_http2_invalid_setting_value"><code>ERR_HTTP2_INVALID_SETTING_VALUE</code></a></li> 281<li><a href="#err_http2_invalid_stream"><code>ERR_HTTP2_INVALID_STREAM</code></a></li> 282<li><a href="#err_http2_max_pending_settings_ack"><code>ERR_HTTP2_MAX_PENDING_SETTINGS_ACK</code></a></li> 283<li><a href="#err_http2_nested_push"><code>ERR_HTTP2_NESTED_PUSH</code></a></li> 284<li><a href="#err_http2_no_mem"><code>ERR_HTTP2_NO_MEM</code></a></li> 285<li><a href="#err_http2_no_socket_manipulation"><code>ERR_HTTP2_NO_SOCKET_MANIPULATION</code></a></li> 286<li><a href="#err_http2_origin_length"><code>ERR_HTTP2_ORIGIN_LENGTH</code></a></li> 287<li><a href="#err_http2_out_of_streams"><code>ERR_HTTP2_OUT_OF_STREAMS</code></a></li> 288<li><a href="#err_http2_payload_forbidden"><code>ERR_HTTP2_PAYLOAD_FORBIDDEN</code></a></li> 289<li><a href="#err_http2_ping_cancel"><code>ERR_HTTP2_PING_CANCEL</code></a></li> 290<li><a href="#err_http2_ping_length"><code>ERR_HTTP2_PING_LENGTH</code></a></li> 291<li><a href="#err_http2_pseudoheader_not_allowed"><code>ERR_HTTP2_PSEUDOHEADER_NOT_ALLOWED</code></a></li> 292<li><a href="#err_http2_push_disabled"><code>ERR_HTTP2_PUSH_DISABLED</code></a></li> 293<li><a href="#err_http2_send_file"><code>ERR_HTTP2_SEND_FILE</code></a></li> 294<li><a href="#err_http2_send_file_noseek"><code>ERR_HTTP2_SEND_FILE_NOSEEK</code></a></li> 295<li><a href="#err_http2_session_error"><code>ERR_HTTP2_SESSION_ERROR</code></a></li> 296<li><a href="#err_http2_settings_cancel"><code>ERR_HTTP2_SETTINGS_CANCEL</code></a></li> 297<li><a href="#err_http2_socket_bound"><code>ERR_HTTP2_SOCKET_BOUND</code></a></li> 298<li><a href="#err_http2_socket_unbound"><code>ERR_HTTP2_SOCKET_UNBOUND</code></a></li> 299<li><a href="#err_http2_status_101"><code>ERR_HTTP2_STATUS_101</code></a></li> 300<li><a href="#err_http2_status_invalid"><code>ERR_HTTP2_STATUS_INVALID</code></a></li> 301<li><a href="#err_http2_stream_cancel"><code>ERR_HTTP2_STREAM_CANCEL</code></a></li> 302<li><a href="#err_http2_stream_error"><code>ERR_HTTP2_STREAM_ERROR</code></a></li> 303<li><a href="#err_http2_stream_self_dependency"><code>ERR_HTTP2_STREAM_SELF_DEPENDENCY</code></a></li> 304<li><a href="#err_http2_too_many_invalid_frames"><code>ERR_HTTP2_TOO_MANY_INVALID_FRAMES</code></a></li> 305<li><a href="#err_http2_trailers_already_sent"><code>ERR_HTTP2_TRAILERS_ALREADY_SENT</code></a></li> 306<li><a href="#err_http2_trailers_not_ready"><code>ERR_HTTP2_TRAILERS_NOT_READY</code></a></li> 307<li><a href="#err_http2_unsupported_protocol"><code>ERR_HTTP2_UNSUPPORTED_PROTOCOL</code></a></li> 308<li><a href="#err_illegal_constructor"><code>ERR_ILLEGAL_CONSTRUCTOR</code></a></li> 309<li><a href="#err_import_assertion_type_failed"><code>ERR_IMPORT_ASSERTION_TYPE_FAILED</code></a></li> 310<li><a href="#err_import_assertion_type_missing"><code>ERR_IMPORT_ASSERTION_TYPE_MISSING</code></a></li> 311<li><a href="#err_import_assertion_type_unsupported"><code>ERR_IMPORT_ASSERTION_TYPE_UNSUPPORTED</code></a></li> 312<li><a href="#err_incompatible_option_pair"><code>ERR_INCOMPATIBLE_OPTION_PAIR</code></a></li> 313<li><span class="stability_1"><a href="#err_input_type_not_allowed"><code>ERR_INPUT_TYPE_NOT_ALLOWED</code></a></span></li> 314<li><a href="#err_inspector_already_activated"><code>ERR_INSPECTOR_ALREADY_ACTIVATED</code></a></li> 315<li><a href="#err_inspector_already_connected"><code>ERR_INSPECTOR_ALREADY_CONNECTED</code></a></li> 316<li><a href="#err_inspector_closed"><code>ERR_INSPECTOR_CLOSED</code></a></li> 317<li><a href="#err_inspector_command"><code>ERR_INSPECTOR_COMMAND</code></a></li> 318<li><a href="#err_inspector_not_active"><code>ERR_INSPECTOR_NOT_ACTIVE</code></a></li> 319<li><a href="#err_inspector_not_available"><code>ERR_INSPECTOR_NOT_AVAILABLE</code></a></li> 320<li><a href="#err_inspector_not_connected"><code>ERR_INSPECTOR_NOT_CONNECTED</code></a></li> 321<li><a href="#err_inspector_not_worker"><code>ERR_INSPECTOR_NOT_WORKER</code></a></li> 322<li><a href="#err_internal_assertion"><code>ERR_INTERNAL_ASSERTION</code></a></li> 323<li><a href="#err_invalid_address_family"><code>ERR_INVALID_ADDRESS_FAMILY</code></a></li> 324<li><a href="#err_invalid_arg_type"><code>ERR_INVALID_ARG_TYPE</code></a></li> 325<li><a href="#err_invalid_arg_value"><code>ERR_INVALID_ARG_VALUE</code></a></li> 326<li><a href="#err_invalid_async_id"><code>ERR_INVALID_ASYNC_ID</code></a></li> 327<li><a href="#err_invalid_buffer_size"><code>ERR_INVALID_BUFFER_SIZE</code></a></li> 328<li><a href="#err_invalid_char"><code>ERR_INVALID_CHAR</code></a></li> 329<li><a href="#err_invalid_cursor_pos"><code>ERR_INVALID_CURSOR_POS</code></a></li> 330<li><a href="#err_invalid_fd"><code>ERR_INVALID_FD</code></a></li> 331<li><a href="#err_invalid_fd_type"><code>ERR_INVALID_FD_TYPE</code></a></li> 332<li><a href="#err_invalid_file_url_host"><code>ERR_INVALID_FILE_URL_HOST</code></a></li> 333<li><a href="#err_invalid_file_url_path"><code>ERR_INVALID_FILE_URL_PATH</code></a></li> 334<li><a href="#err_invalid_handle_type"><code>ERR_INVALID_HANDLE_TYPE</code></a></li> 335<li><a href="#err_invalid_http_token"><code>ERR_INVALID_HTTP_TOKEN</code></a></li> 336<li><a href="#err_invalid_ip_address"><code>ERR_INVALID_IP_ADDRESS</code></a></li> 337<li><a href="#err_invalid_mime_syntax"><code>ERR_INVALID_MIME_SYNTAX</code></a></li> 338<li><a href="#err_invalid_module"><code>ERR_INVALID_MODULE</code></a></li> 339<li><a href="#err_invalid_module_specifier"><code>ERR_INVALID_MODULE_SPECIFIER</code></a></li> 340<li><a href="#err_invalid_object_define_property"><code>ERR_INVALID_OBJECT_DEFINE_PROPERTY</code></a></li> 341<li><a href="#err_invalid_package_config"><code>ERR_INVALID_PACKAGE_CONFIG</code></a></li> 342<li><a href="#err_invalid_package_target"><code>ERR_INVALID_PACKAGE_TARGET</code></a></li> 343<li><a href="#err_invalid_performance_mark"><code>ERR_INVALID_PERFORMANCE_MARK</code></a></li> 344<li><a href="#err_invalid_protocol"><code>ERR_INVALID_PROTOCOL</code></a></li> 345<li><a href="#err_invalid_repl_eval_config"><code>ERR_INVALID_REPL_EVAL_CONFIG</code></a></li> 346<li><a href="#err_invalid_repl_input"><code>ERR_INVALID_REPL_INPUT</code></a></li> 347<li><a href="#err_invalid_return_property"><code>ERR_INVALID_RETURN_PROPERTY</code></a></li> 348<li><a href="#err_invalid_return_property_value"><code>ERR_INVALID_RETURN_PROPERTY_VALUE</code></a></li> 349<li><a href="#err_invalid_return_value"><code>ERR_INVALID_RETURN_VALUE</code></a></li> 350<li><a href="#err_invalid_state"><code>ERR_INVALID_STATE</code></a></li> 351<li><a href="#err_invalid_sync_fork_input"><code>ERR_INVALID_SYNC_FORK_INPUT</code></a></li> 352<li><a href="#err_invalid_this"><code>ERR_INVALID_THIS</code></a></li> 353<li><a href="#err_invalid_transfer_object"><code>ERR_INVALID_TRANSFER_OBJECT</code></a></li> 354<li><a href="#err_invalid_tuple"><code>ERR_INVALID_TUPLE</code></a></li> 355<li><a href="#err_invalid_uri"><code>ERR_INVALID_URI</code></a></li> 356<li><a href="#err_invalid_url"><code>ERR_INVALID_URL</code></a></li> 357<li><a href="#err_invalid_url_scheme"><code>ERR_INVALID_URL_SCHEME</code></a></li> 358<li><a href="#err_ipc_channel_closed"><code>ERR_IPC_CHANNEL_CLOSED</code></a></li> 359<li><a href="#err_ipc_disconnected"><code>ERR_IPC_DISCONNECTED</code></a></li> 360<li><a href="#err_ipc_one_pipe"><code>ERR_IPC_ONE_PIPE</code></a></li> 361<li><a href="#err_ipc_sync_fork"><code>ERR_IPC_SYNC_FORK</code></a></li> 362<li><a href="#err_loader_chain_incomplete"><code>ERR_LOADER_CHAIN_INCOMPLETE</code></a></li> 363<li><a href="#err_manifest_assert_integrity"><code>ERR_MANIFEST_ASSERT_INTEGRITY</code></a></li> 364<li><a href="#err_manifest_dependency_missing"><code>ERR_MANIFEST_DEPENDENCY_MISSING</code></a></li> 365<li><a href="#err_manifest_integrity_mismatch"><code>ERR_MANIFEST_INTEGRITY_MISMATCH</code></a></li> 366<li><a href="#err_manifest_invalid_resource_field"><code>ERR_MANIFEST_INVALID_RESOURCE_FIELD</code></a></li> 367<li><a href="#err_manifest_invalid_specifier"><code>ERR_MANIFEST_INVALID_SPECIFIER</code></a></li> 368<li><a href="#err_manifest_parse_policy"><code>ERR_MANIFEST_PARSE_POLICY</code></a></li> 369<li><a href="#err_manifest_tdz"><code>ERR_MANIFEST_TDZ</code></a></li> 370<li><a href="#err_manifest_unknown_onerror"><code>ERR_MANIFEST_UNKNOWN_ONERROR</code></a></li> 371<li><a href="#err_memory_allocation_failed"><code>ERR_MEMORY_ALLOCATION_FAILED</code></a></li> 372<li><a href="#err_message_target_context_unavailable"><code>ERR_MESSAGE_TARGET_CONTEXT_UNAVAILABLE</code></a></li> 373<li><a href="#err_method_not_implemented"><code>ERR_METHOD_NOT_IMPLEMENTED</code></a></li> 374<li><a href="#err_missing_args"><code>ERR_MISSING_ARGS</code></a></li> 375<li><a href="#err_missing_option"><code>ERR_MISSING_OPTION</code></a></li> 376<li><a href="#err_missing_passphrase"><code>ERR_MISSING_PASSPHRASE</code></a></li> 377<li><a href="#err_missing_platform_for_worker"><code>ERR_MISSING_PLATFORM_FOR_WORKER</code></a></li> 378<li><a href="#err_missing_transferable_in_transfer_list"><code>ERR_MISSING_TRANSFERABLE_IN_TRANSFER_LIST</code></a></li> 379<li><a href="#err_module_not_found"><code>ERR_MODULE_NOT_FOUND</code></a></li> 380<li><a href="#err_multiple_callback"><code>ERR_MULTIPLE_CALLBACK</code></a></li> 381<li><a href="#err_napi_cons_function"><code>ERR_NAPI_CONS_FUNCTION</code></a></li> 382<li><a href="#err_napi_invalid_dataview_args"><code>ERR_NAPI_INVALID_DATAVIEW_ARGS</code></a></li> 383<li><a href="#err_napi_invalid_typedarray_alignment"><code>ERR_NAPI_INVALID_TYPEDARRAY_ALIGNMENT</code></a></li> 384<li><a href="#err_napi_invalid_typedarray_length"><code>ERR_NAPI_INVALID_TYPEDARRAY_LENGTH</code></a></li> 385<li><a href="#err_napi_tsfn_call_js"><code>ERR_NAPI_TSFN_CALL_JS</code></a></li> 386<li><a href="#err_napi_tsfn_get_undefined"><code>ERR_NAPI_TSFN_GET_UNDEFINED</code></a></li> 387<li><a href="#err_napi_tsfn_start_idle_loop"><code>ERR_NAPI_TSFN_START_IDLE_LOOP</code></a></li> 388<li><a href="#err_napi_tsfn_stop_idle_loop"><code>ERR_NAPI_TSFN_STOP_IDLE_LOOP</code></a></li> 389<li><a href="#err_not_building_snapshot"><code>ERR_NOT_BUILDING_SNAPSHOT</code></a></li> 390<li><a href="#err_no_crypto"><code>ERR_NO_CRYPTO</code></a></li> 391<li><a href="#err_no_icu"><code>ERR_NO_ICU</code></a></li> 392<li><a href="#err_non_context_aware_disabled"><code>ERR_NON_CONTEXT_AWARE_DISABLED</code></a></li> 393<li><a href="#err_out_of_range"><code>ERR_OUT_OF_RANGE</code></a></li> 394<li><a href="#err_package_import_not_defined"><code>ERR_PACKAGE_IMPORT_NOT_DEFINED</code></a></li> 395<li><a href="#err_package_path_not_exported"><code>ERR_PACKAGE_PATH_NOT_EXPORTED</code></a></li> 396<li><a href="#err_parse_args_invalid_option_value"><code>ERR_PARSE_ARGS_INVALID_OPTION_VALUE</code></a></li> 397<li><a href="#err_parse_args_unexpected_positional"><code>ERR_PARSE_ARGS_UNEXPECTED_POSITIONAL</code></a></li> 398<li><a href="#err_parse_args_unknown_option"><code>ERR_PARSE_ARGS_UNKNOWN_OPTION</code></a></li> 399<li><a href="#err_performance_invalid_timestamp"><code>ERR_PERFORMANCE_INVALID_TIMESTAMP</code></a></li> 400<li><a href="#err_performance_measure_invalid_options"><code>ERR_PERFORMANCE_MEASURE_INVALID_OPTIONS</code></a></li> 401<li><a href="#err_proto_access"><code>ERR_PROTO_ACCESS</code></a></li> 402<li><span class="stability_1"><a href="#err_require_esm"><code>ERR_REQUIRE_ESM</code></a></span></li> 403<li><a href="#err_script_execution_interrupted"><code>ERR_SCRIPT_EXECUTION_INTERRUPTED</code></a></li> 404<li><a href="#err_script_execution_timeout"><code>ERR_SCRIPT_EXECUTION_TIMEOUT</code></a></li> 405<li><a href="#err_server_already_listen"><code>ERR_SERVER_ALREADY_LISTEN</code></a></li> 406<li><a href="#err_server_not_running"><code>ERR_SERVER_NOT_RUNNING</code></a></li> 407<li><a href="#err_socket_already_bound"><code>ERR_SOCKET_ALREADY_BOUND</code></a></li> 408<li><a href="#err_socket_bad_buffer_size"><code>ERR_SOCKET_BAD_BUFFER_SIZE</code></a></li> 409<li><a href="#err_socket_bad_port"><code>ERR_SOCKET_BAD_PORT</code></a></li> 410<li><a href="#err_socket_bad_type"><code>ERR_SOCKET_BAD_TYPE</code></a></li> 411<li><a href="#err_socket_buffer_size"><code>ERR_SOCKET_BUFFER_SIZE</code></a></li> 412<li><a href="#err_socket_closed"><code>ERR_SOCKET_CLOSED</code></a></li> 413<li><a href="#err_socket_closed_before_connection"><code>ERR_SOCKET_CLOSED_BEFORE_CONNECTION</code></a></li> 414<li><a href="#err_socket_dgram_is_connected"><code>ERR_SOCKET_DGRAM_IS_CONNECTED</code></a></li> 415<li><a href="#err_socket_dgram_not_connected"><code>ERR_SOCKET_DGRAM_NOT_CONNECTED</code></a></li> 416<li><a href="#err_socket_dgram_not_running"><code>ERR_SOCKET_DGRAM_NOT_RUNNING</code></a></li> 417<li><a href="#err_sri_parse"><code>ERR_SRI_PARSE</code></a></li> 418<li><a href="#err_stream_already_finished"><code>ERR_STREAM_ALREADY_FINISHED</code></a></li> 419<li><a href="#err_stream_cannot_pipe"><code>ERR_STREAM_CANNOT_PIPE</code></a></li> 420<li><a href="#err_stream_destroyed"><code>ERR_STREAM_DESTROYED</code></a></li> 421<li><a href="#err_stream_null_values"><code>ERR_STREAM_NULL_VALUES</code></a></li> 422<li><a href="#err_stream_premature_close"><code>ERR_STREAM_PREMATURE_CLOSE</code></a></li> 423<li><a href="#err_stream_push_after_eof"><code>ERR_STREAM_PUSH_AFTER_EOF</code></a></li> 424<li><a href="#err_stream_unshift_after_end_event"><code>ERR_STREAM_UNSHIFT_AFTER_END_EVENT</code></a></li> 425<li><a href="#err_stream_wrap"><code>ERR_STREAM_WRAP</code></a></li> 426<li><a href="#err_stream_write_after_end"><code>ERR_STREAM_WRITE_AFTER_END</code></a></li> 427<li><a href="#err_string_too_long"><code>ERR_STRING_TOO_LONG</code></a></li> 428<li><a href="#err_synthetic"><code>ERR_SYNTHETIC</code></a></li> 429<li><a href="#err_system_error"><code>ERR_SYSTEM_ERROR</code></a></li> 430<li><a href="#err_tap_lexer_error"><code>ERR_TAP_LEXER_ERROR</code></a></li> 431<li><a href="#err_tap_parser_error"><code>ERR_TAP_PARSER_ERROR</code></a></li> 432<li><a href="#err_tap_validation_error"><code>ERR_TAP_VALIDATION_ERROR</code></a></li> 433<li><a href="#err_test_failure"><code>ERR_TEST_FAILURE</code></a></li> 434<li><a href="#err_tls_cert_altname_format"><code>ERR_TLS_CERT_ALTNAME_FORMAT</code></a></li> 435<li><a href="#err_tls_cert_altname_invalid"><code>ERR_TLS_CERT_ALTNAME_INVALID</code></a></li> 436<li><a href="#err_tls_dh_param_size"><code>ERR_TLS_DH_PARAM_SIZE</code></a></li> 437<li><a href="#err_tls_handshake_timeout"><code>ERR_TLS_HANDSHAKE_TIMEOUT</code></a></li> 438<li><a href="#err_tls_invalid_context"><code>ERR_TLS_INVALID_CONTEXT</code></a></li> 439<li><a href="#err_tls_invalid_protocol_method"><code>ERR_TLS_INVALID_PROTOCOL_METHOD</code></a></li> 440<li><a href="#err_tls_invalid_protocol_version"><code>ERR_TLS_INVALID_PROTOCOL_VERSION</code></a></li> 441<li><a href="#err_tls_invalid_state"><code>ERR_TLS_INVALID_STATE</code></a></li> 442<li><a href="#err_tls_protocol_version_conflict"><code>ERR_TLS_PROTOCOL_VERSION_CONFLICT</code></a></li> 443<li><a href="#err_tls_psk_set_identiy_hint_failed"><code>ERR_TLS_PSK_SET_IDENTIY_HINT_FAILED</code></a></li> 444<li><a href="#err_tls_renegotiation_disabled"><code>ERR_TLS_RENEGOTIATION_DISABLED</code></a></li> 445<li><a href="#err_tls_required_server_name"><code>ERR_TLS_REQUIRED_SERVER_NAME</code></a></li> 446<li><a href="#err_tls_session_attack"><code>ERR_TLS_SESSION_ATTACK</code></a></li> 447<li><a href="#err_tls_sni_from_server"><code>ERR_TLS_SNI_FROM_SERVER</code></a></li> 448<li><a href="#err_trace_events_category_required"><code>ERR_TRACE_EVENTS_CATEGORY_REQUIRED</code></a></li> 449<li><a href="#err_trace_events_unavailable"><code>ERR_TRACE_EVENTS_UNAVAILABLE</code></a></li> 450<li><a href="#err_transform_already_transforming"><code>ERR_TRANSFORM_ALREADY_TRANSFORMING</code></a></li> 451<li><a href="#err_transform_with_length_0"><code>ERR_TRANSFORM_WITH_LENGTH_0</code></a></li> 452<li><a href="#err_tty_init_failed"><code>ERR_TTY_INIT_FAILED</code></a></li> 453<li><a href="#err_unavailable_during_exit"><code>ERR_UNAVAILABLE_DURING_EXIT</code></a></li> 454<li><a href="#err_uncaught_exception_capture_already_set"><code>ERR_UNCAUGHT_EXCEPTION_CAPTURE_ALREADY_SET</code></a></li> 455<li><a href="#err_unescaped_characters"><code>ERR_UNESCAPED_CHARACTERS</code></a></li> 456<li><a href="#err_unhandled_error"><code>ERR_UNHANDLED_ERROR</code></a></li> 457<li><a href="#err_unknown_builtin_module"><code>ERR_UNKNOWN_BUILTIN_MODULE</code></a></li> 458<li><a href="#err_unknown_credential"><code>ERR_UNKNOWN_CREDENTIAL</code></a></li> 459<li><a href="#err_unknown_encoding"><code>ERR_UNKNOWN_ENCODING</code></a></li> 460<li><span class="stability_1"><a href="#err_unknown_file_extension"><code>ERR_UNKNOWN_FILE_EXTENSION</code></a></span></li> 461<li><span class="stability_1"><a href="#err_unknown_module_format"><code>ERR_UNKNOWN_MODULE_FORMAT</code></a></span></li> 462<li><a href="#err_unknown_signal"><code>ERR_UNKNOWN_SIGNAL</code></a></li> 463<li><a href="#err_unsupported_dir_import"><code>ERR_UNSUPPORTED_DIR_IMPORT</code></a></li> 464<li><a href="#err_unsupported_esm_url_scheme"><code>ERR_UNSUPPORTED_ESM_URL_SCHEME</code></a></li> 465<li><span class="stability_1"><a href="#err_use_after_close"><code>ERR_USE_AFTER_CLOSE</code></a></span></li> 466<li><a href="#err_valid_performance_entry_type"><code>ERR_VALID_PERFORMANCE_ENTRY_TYPE</code></a></li> 467<li><a href="#err_vm_dynamic_import_callback_missing"><code>ERR_VM_DYNAMIC_IMPORT_CALLBACK_MISSING</code></a></li> 468<li><a href="#err_vm_module_already_linked"><code>ERR_VM_MODULE_ALREADY_LINKED</code></a></li> 469<li><a href="#err_vm_module_cached_data_rejected"><code>ERR_VM_MODULE_CACHED_DATA_REJECTED</code></a></li> 470<li><a href="#err_vm_module_cannot_create_cached_data"><code>ERR_VM_MODULE_CANNOT_CREATE_CACHED_DATA</code></a></li> 471<li><a href="#err_vm_module_different_context"><code>ERR_VM_MODULE_DIFFERENT_CONTEXT</code></a></li> 472<li><a href="#err_vm_module_link_failure"><code>ERR_VM_MODULE_LINK_FAILURE</code></a></li> 473<li><a href="#err_vm_module_not_module"><code>ERR_VM_MODULE_NOT_MODULE</code></a></li> 474<li><a href="#err_vm_module_status"><code>ERR_VM_MODULE_STATUS</code></a></li> 475<li><a href="#err_wasi_already_started"><code>ERR_WASI_ALREADY_STARTED</code></a></li> 476<li><a href="#err_wasi_not_started"><code>ERR_WASI_NOT_STARTED</code></a></li> 477<li><a href="#err_webassembly_response"><code>ERR_WEBASSEMBLY_RESPONSE</code></a></li> 478<li><a href="#err_worker_init_failed"><code>ERR_WORKER_INIT_FAILED</code></a></li> 479<li><a href="#err_worker_invalid_exec_argv"><code>ERR_WORKER_INVALID_EXEC_ARGV</code></a></li> 480<li><a href="#err_worker_not_running"><code>ERR_WORKER_NOT_RUNNING</code></a></li> 481<li><a href="#err_worker_out_of_memory"><code>ERR_WORKER_OUT_OF_MEMORY</code></a></li> 482<li><a href="#err_worker_path"><code>ERR_WORKER_PATH</code></a></li> 483<li><a href="#err_worker_unserializable_error"><code>ERR_WORKER_UNSERIALIZABLE_ERROR</code></a></li> 484<li><a href="#err_worker_unsupported_operation"><code>ERR_WORKER_UNSUPPORTED_OPERATION</code></a></li> 485<li><a href="#err_zlib_initialization_failed"><code>ERR_ZLIB_INITIALIZATION_FAILED</code></a></li> 486<li><a href="#hpe_header_overflow"><code>HPE_HEADER_OVERFLOW</code></a></li> 487<li><a href="#hpe_unexpected_content_length"><code>HPE_UNEXPECTED_CONTENT_LENGTH</code></a></li> 488<li><a href="#module_not_found"><code>MODULE_NOT_FOUND</code></a></li> 489</ul> 490</li> 491<li><span class="stability_0"><a href="#legacy-nodejs-error-codes">Legacy Node.js error codes</a></span> 492<ul> 493<li><a href="#err_cannot_transfer_object"><code>ERR_CANNOT_TRANSFER_OBJECT</code></a></li> 494<li><a href="#err_crypto_hash_digest_no_utf16"><code>ERR_CRYPTO_HASH_DIGEST_NO_UTF16</code></a></li> 495<li><a href="#err_http2_frame_error"><code>ERR_HTTP2_FRAME_ERROR</code></a></li> 496<li><a href="#err_http2_headers_object"><code>ERR_HTTP2_HEADERS_OBJECT</code></a></li> 497<li><a href="#err_http2_header_required"><code>ERR_HTTP2_HEADER_REQUIRED</code></a></li> 498<li><a href="#err_http2_info_headers_after_respond"><code>ERR_HTTP2_INFO_HEADERS_AFTER_RESPOND</code></a></li> 499<li><a href="#err_http2_stream_closed"><code>ERR_HTTP2_STREAM_CLOSED</code></a></li> 500<li><a href="#err_http_invalid_char"><code>ERR_HTTP_INVALID_CHAR</code></a></li> 501<li><a href="#err_index_out_of_range"><code>ERR_INDEX_OUT_OF_RANGE</code></a></li> 502<li><a href="#err_invalid_opt_value"><code>ERR_INVALID_OPT_VALUE</code></a></li> 503<li><a href="#err_invalid_opt_value_encoding"><code>ERR_INVALID_OPT_VALUE_ENCODING</code></a></li> 504<li><a href="#err_missing_message_port_in_transfer_list"><code>ERR_MISSING_MESSAGE_PORT_IN_TRANSFER_LIST</code></a></li> 505<li><a href="#err_napi_cons_prototype_object"><code>ERR_NAPI_CONS_PROTOTYPE_OBJECT</code></a></li> 506<li><span class="stability_1"><a href="#err_network_import_bad_response"><code>ERR_NETWORK_IMPORT_BAD_RESPONSE</code></a></span></li> 507<li><span class="stability_1"><a href="#err_network_import_disallowed"><code>ERR_NETWORK_IMPORT_DISALLOWED</code></a></span></li> 508<li><a href="#err_no_longer_supported"><code>ERR_NO_LONGER_SUPPORTED</code></a></li> 509<li><a href="#err_operation_failed"><code>ERR_OPERATION_FAILED</code></a></li> 510<li><a href="#err_outofmemory"><code>ERR_OUTOFMEMORY</code></a></li> 511<li><a href="#err_parse_history_data"><code>ERR_PARSE_HISTORY_DATA</code></a></li> 512<li><a href="#err_socket_cannot_send"><code>ERR_SOCKET_CANNOT_SEND</code></a></li> 513<li><a href="#err_stderr_close"><code>ERR_STDERR_CLOSE</code></a></li> 514<li><a href="#err_stdout_close"><code>ERR_STDOUT_CLOSE</code></a></li> 515<li><a href="#err_stream_read_not_implemented"><code>ERR_STREAM_READ_NOT_IMPLEMENTED</code></a></li> 516<li><a href="#err_tls_renegotiation_failed"><code>ERR_TLS_RENEGOTIATION_FAILED</code></a></li> 517<li><a href="#err_transferring_externalized_sharedarraybuffer"><code>ERR_TRANSFERRING_EXTERNALIZED_SHAREDARRAYBUFFER</code></a></li> 518<li><a href="#err_unknown_stdin_type"><code>ERR_UNKNOWN_STDIN_TYPE</code></a></li> 519<li><a href="#err_unknown_stream_type"><code>ERR_UNKNOWN_STREAM_TYPE</code></a></li> 520<li><a href="#err_v8breakiterator"><code>ERR_V8BREAKITERATOR</code></a></li> 521<li><a href="#err_value_out_of_range"><code>ERR_VALUE_OUT_OF_RANGE</code></a></li> 522<li><a href="#err_vm_module_not_linked"><code>ERR_VM_MODULE_NOT_LINKED</code></a></li> 523<li><a href="#err_vm_module_linking_errored"><code>ERR_VM_MODULE_LINKING_ERRORED</code></a></li> 524<li><a href="#err_worker_unsupported_extension"><code>ERR_WORKER_UNSUPPORTED_EXTENSION</code></a></li> 525<li><a href="#err_zlib_binding_closed"><code>ERR_ZLIB_BINDING_CLOSED</code></a></li> 526<li><a href="#err_cpu_usage"><code>ERR_CPU_USAGE</code></a></li> 527</ul> 528</li> 529</ul> 530</li> 531</ul></div></div> 532 </li> 533 534 535 <li class="picker-header"> 536 <a href="#"> 537 <span class="collapsed-arrow">►</span><span class="expanded-arrow">▼</span> 538 Index 539 </a> 540 541 <div class="picker"><ul> 542<li><a href="documentation.html" class="nav-documentation">About this documentation</a></li> 543<li><a href="synopsis.html" class="nav-synopsis">Usage and example</a></li> 544 545 <li> 546 <a href="index.html">Index</a> 547 </li> 548 </ul> 549 550<hr class="line"> 551<ul> 552<li><a href="assert.html" class="nav-assert">Assertion testing</a></li> 553<li><a href="async_context.html" class="nav-async_context">Asynchronous context tracking</a></li> 554<li><a href="async_hooks.html" class="nav-async_hooks">Async hooks</a></li> 555<li><a href="buffer.html" class="nav-buffer">Buffer</a></li> 556<li><a href="addons.html" class="nav-addons">C++ addons</a></li> 557<li><a href="n-api.html" class="nav-n-api">C/C++ addons with Node-API</a></li> 558<li><a href="embedding.html" class="nav-embedding">C++ embedder API</a></li> 559<li><a href="child_process.html" class="nav-child_process">Child processes</a></li> 560<li><a href="cluster.html" class="nav-cluster">Cluster</a></li> 561<li><a href="cli.html" class="nav-cli">Command-line options</a></li> 562<li><a href="console.html" class="nav-console">Console</a></li> 563<li><a href="corepack.html" class="nav-corepack">Corepack</a></li> 564<li><a href="crypto.html" class="nav-crypto">Crypto</a></li> 565<li><a href="debugger.html" class="nav-debugger">Debugger</a></li> 566<li><a href="deprecations.html" class="nav-deprecations">Deprecated APIs</a></li> 567<li><a href="diagnostics_channel.html" class="nav-diagnostics_channel">Diagnostics Channel</a></li> 568<li><a href="dns.html" class="nav-dns">DNS</a></li> 569<li><a href="domain.html" class="nav-domain">Domain</a></li> 570<li><a href="errors.html" class="nav-errors active">Errors</a></li> 571<li><a href="events.html" class="nav-events">Events</a></li> 572<li><a href="fs.html" class="nav-fs">File system</a></li> 573<li><a href="globals.html" class="nav-globals">Globals</a></li> 574<li><a href="http.html" class="nav-http">HTTP</a></li> 575<li><a href="http2.html" class="nav-http2">HTTP/2</a></li> 576<li><a href="https.html" class="nav-https">HTTPS</a></li> 577<li><a href="inspector.html" class="nav-inspector">Inspector</a></li> 578<li><a href="intl.html" class="nav-intl">Internationalization</a></li> 579<li><a href="modules.html" class="nav-modules">Modules: CommonJS modules</a></li> 580<li><a href="esm.html" class="nav-esm">Modules: ECMAScript modules</a></li> 581<li><a href="module.html" class="nav-module">Modules: <code>node:module</code> API</a></li> 582<li><a href="packages.html" class="nav-packages">Modules: Packages</a></li> 583<li><a href="net.html" class="nav-net">Net</a></li> 584<li><a href="os.html" class="nav-os">OS</a></li> 585<li><a href="path.html" class="nav-path">Path</a></li> 586<li><a href="perf_hooks.html" class="nav-perf_hooks">Performance hooks</a></li> 587<li><a href="permissions.html" class="nav-permissions">Permissions</a></li> 588<li><a href="process.html" class="nav-process">Process</a></li> 589<li><a href="punycode.html" class="nav-punycode">Punycode</a></li> 590<li><a href="querystring.html" class="nav-querystring">Query strings</a></li> 591<li><a href="readline.html" class="nav-readline">Readline</a></li> 592<li><a href="repl.html" class="nav-repl">REPL</a></li> 593<li><a href="report.html" class="nav-report">Report</a></li> 594<li><a href="single-executable-applications.html" class="nav-single-executable-applications">Single executable applications</a></li> 595<li><a href="stream.html" class="nav-stream">Stream</a></li> 596<li><a href="string_decoder.html" class="nav-string_decoder">String decoder</a></li> 597<li><a href="test.html" class="nav-test">Test runner</a></li> 598<li><a href="timers.html" class="nav-timers">Timers</a></li> 599<li><a href="tls.html" class="nav-tls">TLS/SSL</a></li> 600<li><a href="tracing.html" class="nav-tracing">Trace events</a></li> 601<li><a href="tty.html" class="nav-tty">TTY</a></li> 602<li><a href="dgram.html" class="nav-dgram">UDP/datagram</a></li> 603<li><a href="url.html" class="nav-url">URL</a></li> 604<li><a href="util.html" class="nav-util">Utilities</a></li> 605<li><a href="v8.html" class="nav-v8">V8</a></li> 606<li><a href="vm.html" class="nav-vm">VM</a></li> 607<li><a href="wasi.html" class="nav-wasi">WASI</a></li> 608<li><a href="webcrypto.html" class="nav-webcrypto">Web Crypto API</a></li> 609<li><a href="webstreams.html" class="nav-webstreams">Web Streams API</a></li> 610<li><a href="worker_threads.html" class="nav-worker_threads">Worker threads</a></li> 611<li><a href="zlib.html" class="nav-zlib">Zlib</a></li> 612</ul> 613<hr class="line"> 614<ul> 615<li><a href="https://github.com/nodejs/node" class="nav-https-github-com-nodejs-node">Code repository and issue tracker</a></li> 616</ul></div> 617 </li> 618 619 620 <li class="picker-header"> 621 <a href="#"> 622 <span class="collapsed-arrow">►</span><span class="expanded-arrow">▼</span> 623 Other versions 624 </a> 625 <div class="picker"><ol id="alt-docs"><li><a href="https://nodejs.org/docs/latest-v20.x/api/errors.html">20.x</a></li> 626<li><a href="https://nodejs.org/docs/latest-v19.x/api/errors.html">19.x</a></li> 627<li><a href="https://nodejs.org/docs/latest-v18.x/api/errors.html">18.x <b>LTS</b></a></li> 628<li><a href="https://nodejs.org/docs/latest-v17.x/api/errors.html">17.x</a></li> 629<li><a href="https://nodejs.org/docs/latest-v16.x/api/errors.html">16.x</a></li> 630<li><a href="https://nodejs.org/docs/latest-v15.x/api/errors.html">15.x</a></li> 631<li><a href="https://nodejs.org/docs/latest-v14.x/api/errors.html">14.x</a></li> 632<li><a href="https://nodejs.org/docs/latest-v13.x/api/errors.html">13.x</a></li> 633<li><a href="https://nodejs.org/docs/latest-v12.x/api/errors.html">12.x</a></li> 634<li><a href="https://nodejs.org/docs/latest-v11.x/api/errors.html">11.x</a></li> 635<li><a href="https://nodejs.org/docs/latest-v10.x/api/errors.html">10.x</a></li> 636<li><a href="https://nodejs.org/docs/latest-v9.x/api/errors.html">9.x</a></li> 637<li><a href="https://nodejs.org/docs/latest-v8.x/api/errors.html">8.x</a></li> 638<li><a href="https://nodejs.org/docs/latest-v7.x/api/errors.html">7.x</a></li> 639<li><a href="https://nodejs.org/docs/latest-v6.x/api/errors.html">6.x</a></li> 640<li><a href="https://nodejs.org/docs/latest-v5.x/api/errors.html">5.x</a></li> 641<li><a href="https://nodejs.org/docs/latest-v4.x/api/errors.html">4.x</a></li></ol></div> 642 </li> 643 644 <li class="picker-header"> 645 <a href="#"> 646 <span class="collapsed-arrow">►</span><span class="expanded-arrow">▼</span> 647 Options 648 </a> 649 650 <div class="picker"> 651 <ul> 652 <li> 653 <a href="all.html">View on single page</a> 654 </li> 655 <li> 656 <a href="errors.json">View as JSON</a> 657 </li> 658 <li class="edit_on_github"><a href="https://github.com/nodejs/node/edit/main/doc/api/errors.md">Edit on GitHub</a></li> 659 </ul> 660 </div> 661 </li> 662 </ul> 663 </div> 664 <hr> 665 </header> 666 667 <details id="toc" open><summary>Table of contents</summary><ul> 668<li><a href="#errors">Errors</a> 669<ul> 670<li><a href="#error-propagation-and-interception">Error propagation and interception</a></li> 671<li><a href="#class-error">Class: <code>Error</code></a> 672<ul> 673<li><a href="#new-errormessage-options"><code>new Error(message[, options])</code></a></li> 674<li><a href="#errorcapturestacktracetargetobject-constructoropt"><code>Error.captureStackTrace(targetObject[, constructorOpt])</code></a></li> 675<li><a href="#errorstacktracelimit"><code>Error.stackTraceLimit</code></a></li> 676<li><a href="#errorcause"><code>error.cause</code></a></li> 677<li><a href="#errorcode"><code>error.code</code></a></li> 678<li><a href="#errormessage"><code>error.message</code></a></li> 679<li><a href="#errorstack"><code>error.stack</code></a></li> 680</ul> 681</li> 682<li><a href="#class-assertionerror">Class: <code>AssertionError</code></a></li> 683<li><a href="#class-rangeerror">Class: <code>RangeError</code></a></li> 684<li><a href="#class-referenceerror">Class: <code>ReferenceError</code></a></li> 685<li><a href="#class-syntaxerror">Class: <code>SyntaxError</code></a></li> 686<li><a href="#class-systemerror">Class: <code>SystemError</code></a> 687<ul> 688<li><a href="#erroraddress"><code>error.address</code></a></li> 689<li><a href="#errorcode_1"><code>error.code</code></a></li> 690<li><a href="#errordest"><code>error.dest</code></a></li> 691<li><a href="#errorerrno"><code>error.errno</code></a></li> 692<li><a href="#errorinfo"><code>error.info</code></a></li> 693<li><a href="#errormessage_1"><code>error.message</code></a></li> 694<li><a href="#errorpath"><code>error.path</code></a></li> 695<li><a href="#errorport"><code>error.port</code></a></li> 696<li><a href="#errorsyscall"><code>error.syscall</code></a></li> 697<li><a href="#common-system-errors">Common system errors</a></li> 698</ul> 699</li> 700<li><a href="#class-typeerror">Class: <code>TypeError</code></a></li> 701<li><a href="#exceptions-vs-errors">Exceptions vs. errors</a></li> 702<li><a href="#openssl-errors">OpenSSL errors</a> 703<ul> 704<li><a href="#erroropensslerrorstack"><code>error.opensslErrorStack</code></a></li> 705<li><a href="#errorfunction"><code>error.function</code></a></li> 706<li><a href="#errorlibrary"><code>error.library</code></a></li> 707<li><a href="#errorreason"><code>error.reason</code></a></li> 708</ul> 709</li> 710<li><a href="#nodejs-error-codes">Node.js error codes</a> 711<ul> 712<li><a href="#abort_err"><code>ABORT_ERR</code></a></li> 713<li><a href="#err_access_denied"><code>ERR_ACCESS_DENIED</code></a></li> 714<li><a href="#err_ambiguous_argument"><code>ERR_AMBIGUOUS_ARGUMENT</code></a></li> 715<li><a href="#err_arg_not_iterable"><code>ERR_ARG_NOT_ITERABLE</code></a></li> 716<li><a href="#err_assertion"><code>ERR_ASSERTION</code></a></li> 717<li><a href="#err_async_callback"><code>ERR_ASYNC_CALLBACK</code></a></li> 718<li><a href="#err_async_type"><code>ERR_ASYNC_TYPE</code></a></li> 719<li><a href="#err_brotli_compression_failed"><code>ERR_BROTLI_COMPRESSION_FAILED</code></a></li> 720<li><a href="#err_brotli_invalid_param"><code>ERR_BROTLI_INVALID_PARAM</code></a></li> 721<li><a href="#err_buffer_context_not_available"><code>ERR_BUFFER_CONTEXT_NOT_AVAILABLE</code></a></li> 722<li><a href="#err_buffer_out_of_bounds"><code>ERR_BUFFER_OUT_OF_BOUNDS</code></a></li> 723<li><a href="#err_buffer_too_large"><code>ERR_BUFFER_TOO_LARGE</code></a></li> 724<li><a href="#err_cannot_watch_sigint"><code>ERR_CANNOT_WATCH_SIGINT</code></a></li> 725<li><a href="#err_child_closed_before_reply"><code>ERR_CHILD_CLOSED_BEFORE_REPLY</code></a></li> 726<li><a href="#err_child_process_ipc_required"><code>ERR_CHILD_PROCESS_IPC_REQUIRED</code></a></li> 727<li><a href="#err_child_process_stdio_maxbuffer"><code>ERR_CHILD_PROCESS_STDIO_MAXBUFFER</code></a></li> 728<li><a href="#err_closed_message_port"><code>ERR_CLOSED_MESSAGE_PORT</code></a></li> 729<li><a href="#err_console_writable_stream"><code>ERR_CONSOLE_WRITABLE_STREAM</code></a></li> 730<li><a href="#err_construct_call_invalid"><code>ERR_CONSTRUCT_CALL_INVALID</code></a></li> 731<li><a href="#err_construct_call_required"><code>ERR_CONSTRUCT_CALL_REQUIRED</code></a></li> 732<li><a href="#err_context_not_initialized"><code>ERR_CONTEXT_NOT_INITIALIZED</code></a></li> 733<li><a href="#err_crypto_custom_engine_not_supported"><code>ERR_CRYPTO_CUSTOM_ENGINE_NOT_SUPPORTED</code></a></li> 734<li><a href="#err_crypto_ecdh_invalid_format"><code>ERR_CRYPTO_ECDH_INVALID_FORMAT</code></a></li> 735<li><a href="#err_crypto_ecdh_invalid_public_key"><code>ERR_CRYPTO_ECDH_INVALID_PUBLIC_KEY</code></a></li> 736<li><a href="#err_crypto_engine_unknown"><code>ERR_CRYPTO_ENGINE_UNKNOWN</code></a></li> 737<li><a href="#err_crypto_fips_forced"><code>ERR_CRYPTO_FIPS_FORCED</code></a></li> 738<li><a href="#err_crypto_fips_unavailable"><code>ERR_CRYPTO_FIPS_UNAVAILABLE</code></a></li> 739<li><a href="#err_crypto_hash_finalized"><code>ERR_CRYPTO_HASH_FINALIZED</code></a></li> 740<li><a href="#err_crypto_hash_update_failed"><code>ERR_CRYPTO_HASH_UPDATE_FAILED</code></a></li> 741<li><a href="#err_crypto_incompatible_key"><code>ERR_CRYPTO_INCOMPATIBLE_KEY</code></a></li> 742<li><a href="#err_crypto_incompatible_key_options"><code>ERR_CRYPTO_INCOMPATIBLE_KEY_OPTIONS</code></a></li> 743<li><a href="#err_crypto_initialization_failed"><code>ERR_CRYPTO_INITIALIZATION_FAILED</code></a></li> 744<li><a href="#err_crypto_invalid_auth_tag"><code>ERR_CRYPTO_INVALID_AUTH_TAG</code></a></li> 745<li><a href="#err_crypto_invalid_counter"><code>ERR_CRYPTO_INVALID_COUNTER</code></a></li> 746<li><a href="#err_crypto_invalid_curve"><code>ERR_CRYPTO_INVALID_CURVE</code></a></li> 747<li><a href="#err_crypto_invalid_digest"><code>ERR_CRYPTO_INVALID_DIGEST</code></a></li> 748<li><a href="#err_crypto_invalid_iv"><code>ERR_CRYPTO_INVALID_IV</code></a></li> 749<li><a href="#err_crypto_invalid_jwk"><code>ERR_CRYPTO_INVALID_JWK</code></a></li> 750<li><a href="#err_crypto_invalid_key_object_type"><code>ERR_CRYPTO_INVALID_KEY_OBJECT_TYPE</code></a></li> 751<li><a href="#err_crypto_invalid_keylen"><code>ERR_CRYPTO_INVALID_KEYLEN</code></a></li> 752<li><a href="#err_crypto_invalid_keypair"><code>ERR_CRYPTO_INVALID_KEYPAIR</code></a></li> 753<li><a href="#err_crypto_invalid_keytype"><code>ERR_CRYPTO_INVALID_KEYTYPE</code></a></li> 754<li><a href="#err_crypto_invalid_messagelen"><code>ERR_CRYPTO_INVALID_MESSAGELEN</code></a></li> 755<li><a href="#err_crypto_invalid_scrypt_params"><code>ERR_CRYPTO_INVALID_SCRYPT_PARAMS</code></a></li> 756<li><a href="#err_crypto_invalid_state"><code>ERR_CRYPTO_INVALID_STATE</code></a></li> 757<li><a href="#err_crypto_invalid_tag_length"><code>ERR_CRYPTO_INVALID_TAG_LENGTH</code></a></li> 758<li><a href="#err_crypto_job_init_failed"><code>ERR_CRYPTO_JOB_INIT_FAILED</code></a></li> 759<li><a href="#err_crypto_jwk_unsupported_curve"><code>ERR_CRYPTO_JWK_UNSUPPORTED_CURVE</code></a></li> 760<li><a href="#err_crypto_jwk_unsupported_key_type"><code>ERR_CRYPTO_JWK_UNSUPPORTED_KEY_TYPE</code></a></li> 761<li><a href="#err_crypto_operation_failed"><code>ERR_CRYPTO_OPERATION_FAILED</code></a></li> 762<li><a href="#err_crypto_pbkdf2_error"><code>ERR_CRYPTO_PBKDF2_ERROR</code></a></li> 763<li><a href="#err_crypto_scrypt_invalid_parameter"><code>ERR_CRYPTO_SCRYPT_INVALID_PARAMETER</code></a></li> 764<li><a href="#err_crypto_scrypt_not_supported"><code>ERR_CRYPTO_SCRYPT_NOT_SUPPORTED</code></a></li> 765<li><a href="#err_crypto_sign_key_required"><code>ERR_CRYPTO_SIGN_KEY_REQUIRED</code></a></li> 766<li><a href="#err_crypto_timing_safe_equal_length"><code>ERR_CRYPTO_TIMING_SAFE_EQUAL_LENGTH</code></a></li> 767<li><a href="#err_crypto_unknown_cipher"><code>ERR_CRYPTO_UNKNOWN_CIPHER</code></a></li> 768<li><a href="#err_crypto_unknown_dh_group"><code>ERR_CRYPTO_UNKNOWN_DH_GROUP</code></a></li> 769<li><a href="#err_crypto_unsupported_operation"><code>ERR_CRYPTO_UNSUPPORTED_OPERATION</code></a></li> 770<li><a href="#err_debugger_error"><code>ERR_DEBUGGER_ERROR</code></a></li> 771<li><a href="#err_debugger_startup_error"><code>ERR_DEBUGGER_STARTUP_ERROR</code></a></li> 772<li><a href="#err_dlopen_disabled"><code>ERR_DLOPEN_DISABLED</code></a></li> 773<li><a href="#err_dlopen_failed"><code>ERR_DLOPEN_FAILED</code></a></li> 774<li><a href="#err_dir_closed"><code>ERR_DIR_CLOSED</code></a></li> 775<li><a href="#err_dir_concurrent_operation"><code>ERR_DIR_CONCURRENT_OPERATION</code></a></li> 776<li><a href="#err_dns_set_servers_failed"><code>ERR_DNS_SET_SERVERS_FAILED</code></a></li> 777<li><a href="#err_domain_callback_not_available"><code>ERR_DOMAIN_CALLBACK_NOT_AVAILABLE</code></a></li> 778<li><a href="#err_domain_cannot_set_uncaught_exception_capture"><code>ERR_DOMAIN_CANNOT_SET_UNCAUGHT_EXCEPTION_CAPTURE</code></a></li> 779<li><a href="#err_duplicate_startup_snapshot_main_function"><code>ERR_DUPLICATE_STARTUP_SNAPSHOT_MAIN_FUNCTION</code></a></li> 780<li><a href="#err_encoding_invalid_encoded_data"><code>ERR_ENCODING_INVALID_ENCODED_DATA</code></a></li> 781<li><a href="#err_encoding_not_supported"><code>ERR_ENCODING_NOT_SUPPORTED</code></a></li> 782<li><a href="#err_eval_esm_cannot_print"><code>ERR_EVAL_ESM_CANNOT_PRINT</code></a></li> 783<li><a href="#err_event_recursion"><code>ERR_EVENT_RECURSION</code></a></li> 784<li><a href="#err_execution_environment_not_available"><code>ERR_EXECUTION_ENVIRONMENT_NOT_AVAILABLE</code></a></li> 785<li><a href="#err_falsy_value_rejection"><code>ERR_FALSY_VALUE_REJECTION</code></a></li> 786<li><a href="#err_feature_unavailable_on_platform"><code>ERR_FEATURE_UNAVAILABLE_ON_PLATFORM</code></a></li> 787<li><a href="#err_fs_cp_dir_to_non_dir"><code>ERR_FS_CP_DIR_TO_NON_DIR</code></a></li> 788<li><a href="#err_fs_cp_eexist"><code>ERR_FS_CP_EEXIST</code></a></li> 789<li><a href="#err_fs_cp_einval"><code>ERR_FS_CP_EINVAL</code></a></li> 790<li><a href="#err_http_body_not_allowed"><code>ERR_HTTP_BODY_NOT_ALLOWED</code></a></li> 791<li><a href="#err_http_content_length_mismatch"><code>ERR_HTTP_CONTENT_LENGTH_MISMATCH</code></a></li> 792<li><a href="#err_fs_cp_fifo_pipe"><code>ERR_FS_CP_FIFO_PIPE</code></a></li> 793<li><a href="#err_fs_cp_non_dir_to_dir"><code>ERR_FS_CP_NON_DIR_TO_DIR</code></a></li> 794<li><a href="#err_fs_cp_socket"><code>ERR_FS_CP_SOCKET</code></a></li> 795<li><a href="#err_fs_cp_symlink_to_subdirectory"><code>ERR_FS_CP_SYMLINK_TO_SUBDIRECTORY</code></a></li> 796<li><a href="#err_fs_cp_unknown"><code>ERR_FS_CP_UNKNOWN</code></a></li> 797<li><a href="#err_fs_eisdir"><code>ERR_FS_EISDIR</code></a></li> 798<li><a href="#err_fs_file_too_large"><code>ERR_FS_FILE_TOO_LARGE</code></a></li> 799<li><a href="#err_fs_invalid_symlink_type"><code>ERR_FS_INVALID_SYMLINK_TYPE</code></a></li> 800<li><a href="#err_http_headers_sent"><code>ERR_HTTP_HEADERS_SENT</code></a></li> 801<li><a href="#err_http_invalid_header_value"><code>ERR_HTTP_INVALID_HEADER_VALUE</code></a></li> 802<li><a href="#err_http_invalid_status_code"><code>ERR_HTTP_INVALID_STATUS_CODE</code></a></li> 803<li><a href="#err_http_request_timeout"><code>ERR_HTTP_REQUEST_TIMEOUT</code></a></li> 804<li><a href="#err_http_socket_assigned"><code>ERR_HTTP_SOCKET_ASSIGNED</code></a></li> 805<li><a href="#err_http_socket_encoding"><code>ERR_HTTP_SOCKET_ENCODING</code></a></li> 806<li><a href="#err_http_trailer_invalid"><code>ERR_HTTP_TRAILER_INVALID</code></a></li> 807<li><a href="#err_http2_altsvc_invalid_origin"><code>ERR_HTTP2_ALTSVC_INVALID_ORIGIN</code></a></li> 808<li><a href="#err_http2_altsvc_length"><code>ERR_HTTP2_ALTSVC_LENGTH</code></a></li> 809<li><a href="#err_http2_connect_authority"><code>ERR_HTTP2_CONNECT_AUTHORITY</code></a></li> 810<li><a href="#err_http2_connect_path"><code>ERR_HTTP2_CONNECT_PATH</code></a></li> 811<li><a href="#err_http2_connect_scheme"><code>ERR_HTTP2_CONNECT_SCHEME</code></a></li> 812<li><a href="#err_http2_error"><code>ERR_HTTP2_ERROR</code></a></li> 813<li><a href="#err_http2_goaway_session"><code>ERR_HTTP2_GOAWAY_SESSION</code></a></li> 814<li><a href="#err_http2_header_single_value"><code>ERR_HTTP2_HEADER_SINGLE_VALUE</code></a></li> 815<li><a href="#err_http2_headers_after_respond"><code>ERR_HTTP2_HEADERS_AFTER_RESPOND</code></a></li> 816<li><a href="#err_http2_headers_sent"><code>ERR_HTTP2_HEADERS_SENT</code></a></li> 817<li><a href="#err_http2_info_status_not_allowed"><code>ERR_HTTP2_INFO_STATUS_NOT_ALLOWED</code></a></li> 818<li><a href="#err_http2_invalid_connection_headers"><code>ERR_HTTP2_INVALID_CONNECTION_HEADERS</code></a></li> 819<li><a href="#err_http2_invalid_header_value"><code>ERR_HTTP2_INVALID_HEADER_VALUE</code></a></li> 820<li><a href="#err_http2_invalid_info_status"><code>ERR_HTTP2_INVALID_INFO_STATUS</code></a></li> 821<li><a href="#err_http2_invalid_origin"><code>ERR_HTTP2_INVALID_ORIGIN</code></a></li> 822<li><a href="#err_http2_invalid_packed_settings_length"><code>ERR_HTTP2_INVALID_PACKED_SETTINGS_LENGTH</code></a></li> 823<li><a href="#err_http2_invalid_pseudoheader"><code>ERR_HTTP2_INVALID_PSEUDOHEADER</code></a></li> 824<li><a href="#err_http2_invalid_session"><code>ERR_HTTP2_INVALID_SESSION</code></a></li> 825<li><a href="#err_http2_invalid_setting_value"><code>ERR_HTTP2_INVALID_SETTING_VALUE</code></a></li> 826<li><a href="#err_http2_invalid_stream"><code>ERR_HTTP2_INVALID_STREAM</code></a></li> 827<li><a href="#err_http2_max_pending_settings_ack"><code>ERR_HTTP2_MAX_PENDING_SETTINGS_ACK</code></a></li> 828<li><a href="#err_http2_nested_push"><code>ERR_HTTP2_NESTED_PUSH</code></a></li> 829<li><a href="#err_http2_no_mem"><code>ERR_HTTP2_NO_MEM</code></a></li> 830<li><a href="#err_http2_no_socket_manipulation"><code>ERR_HTTP2_NO_SOCKET_MANIPULATION</code></a></li> 831<li><a href="#err_http2_origin_length"><code>ERR_HTTP2_ORIGIN_LENGTH</code></a></li> 832<li><a href="#err_http2_out_of_streams"><code>ERR_HTTP2_OUT_OF_STREAMS</code></a></li> 833<li><a href="#err_http2_payload_forbidden"><code>ERR_HTTP2_PAYLOAD_FORBIDDEN</code></a></li> 834<li><a href="#err_http2_ping_cancel"><code>ERR_HTTP2_PING_CANCEL</code></a></li> 835<li><a href="#err_http2_ping_length"><code>ERR_HTTP2_PING_LENGTH</code></a></li> 836<li><a href="#err_http2_pseudoheader_not_allowed"><code>ERR_HTTP2_PSEUDOHEADER_NOT_ALLOWED</code></a></li> 837<li><a href="#err_http2_push_disabled"><code>ERR_HTTP2_PUSH_DISABLED</code></a></li> 838<li><a href="#err_http2_send_file"><code>ERR_HTTP2_SEND_FILE</code></a></li> 839<li><a href="#err_http2_send_file_noseek"><code>ERR_HTTP2_SEND_FILE_NOSEEK</code></a></li> 840<li><a href="#err_http2_session_error"><code>ERR_HTTP2_SESSION_ERROR</code></a></li> 841<li><a href="#err_http2_settings_cancel"><code>ERR_HTTP2_SETTINGS_CANCEL</code></a></li> 842<li><a href="#err_http2_socket_bound"><code>ERR_HTTP2_SOCKET_BOUND</code></a></li> 843<li><a href="#err_http2_socket_unbound"><code>ERR_HTTP2_SOCKET_UNBOUND</code></a></li> 844<li><a href="#err_http2_status_101"><code>ERR_HTTP2_STATUS_101</code></a></li> 845<li><a href="#err_http2_status_invalid"><code>ERR_HTTP2_STATUS_INVALID</code></a></li> 846<li><a href="#err_http2_stream_cancel"><code>ERR_HTTP2_STREAM_CANCEL</code></a></li> 847<li><a href="#err_http2_stream_error"><code>ERR_HTTP2_STREAM_ERROR</code></a></li> 848<li><a href="#err_http2_stream_self_dependency"><code>ERR_HTTP2_STREAM_SELF_DEPENDENCY</code></a></li> 849<li><a href="#err_http2_too_many_invalid_frames"><code>ERR_HTTP2_TOO_MANY_INVALID_FRAMES</code></a></li> 850<li><a href="#err_http2_trailers_already_sent"><code>ERR_HTTP2_TRAILERS_ALREADY_SENT</code></a></li> 851<li><a href="#err_http2_trailers_not_ready"><code>ERR_HTTP2_TRAILERS_NOT_READY</code></a></li> 852<li><a href="#err_http2_unsupported_protocol"><code>ERR_HTTP2_UNSUPPORTED_PROTOCOL</code></a></li> 853<li><a href="#err_illegal_constructor"><code>ERR_ILLEGAL_CONSTRUCTOR</code></a></li> 854<li><a href="#err_import_assertion_type_failed"><code>ERR_IMPORT_ASSERTION_TYPE_FAILED</code></a></li> 855<li><a href="#err_import_assertion_type_missing"><code>ERR_IMPORT_ASSERTION_TYPE_MISSING</code></a></li> 856<li><a href="#err_import_assertion_type_unsupported"><code>ERR_IMPORT_ASSERTION_TYPE_UNSUPPORTED</code></a></li> 857<li><a href="#err_incompatible_option_pair"><code>ERR_INCOMPATIBLE_OPTION_PAIR</code></a></li> 858<li><span class="stability_1"><a href="#err_input_type_not_allowed"><code>ERR_INPUT_TYPE_NOT_ALLOWED</code></a></span></li> 859<li><a href="#err_inspector_already_activated"><code>ERR_INSPECTOR_ALREADY_ACTIVATED</code></a></li> 860<li><a href="#err_inspector_already_connected"><code>ERR_INSPECTOR_ALREADY_CONNECTED</code></a></li> 861<li><a href="#err_inspector_closed"><code>ERR_INSPECTOR_CLOSED</code></a></li> 862<li><a href="#err_inspector_command"><code>ERR_INSPECTOR_COMMAND</code></a></li> 863<li><a href="#err_inspector_not_active"><code>ERR_INSPECTOR_NOT_ACTIVE</code></a></li> 864<li><a href="#err_inspector_not_available"><code>ERR_INSPECTOR_NOT_AVAILABLE</code></a></li> 865<li><a href="#err_inspector_not_connected"><code>ERR_INSPECTOR_NOT_CONNECTED</code></a></li> 866<li><a href="#err_inspector_not_worker"><code>ERR_INSPECTOR_NOT_WORKER</code></a></li> 867<li><a href="#err_internal_assertion"><code>ERR_INTERNAL_ASSERTION</code></a></li> 868<li><a href="#err_invalid_address_family"><code>ERR_INVALID_ADDRESS_FAMILY</code></a></li> 869<li><a href="#err_invalid_arg_type"><code>ERR_INVALID_ARG_TYPE</code></a></li> 870<li><a href="#err_invalid_arg_value"><code>ERR_INVALID_ARG_VALUE</code></a></li> 871<li><a href="#err_invalid_async_id"><code>ERR_INVALID_ASYNC_ID</code></a></li> 872<li><a href="#err_invalid_buffer_size"><code>ERR_INVALID_BUFFER_SIZE</code></a></li> 873<li><a href="#err_invalid_char"><code>ERR_INVALID_CHAR</code></a></li> 874<li><a href="#err_invalid_cursor_pos"><code>ERR_INVALID_CURSOR_POS</code></a></li> 875<li><a href="#err_invalid_fd"><code>ERR_INVALID_FD</code></a></li> 876<li><a href="#err_invalid_fd_type"><code>ERR_INVALID_FD_TYPE</code></a></li> 877<li><a href="#err_invalid_file_url_host"><code>ERR_INVALID_FILE_URL_HOST</code></a></li> 878<li><a href="#err_invalid_file_url_path"><code>ERR_INVALID_FILE_URL_PATH</code></a></li> 879<li><a href="#err_invalid_handle_type"><code>ERR_INVALID_HANDLE_TYPE</code></a></li> 880<li><a href="#err_invalid_http_token"><code>ERR_INVALID_HTTP_TOKEN</code></a></li> 881<li><a href="#err_invalid_ip_address"><code>ERR_INVALID_IP_ADDRESS</code></a></li> 882<li><a href="#err_invalid_mime_syntax"><code>ERR_INVALID_MIME_SYNTAX</code></a></li> 883<li><a href="#err_invalid_module"><code>ERR_INVALID_MODULE</code></a></li> 884<li><a href="#err_invalid_module_specifier"><code>ERR_INVALID_MODULE_SPECIFIER</code></a></li> 885<li><a href="#err_invalid_object_define_property"><code>ERR_INVALID_OBJECT_DEFINE_PROPERTY</code></a></li> 886<li><a href="#err_invalid_package_config"><code>ERR_INVALID_PACKAGE_CONFIG</code></a></li> 887<li><a href="#err_invalid_package_target"><code>ERR_INVALID_PACKAGE_TARGET</code></a></li> 888<li><a href="#err_invalid_performance_mark"><code>ERR_INVALID_PERFORMANCE_MARK</code></a></li> 889<li><a href="#err_invalid_protocol"><code>ERR_INVALID_PROTOCOL</code></a></li> 890<li><a href="#err_invalid_repl_eval_config"><code>ERR_INVALID_REPL_EVAL_CONFIG</code></a></li> 891<li><a href="#err_invalid_repl_input"><code>ERR_INVALID_REPL_INPUT</code></a></li> 892<li><a href="#err_invalid_return_property"><code>ERR_INVALID_RETURN_PROPERTY</code></a></li> 893<li><a href="#err_invalid_return_property_value"><code>ERR_INVALID_RETURN_PROPERTY_VALUE</code></a></li> 894<li><a href="#err_invalid_return_value"><code>ERR_INVALID_RETURN_VALUE</code></a></li> 895<li><a href="#err_invalid_state"><code>ERR_INVALID_STATE</code></a></li> 896<li><a href="#err_invalid_sync_fork_input"><code>ERR_INVALID_SYNC_FORK_INPUT</code></a></li> 897<li><a href="#err_invalid_this"><code>ERR_INVALID_THIS</code></a></li> 898<li><a href="#err_invalid_transfer_object"><code>ERR_INVALID_TRANSFER_OBJECT</code></a></li> 899<li><a href="#err_invalid_tuple"><code>ERR_INVALID_TUPLE</code></a></li> 900<li><a href="#err_invalid_uri"><code>ERR_INVALID_URI</code></a></li> 901<li><a href="#err_invalid_url"><code>ERR_INVALID_URL</code></a></li> 902<li><a href="#err_invalid_url_scheme"><code>ERR_INVALID_URL_SCHEME</code></a></li> 903<li><a href="#err_ipc_channel_closed"><code>ERR_IPC_CHANNEL_CLOSED</code></a></li> 904<li><a href="#err_ipc_disconnected"><code>ERR_IPC_DISCONNECTED</code></a></li> 905<li><a href="#err_ipc_one_pipe"><code>ERR_IPC_ONE_PIPE</code></a></li> 906<li><a href="#err_ipc_sync_fork"><code>ERR_IPC_SYNC_FORK</code></a></li> 907<li><a href="#err_loader_chain_incomplete"><code>ERR_LOADER_CHAIN_INCOMPLETE</code></a></li> 908<li><a href="#err_manifest_assert_integrity"><code>ERR_MANIFEST_ASSERT_INTEGRITY</code></a></li> 909<li><a href="#err_manifest_dependency_missing"><code>ERR_MANIFEST_DEPENDENCY_MISSING</code></a></li> 910<li><a href="#err_manifest_integrity_mismatch"><code>ERR_MANIFEST_INTEGRITY_MISMATCH</code></a></li> 911<li><a href="#err_manifest_invalid_resource_field"><code>ERR_MANIFEST_INVALID_RESOURCE_FIELD</code></a></li> 912<li><a href="#err_manifest_invalid_specifier"><code>ERR_MANIFEST_INVALID_SPECIFIER</code></a></li> 913<li><a href="#err_manifest_parse_policy"><code>ERR_MANIFEST_PARSE_POLICY</code></a></li> 914<li><a href="#err_manifest_tdz"><code>ERR_MANIFEST_TDZ</code></a></li> 915<li><a href="#err_manifest_unknown_onerror"><code>ERR_MANIFEST_UNKNOWN_ONERROR</code></a></li> 916<li><a href="#err_memory_allocation_failed"><code>ERR_MEMORY_ALLOCATION_FAILED</code></a></li> 917<li><a href="#err_message_target_context_unavailable"><code>ERR_MESSAGE_TARGET_CONTEXT_UNAVAILABLE</code></a></li> 918<li><a href="#err_method_not_implemented"><code>ERR_METHOD_NOT_IMPLEMENTED</code></a></li> 919<li><a href="#err_missing_args"><code>ERR_MISSING_ARGS</code></a></li> 920<li><a href="#err_missing_option"><code>ERR_MISSING_OPTION</code></a></li> 921<li><a href="#err_missing_passphrase"><code>ERR_MISSING_PASSPHRASE</code></a></li> 922<li><a href="#err_missing_platform_for_worker"><code>ERR_MISSING_PLATFORM_FOR_WORKER</code></a></li> 923<li><a href="#err_missing_transferable_in_transfer_list"><code>ERR_MISSING_TRANSFERABLE_IN_TRANSFER_LIST</code></a></li> 924<li><a href="#err_module_not_found"><code>ERR_MODULE_NOT_FOUND</code></a></li> 925<li><a href="#err_multiple_callback"><code>ERR_MULTIPLE_CALLBACK</code></a></li> 926<li><a href="#err_napi_cons_function"><code>ERR_NAPI_CONS_FUNCTION</code></a></li> 927<li><a href="#err_napi_invalid_dataview_args"><code>ERR_NAPI_INVALID_DATAVIEW_ARGS</code></a></li> 928<li><a href="#err_napi_invalid_typedarray_alignment"><code>ERR_NAPI_INVALID_TYPEDARRAY_ALIGNMENT</code></a></li> 929<li><a href="#err_napi_invalid_typedarray_length"><code>ERR_NAPI_INVALID_TYPEDARRAY_LENGTH</code></a></li> 930<li><a href="#err_napi_tsfn_call_js"><code>ERR_NAPI_TSFN_CALL_JS</code></a></li> 931<li><a href="#err_napi_tsfn_get_undefined"><code>ERR_NAPI_TSFN_GET_UNDEFINED</code></a></li> 932<li><a href="#err_napi_tsfn_start_idle_loop"><code>ERR_NAPI_TSFN_START_IDLE_LOOP</code></a></li> 933<li><a href="#err_napi_tsfn_stop_idle_loop"><code>ERR_NAPI_TSFN_STOP_IDLE_LOOP</code></a></li> 934<li><a href="#err_not_building_snapshot"><code>ERR_NOT_BUILDING_SNAPSHOT</code></a></li> 935<li><a href="#err_no_crypto"><code>ERR_NO_CRYPTO</code></a></li> 936<li><a href="#err_no_icu"><code>ERR_NO_ICU</code></a></li> 937<li><a href="#err_non_context_aware_disabled"><code>ERR_NON_CONTEXT_AWARE_DISABLED</code></a></li> 938<li><a href="#err_out_of_range"><code>ERR_OUT_OF_RANGE</code></a></li> 939<li><a href="#err_package_import_not_defined"><code>ERR_PACKAGE_IMPORT_NOT_DEFINED</code></a></li> 940<li><a href="#err_package_path_not_exported"><code>ERR_PACKAGE_PATH_NOT_EXPORTED</code></a></li> 941<li><a href="#err_parse_args_invalid_option_value"><code>ERR_PARSE_ARGS_INVALID_OPTION_VALUE</code></a></li> 942<li><a href="#err_parse_args_unexpected_positional"><code>ERR_PARSE_ARGS_UNEXPECTED_POSITIONAL</code></a></li> 943<li><a href="#err_parse_args_unknown_option"><code>ERR_PARSE_ARGS_UNKNOWN_OPTION</code></a></li> 944<li><a href="#err_performance_invalid_timestamp"><code>ERR_PERFORMANCE_INVALID_TIMESTAMP</code></a></li> 945<li><a href="#err_performance_measure_invalid_options"><code>ERR_PERFORMANCE_MEASURE_INVALID_OPTIONS</code></a></li> 946<li><a href="#err_proto_access"><code>ERR_PROTO_ACCESS</code></a></li> 947<li><span class="stability_1"><a href="#err_require_esm"><code>ERR_REQUIRE_ESM</code></a></span></li> 948<li><a href="#err_script_execution_interrupted"><code>ERR_SCRIPT_EXECUTION_INTERRUPTED</code></a></li> 949<li><a href="#err_script_execution_timeout"><code>ERR_SCRIPT_EXECUTION_TIMEOUT</code></a></li> 950<li><a href="#err_server_already_listen"><code>ERR_SERVER_ALREADY_LISTEN</code></a></li> 951<li><a href="#err_server_not_running"><code>ERR_SERVER_NOT_RUNNING</code></a></li> 952<li><a href="#err_socket_already_bound"><code>ERR_SOCKET_ALREADY_BOUND</code></a></li> 953<li><a href="#err_socket_bad_buffer_size"><code>ERR_SOCKET_BAD_BUFFER_SIZE</code></a></li> 954<li><a href="#err_socket_bad_port"><code>ERR_SOCKET_BAD_PORT</code></a></li> 955<li><a href="#err_socket_bad_type"><code>ERR_SOCKET_BAD_TYPE</code></a></li> 956<li><a href="#err_socket_buffer_size"><code>ERR_SOCKET_BUFFER_SIZE</code></a></li> 957<li><a href="#err_socket_closed"><code>ERR_SOCKET_CLOSED</code></a></li> 958<li><a href="#err_socket_closed_before_connection"><code>ERR_SOCKET_CLOSED_BEFORE_CONNECTION</code></a></li> 959<li><a href="#err_socket_dgram_is_connected"><code>ERR_SOCKET_DGRAM_IS_CONNECTED</code></a></li> 960<li><a href="#err_socket_dgram_not_connected"><code>ERR_SOCKET_DGRAM_NOT_CONNECTED</code></a></li> 961<li><a href="#err_socket_dgram_not_running"><code>ERR_SOCKET_DGRAM_NOT_RUNNING</code></a></li> 962<li><a href="#err_sri_parse"><code>ERR_SRI_PARSE</code></a></li> 963<li><a href="#err_stream_already_finished"><code>ERR_STREAM_ALREADY_FINISHED</code></a></li> 964<li><a href="#err_stream_cannot_pipe"><code>ERR_STREAM_CANNOT_PIPE</code></a></li> 965<li><a href="#err_stream_destroyed"><code>ERR_STREAM_DESTROYED</code></a></li> 966<li><a href="#err_stream_null_values"><code>ERR_STREAM_NULL_VALUES</code></a></li> 967<li><a href="#err_stream_premature_close"><code>ERR_STREAM_PREMATURE_CLOSE</code></a></li> 968<li><a href="#err_stream_push_after_eof"><code>ERR_STREAM_PUSH_AFTER_EOF</code></a></li> 969<li><a href="#err_stream_unshift_after_end_event"><code>ERR_STREAM_UNSHIFT_AFTER_END_EVENT</code></a></li> 970<li><a href="#err_stream_wrap"><code>ERR_STREAM_WRAP</code></a></li> 971<li><a href="#err_stream_write_after_end"><code>ERR_STREAM_WRITE_AFTER_END</code></a></li> 972<li><a href="#err_string_too_long"><code>ERR_STRING_TOO_LONG</code></a></li> 973<li><a href="#err_synthetic"><code>ERR_SYNTHETIC</code></a></li> 974<li><a href="#err_system_error"><code>ERR_SYSTEM_ERROR</code></a></li> 975<li><a href="#err_tap_lexer_error"><code>ERR_TAP_LEXER_ERROR</code></a></li> 976<li><a href="#err_tap_parser_error"><code>ERR_TAP_PARSER_ERROR</code></a></li> 977<li><a href="#err_tap_validation_error"><code>ERR_TAP_VALIDATION_ERROR</code></a></li> 978<li><a href="#err_test_failure"><code>ERR_TEST_FAILURE</code></a></li> 979<li><a href="#err_tls_cert_altname_format"><code>ERR_TLS_CERT_ALTNAME_FORMAT</code></a></li> 980<li><a href="#err_tls_cert_altname_invalid"><code>ERR_TLS_CERT_ALTNAME_INVALID</code></a></li> 981<li><a href="#err_tls_dh_param_size"><code>ERR_TLS_DH_PARAM_SIZE</code></a></li> 982<li><a href="#err_tls_handshake_timeout"><code>ERR_TLS_HANDSHAKE_TIMEOUT</code></a></li> 983<li><a href="#err_tls_invalid_context"><code>ERR_TLS_INVALID_CONTEXT</code></a></li> 984<li><a href="#err_tls_invalid_protocol_method"><code>ERR_TLS_INVALID_PROTOCOL_METHOD</code></a></li> 985<li><a href="#err_tls_invalid_protocol_version"><code>ERR_TLS_INVALID_PROTOCOL_VERSION</code></a></li> 986<li><a href="#err_tls_invalid_state"><code>ERR_TLS_INVALID_STATE</code></a></li> 987<li><a href="#err_tls_protocol_version_conflict"><code>ERR_TLS_PROTOCOL_VERSION_CONFLICT</code></a></li> 988<li><a href="#err_tls_psk_set_identiy_hint_failed"><code>ERR_TLS_PSK_SET_IDENTIY_HINT_FAILED</code></a></li> 989<li><a href="#err_tls_renegotiation_disabled"><code>ERR_TLS_RENEGOTIATION_DISABLED</code></a></li> 990<li><a href="#err_tls_required_server_name"><code>ERR_TLS_REQUIRED_SERVER_NAME</code></a></li> 991<li><a href="#err_tls_session_attack"><code>ERR_TLS_SESSION_ATTACK</code></a></li> 992<li><a href="#err_tls_sni_from_server"><code>ERR_TLS_SNI_FROM_SERVER</code></a></li> 993<li><a href="#err_trace_events_category_required"><code>ERR_TRACE_EVENTS_CATEGORY_REQUIRED</code></a></li> 994<li><a href="#err_trace_events_unavailable"><code>ERR_TRACE_EVENTS_UNAVAILABLE</code></a></li> 995<li><a href="#err_transform_already_transforming"><code>ERR_TRANSFORM_ALREADY_TRANSFORMING</code></a></li> 996<li><a href="#err_transform_with_length_0"><code>ERR_TRANSFORM_WITH_LENGTH_0</code></a></li> 997<li><a href="#err_tty_init_failed"><code>ERR_TTY_INIT_FAILED</code></a></li> 998<li><a href="#err_unavailable_during_exit"><code>ERR_UNAVAILABLE_DURING_EXIT</code></a></li> 999<li><a href="#err_uncaught_exception_capture_already_set"><code>ERR_UNCAUGHT_EXCEPTION_CAPTURE_ALREADY_SET</code></a></li> 1000<li><a href="#err_unescaped_characters"><code>ERR_UNESCAPED_CHARACTERS</code></a></li> 1001<li><a href="#err_unhandled_error"><code>ERR_UNHANDLED_ERROR</code></a></li> 1002<li><a href="#err_unknown_builtin_module"><code>ERR_UNKNOWN_BUILTIN_MODULE</code></a></li> 1003<li><a href="#err_unknown_credential"><code>ERR_UNKNOWN_CREDENTIAL</code></a></li> 1004<li><a href="#err_unknown_encoding"><code>ERR_UNKNOWN_ENCODING</code></a></li> 1005<li><span class="stability_1"><a href="#err_unknown_file_extension"><code>ERR_UNKNOWN_FILE_EXTENSION</code></a></span></li> 1006<li><span class="stability_1"><a href="#err_unknown_module_format"><code>ERR_UNKNOWN_MODULE_FORMAT</code></a></span></li> 1007<li><a href="#err_unknown_signal"><code>ERR_UNKNOWN_SIGNAL</code></a></li> 1008<li><a href="#err_unsupported_dir_import"><code>ERR_UNSUPPORTED_DIR_IMPORT</code></a></li> 1009<li><a href="#err_unsupported_esm_url_scheme"><code>ERR_UNSUPPORTED_ESM_URL_SCHEME</code></a></li> 1010<li><span class="stability_1"><a href="#err_use_after_close"><code>ERR_USE_AFTER_CLOSE</code></a></span></li> 1011<li><a href="#err_valid_performance_entry_type"><code>ERR_VALID_PERFORMANCE_ENTRY_TYPE</code></a></li> 1012<li><a href="#err_vm_dynamic_import_callback_missing"><code>ERR_VM_DYNAMIC_IMPORT_CALLBACK_MISSING</code></a></li> 1013<li><a href="#err_vm_module_already_linked"><code>ERR_VM_MODULE_ALREADY_LINKED</code></a></li> 1014<li><a href="#err_vm_module_cached_data_rejected"><code>ERR_VM_MODULE_CACHED_DATA_REJECTED</code></a></li> 1015<li><a href="#err_vm_module_cannot_create_cached_data"><code>ERR_VM_MODULE_CANNOT_CREATE_CACHED_DATA</code></a></li> 1016<li><a href="#err_vm_module_different_context"><code>ERR_VM_MODULE_DIFFERENT_CONTEXT</code></a></li> 1017<li><a href="#err_vm_module_link_failure"><code>ERR_VM_MODULE_LINK_FAILURE</code></a></li> 1018<li><a href="#err_vm_module_not_module"><code>ERR_VM_MODULE_NOT_MODULE</code></a></li> 1019<li><a href="#err_vm_module_status"><code>ERR_VM_MODULE_STATUS</code></a></li> 1020<li><a href="#err_wasi_already_started"><code>ERR_WASI_ALREADY_STARTED</code></a></li> 1021<li><a href="#err_wasi_not_started"><code>ERR_WASI_NOT_STARTED</code></a></li> 1022<li><a href="#err_webassembly_response"><code>ERR_WEBASSEMBLY_RESPONSE</code></a></li> 1023<li><a href="#err_worker_init_failed"><code>ERR_WORKER_INIT_FAILED</code></a></li> 1024<li><a href="#err_worker_invalid_exec_argv"><code>ERR_WORKER_INVALID_EXEC_ARGV</code></a></li> 1025<li><a href="#err_worker_not_running"><code>ERR_WORKER_NOT_RUNNING</code></a></li> 1026<li><a href="#err_worker_out_of_memory"><code>ERR_WORKER_OUT_OF_MEMORY</code></a></li> 1027<li><a href="#err_worker_path"><code>ERR_WORKER_PATH</code></a></li> 1028<li><a href="#err_worker_unserializable_error"><code>ERR_WORKER_UNSERIALIZABLE_ERROR</code></a></li> 1029<li><a href="#err_worker_unsupported_operation"><code>ERR_WORKER_UNSUPPORTED_OPERATION</code></a></li> 1030<li><a href="#err_zlib_initialization_failed"><code>ERR_ZLIB_INITIALIZATION_FAILED</code></a></li> 1031<li><a href="#hpe_header_overflow"><code>HPE_HEADER_OVERFLOW</code></a></li> 1032<li><a href="#hpe_unexpected_content_length"><code>HPE_UNEXPECTED_CONTENT_LENGTH</code></a></li> 1033<li><a href="#module_not_found"><code>MODULE_NOT_FOUND</code></a></li> 1034</ul> 1035</li> 1036<li><span class="stability_0"><a href="#legacy-nodejs-error-codes">Legacy Node.js error codes</a></span> 1037<ul> 1038<li><a href="#err_cannot_transfer_object"><code>ERR_CANNOT_TRANSFER_OBJECT</code></a></li> 1039<li><a href="#err_crypto_hash_digest_no_utf16"><code>ERR_CRYPTO_HASH_DIGEST_NO_UTF16</code></a></li> 1040<li><a href="#err_http2_frame_error"><code>ERR_HTTP2_FRAME_ERROR</code></a></li> 1041<li><a href="#err_http2_headers_object"><code>ERR_HTTP2_HEADERS_OBJECT</code></a></li> 1042<li><a href="#err_http2_header_required"><code>ERR_HTTP2_HEADER_REQUIRED</code></a></li> 1043<li><a href="#err_http2_info_headers_after_respond"><code>ERR_HTTP2_INFO_HEADERS_AFTER_RESPOND</code></a></li> 1044<li><a href="#err_http2_stream_closed"><code>ERR_HTTP2_STREAM_CLOSED</code></a></li> 1045<li><a href="#err_http_invalid_char"><code>ERR_HTTP_INVALID_CHAR</code></a></li> 1046<li><a href="#err_index_out_of_range"><code>ERR_INDEX_OUT_OF_RANGE</code></a></li> 1047<li><a href="#err_invalid_opt_value"><code>ERR_INVALID_OPT_VALUE</code></a></li> 1048<li><a href="#err_invalid_opt_value_encoding"><code>ERR_INVALID_OPT_VALUE_ENCODING</code></a></li> 1049<li><a href="#err_missing_message_port_in_transfer_list"><code>ERR_MISSING_MESSAGE_PORT_IN_TRANSFER_LIST</code></a></li> 1050<li><a href="#err_napi_cons_prototype_object"><code>ERR_NAPI_CONS_PROTOTYPE_OBJECT</code></a></li> 1051<li><span class="stability_1"><a href="#err_network_import_bad_response"><code>ERR_NETWORK_IMPORT_BAD_RESPONSE</code></a></span></li> 1052<li><span class="stability_1"><a href="#err_network_import_disallowed"><code>ERR_NETWORK_IMPORT_DISALLOWED</code></a></span></li> 1053<li><a href="#err_no_longer_supported"><code>ERR_NO_LONGER_SUPPORTED</code></a></li> 1054<li><a href="#err_operation_failed"><code>ERR_OPERATION_FAILED</code></a></li> 1055<li><a href="#err_outofmemory"><code>ERR_OUTOFMEMORY</code></a></li> 1056<li><a href="#err_parse_history_data"><code>ERR_PARSE_HISTORY_DATA</code></a></li> 1057<li><a href="#err_socket_cannot_send"><code>ERR_SOCKET_CANNOT_SEND</code></a></li> 1058<li><a href="#err_stderr_close"><code>ERR_STDERR_CLOSE</code></a></li> 1059<li><a href="#err_stdout_close"><code>ERR_STDOUT_CLOSE</code></a></li> 1060<li><a href="#err_stream_read_not_implemented"><code>ERR_STREAM_READ_NOT_IMPLEMENTED</code></a></li> 1061<li><a href="#err_tls_renegotiation_failed"><code>ERR_TLS_RENEGOTIATION_FAILED</code></a></li> 1062<li><a href="#err_transferring_externalized_sharedarraybuffer"><code>ERR_TRANSFERRING_EXTERNALIZED_SHAREDARRAYBUFFER</code></a></li> 1063<li><a href="#err_unknown_stdin_type"><code>ERR_UNKNOWN_STDIN_TYPE</code></a></li> 1064<li><a href="#err_unknown_stream_type"><code>ERR_UNKNOWN_STREAM_TYPE</code></a></li> 1065<li><a href="#err_v8breakiterator"><code>ERR_V8BREAKITERATOR</code></a></li> 1066<li><a href="#err_value_out_of_range"><code>ERR_VALUE_OUT_OF_RANGE</code></a></li> 1067<li><a href="#err_vm_module_not_linked"><code>ERR_VM_MODULE_NOT_LINKED</code></a></li> 1068<li><a href="#err_vm_module_linking_errored"><code>ERR_VM_MODULE_LINKING_ERRORED</code></a></li> 1069<li><a href="#err_worker_unsupported_extension"><code>ERR_WORKER_UNSUPPORTED_EXTENSION</code></a></li> 1070<li><a href="#err_zlib_binding_closed"><code>ERR_ZLIB_BINDING_CLOSED</code></a></li> 1071<li><a href="#err_cpu_usage"><code>ERR_CPU_USAGE</code></a></li> 1072</ul> 1073</li> 1074</ul> 1075</li> 1076</ul></details> 1077 1078 <div id="apicontent"> 1079 <h2>Errors<span><a class="mark" href="#errors" id="errors">#</a></span><a aria-hidden="true" class="legacy" id="errors_errors"></a></h2> 1080 1081 1082<p>Applications running in Node.js will generally experience four categories of 1083errors:</p> 1084<ul> 1085<li>Standard JavaScript errors such as <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/EvalError" class="type"><EvalError></a>, <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/SyntaxError" class="type"><SyntaxError></a>, <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/RangeError" class="type"><RangeError></a>, 1086<a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ReferenceError" class="type"><ReferenceError></a>, <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypeError" class="type"><TypeError></a>, and <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/URIError" class="type"><URIError></a>.</li> 1087<li>System errors triggered by underlying operating system constraints such 1088as attempting to open a file that does not exist or attempting to send data 1089over a closed socket.</li> 1090<li>User-specified errors triggered by application code.</li> 1091<li><code>AssertionError</code>s are a special class of error that can be triggered when 1092Node.js detects an exceptional logic violation that should never occur. These 1093are raised typically by the <code>node:assert</code> module.</li> 1094</ul> 1095<p>All JavaScript and system errors raised by Node.js inherit from, or are 1096instances of, the standard JavaScript <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error" class="type"><Error></a> class and are guaranteed 1097to provide <em>at least</em> the properties available on that class.</p> 1098<section><h3>Error propagation and interception<span><a class="mark" href="#error-propagation-and-interception" id="error-propagation-and-interception">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_propagation_and_interception"></a></h3> 1099 1100<p>Node.js supports several mechanisms for propagating and handling errors that 1101occur while an application is running. How these errors are reported and 1102handled depends entirely on the type of <code>Error</code> and the style of the API that is 1103called.</p> 1104<p>All JavaScript errors are handled as exceptions that <em>immediately</em> generate 1105and throw an error using the standard JavaScript <code>throw</code> mechanism. These 1106are handled using the <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/try...catch"><code>try…catch</code> construct</a> provided by the 1107JavaScript language.</p> 1108<pre><code class="language-js"><span class="hljs-comment">// Throws with a ReferenceError because z is not defined.</span> 1109<span class="hljs-keyword">try</span> { 1110 <span class="hljs-keyword">const</span> m = <span class="hljs-number">1</span>; 1111 <span class="hljs-keyword">const</span> n = m + z; 1112} <span class="hljs-keyword">catch</span> (err) { 1113 <span class="hljs-comment">// Handle the error here.</span> 1114}</code> <button class="copy-button">copy</button></pre> 1115<p>Any use of the JavaScript <code>throw</code> mechanism will raise an exception that 1116<em>must</em> be handled or the Node.js process will exit immediately.</p> 1117<p>With few exceptions, <em>Synchronous</em> APIs (any blocking method that does not 1118return a <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise" class="type"><Promise></a> nor accept a <code>callback</code> function, such as 1119<a href="fs.html#fsreadfilesyncpath-options"><code>fs.readFileSync</code></a>), will use <code>throw</code> to report errors.</p> 1120<p>Errors that occur within <em>Asynchronous APIs</em> may be reported in multiple ways:</p> 1121<ul> 1122<li> 1123<p>Some asynchronous methods returns a <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise" class="type"><Promise></a>, you should always take into 1124account that it might be rejected. See <a href="cli.html#--unhandled-rejectionsmode"><code>--unhandled-rejections</code></a> flag for 1125how the process will react to an unhandled promise rejection.</p> 1126<!-- eslint-disable no-useless-return --> 1127<pre><code class="language-js"><span class="hljs-keyword">const</span> fs = <span class="hljs-built_in">require</span>(<span class="hljs-string">'fs/promises'</span>); 1128 1129(<span class="hljs-keyword">async</span> () => { 1130 <span class="hljs-keyword">let</span> data; 1131 <span class="hljs-keyword">try</span> { 1132 data = <span class="hljs-keyword">await</span> fs.<span class="hljs-title function_">readFile</span>(<span class="hljs-string">'a file that does not exist'</span>); 1133 } <span class="hljs-keyword">catch</span> (err) { 1134 <span class="hljs-variable language_">console</span>.<span class="hljs-title function_">error</span>(<span class="hljs-string">'There was an error reading the file!'</span>, err); 1135 <span class="hljs-keyword">return</span>; 1136 } 1137 <span class="hljs-comment">// Otherwise handle the data</span> 1138})();</code> <button class="copy-button">copy</button></pre> 1139</li> 1140<li> 1141<p>Most asynchronous methods that accept a <code>callback</code> function will accept an 1142<code>Error</code> object passed as the first argument to that function. If that first 1143argument is not <code>null</code> and is an instance of <code>Error</code>, then an error occurred 1144that should be handled.</p> 1145<!-- eslint-disable no-useless-return --> 1146<pre><code class="language-js"><span class="hljs-keyword">const</span> fs = <span class="hljs-built_in">require</span>(<span class="hljs-string">'node:fs'</span>); 1147fs.<span class="hljs-title function_">readFile</span>(<span class="hljs-string">'a file that does not exist'</span>, <span class="hljs-function">(<span class="hljs-params">err, data</span>) =></span> { 1148 <span class="hljs-keyword">if</span> (err) { 1149 <span class="hljs-variable language_">console</span>.<span class="hljs-title function_">error</span>(<span class="hljs-string">'There was an error reading the file!'</span>, err); 1150 <span class="hljs-keyword">return</span>; 1151 } 1152 <span class="hljs-comment">// Otherwise handle the data</span> 1153});</code> <button class="copy-button">copy</button></pre> 1154</li> 1155<li> 1156<p>When an asynchronous method is called on an object that is an 1157<a href="events.html#class-eventemitter"><code>EventEmitter</code></a>, errors can be routed to that object's <code>'error'</code> event.</p> 1158<pre><code class="language-js"><span class="hljs-keyword">const</span> net = <span class="hljs-built_in">require</span>(<span class="hljs-string">'node:net'</span>); 1159<span class="hljs-keyword">const</span> connection = net.<span class="hljs-title function_">connect</span>(<span class="hljs-string">'localhost'</span>); 1160 1161<span class="hljs-comment">// Adding an 'error' event handler to a stream:</span> 1162connection.<span class="hljs-title function_">on</span>(<span class="hljs-string">'error'</span>, <span class="hljs-function">(<span class="hljs-params">err</span>) =></span> { 1163 <span class="hljs-comment">// If the connection is reset by the server, or if it can't</span> 1164 <span class="hljs-comment">// connect at all, or on any sort of error encountered by</span> 1165 <span class="hljs-comment">// the connection, the error will be sent here.</span> 1166 <span class="hljs-variable language_">console</span>.<span class="hljs-title function_">error</span>(err); 1167}); 1168 1169connection.<span class="hljs-title function_">pipe</span>(process.<span class="hljs-property">stdout</span>);</code> <button class="copy-button">copy</button></pre> 1170</li> 1171<li> 1172<p>A handful of typically asynchronous methods in the Node.js API may still 1173use the <code>throw</code> mechanism to raise exceptions that must be handled using 1174<code>try…catch</code>. There is no comprehensive list of such methods; please 1175refer to the documentation of each method to determine the appropriate 1176error handling mechanism required.</p> 1177</li> 1178</ul> 1179<p>The use of the <code>'error'</code> event mechanism is most common for <a href="stream.html">stream-based</a> 1180and <a href="events.html#class-eventemitter">event emitter-based</a> APIs, which themselves represent a series of 1181asynchronous operations over time (as opposed to a single operation that may 1182pass or fail).</p> 1183<p>For <em>all</em> <a href="events.html#class-eventemitter"><code>EventEmitter</code></a> objects, if an <code>'error'</code> event handler is not 1184provided, the error will be thrown, causing the Node.js process to report an 1185uncaught exception and crash unless either: a handler has been registered for 1186the <a href="process.html#event-uncaughtexception"><code>'uncaughtException'</code></a> event, or the deprecated <a href="domain.html"><code>node:domain</code></a> 1187module is used.</p> 1188<pre><code class="language-js"><span class="hljs-keyword">const</span> <span class="hljs-title class_">EventEmitter</span> = <span class="hljs-built_in">require</span>(<span class="hljs-string">'node:events'</span>); 1189<span class="hljs-keyword">const</span> ee = <span class="hljs-keyword">new</span> <span class="hljs-title class_">EventEmitter</span>(); 1190 1191<span class="hljs-title function_">setImmediate</span>(<span class="hljs-function">() =></span> { 1192 <span class="hljs-comment">// This will crash the process because no 'error' event</span> 1193 <span class="hljs-comment">// handler has been added.</span> 1194 ee.<span class="hljs-title function_">emit</span>(<span class="hljs-string">'error'</span>, <span class="hljs-keyword">new</span> <span class="hljs-title class_">Error</span>(<span class="hljs-string">'This will crash'</span>)); 1195});</code> <button class="copy-button">copy</button></pre> 1196<p>Errors generated in this way <em>cannot</em> be intercepted using <code>try…catch</code> as 1197they are thrown <em>after</em> the calling code has already exited.</p> 1198<p>Developers must refer to the documentation for each method to determine 1199exactly how errors raised by those methods are propagated.</p> 1200</section><section><h3>Class: <code>Error</code><span><a class="mark" href="#class-error" id="class-error">#</a></span><a aria-hidden="true" class="legacy" id="errors_class_error"></a></h3> 1201 1202<p>A generic JavaScript <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error" class="type"><Error></a> object that does not denote any specific 1203circumstance of why the error occurred. <code>Error</code> objects capture a "stack trace" 1204detailing the point in the code at which the <code>Error</code> was instantiated, and may 1205provide a text description of the error.</p> 1206<p>All errors generated by Node.js, including all system and JavaScript errors, 1207will either be instances of, or inherit from, the <code>Error</code> class.</p> 1208<h4><code>new Error(message[, options])</code><span><a class="mark" href="#new-errormessage-options" id="new-errormessage-options">#</a></span><a aria-hidden="true" class="legacy" id="errors_new_error_message_options"></a></h4> 1209<ul> 1210<li><code>message</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a></li> 1211<li><code>options</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object" class="type"><Object></a> 1212<ul> 1213<li><code>cause</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Data_types" class="type"><any></a> The error that caused the newly created error.</li> 1214</ul> 1215</li> 1216</ul> 1217<p>Creates a new <code>Error</code> object and sets the <code>error.message</code> property to the 1218provided text message. If an object is passed as <code>message</code>, the text message 1219is generated by calling <code>String(message)</code>. If the <code>cause</code> option is provided, 1220it is assigned to the <code>error.cause</code> property. The <code>error.stack</code> property will 1221represent the point in the code at which <code>new Error()</code> was called. Stack traces 1222are dependent on <a href="https://v8.dev/docs/stack-trace-api">V8's stack trace API</a>. Stack traces extend only to either 1223(a) the beginning of <em>synchronous code execution</em>, or (b) the number of frames 1224given by the property <code>Error.stackTraceLimit</code>, whichever is smaller.</p> 1225<h4><code>Error.captureStackTrace(targetObject[, constructorOpt])</code><span><a class="mark" href="#errorcapturestacktracetargetobject-constructoropt" id="errorcapturestacktracetargetobject-constructoropt">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_capturestacktrace_targetobject_constructoropt"></a></h4> 1226<ul> 1227<li><code>targetObject</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object" class="type"><Object></a></li> 1228<li><code>constructorOpt</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function" class="type"><Function></a></li> 1229</ul> 1230<p>Creates a <code>.stack</code> property on <code>targetObject</code>, which when accessed returns 1231a string representing the location in the code at which 1232<code>Error.captureStackTrace()</code> was called.</p> 1233<pre><code class="language-js"><span class="hljs-keyword">const</span> myObject = {}; 1234<span class="hljs-title class_">Error</span>.<span class="hljs-title function_">captureStackTrace</span>(myObject); 1235myObject.<span class="hljs-property">stack</span>; <span class="hljs-comment">// Similar to `new Error().stack`</span></code> <button class="copy-button">copy</button></pre> 1236<p>The first line of the trace will be prefixed with 1237<code>${myObject.name}: ${myObject.message}</code>.</p> 1238<p>The optional <code>constructorOpt</code> argument accepts a function. If given, all frames 1239above <code>constructorOpt</code>, including <code>constructorOpt</code>, will be omitted from the 1240generated stack trace.</p> 1241<p>The <code>constructorOpt</code> argument is useful for hiding implementation 1242details of error generation from the user. For instance:</p> 1243<pre><code class="language-js"><span class="hljs-keyword">function</span> <span class="hljs-title function_">a</span>(<span class="hljs-params"></span>) { 1244 <span class="hljs-title function_">b</span>(); 1245} 1246 1247<span class="hljs-keyword">function</span> <span class="hljs-title function_">b</span>(<span class="hljs-params"></span>) { 1248 <span class="hljs-title function_">c</span>(); 1249} 1250 1251<span class="hljs-keyword">function</span> <span class="hljs-title function_">c</span>(<span class="hljs-params"></span>) { 1252 <span class="hljs-comment">// Create an error without stack trace to avoid calculating the stack trace twice.</span> 1253 <span class="hljs-keyword">const</span> { stackTraceLimit } = <span class="hljs-title class_">Error</span>; 1254 <span class="hljs-title class_">Error</span>.<span class="hljs-property">stackTraceLimit</span> = <span class="hljs-number">0</span>; 1255 <span class="hljs-keyword">const</span> error = <span class="hljs-keyword">new</span> <span class="hljs-title class_">Error</span>(); 1256 <span class="hljs-title class_">Error</span>.<span class="hljs-property">stackTraceLimit</span> = stackTraceLimit; 1257 1258 <span class="hljs-comment">// Capture the stack trace above function b</span> 1259 <span class="hljs-title class_">Error</span>.<span class="hljs-title function_">captureStackTrace</span>(error, b); <span class="hljs-comment">// Neither function c, nor b is included in the stack trace</span> 1260 <span class="hljs-keyword">throw</span> error; 1261} 1262 1263<span class="hljs-title function_">a</span>();</code> <button class="copy-button">copy</button></pre> 1264<h4><code>Error.stackTraceLimit</code><span><a class="mark" href="#errorstacktracelimit" id="errorstacktracelimit">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_stacktracelimit"></a></h4> 1265<ul> 1266<li><a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type"><number></a></li> 1267</ul> 1268<p>The <code>Error.stackTraceLimit</code> property specifies the number of stack frames 1269collected by a stack trace (whether generated by <code>new Error().stack</code> or 1270<code>Error.captureStackTrace(obj)</code>).</p> 1271<p>The default value is <code>10</code> but may be set to any valid JavaScript number. Changes 1272will affect any stack trace captured <em>after</em> the value has been changed.</p> 1273<p>If set to a non-number value, or set to a negative number, stack traces will 1274not capture any frames.</p> 1275<h4><code>error.cause</code><span><a class="mark" href="#errorcause" id="errorcause">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_cause"></a></h4> 1276<div class="api_metadata"> 1277<span>Added in: v16.9.0</span> 1278</div> 1279<ul> 1280<li><a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Data_types" class="type"><any></a></li> 1281</ul> 1282<p>If present, the <code>error.cause</code> property is the underlying cause of the <code>Error</code>. 1283It is used when catching an error and throwing a new one with a different 1284message or code in order to still have access to the original error.</p> 1285<p>The <code>error.cause</code> property is typically set by calling 1286<code>new Error(message, { cause })</code>. It is not set by the constructor if the 1287<code>cause</code> option is not provided.</p> 1288<p>This property allows errors to be chained. When serializing <code>Error</code> objects, 1289<a href="util.html#utilinspectobject-options"><code>util.inspect()</code></a> recursively serializes <code>error.cause</code> if it is set.</p> 1290<pre><code class="language-js"><span class="hljs-keyword">const</span> cause = <span class="hljs-keyword">new</span> <span class="hljs-title class_">Error</span>(<span class="hljs-string">'The remote HTTP server responded with a 500 status'</span>); 1291<span class="hljs-keyword">const</span> symptom = <span class="hljs-keyword">new</span> <span class="hljs-title class_">Error</span>(<span class="hljs-string">'The message failed to send'</span>, { cause }); 1292 1293<span class="hljs-variable language_">console</span>.<span class="hljs-title function_">log</span>(symptom); 1294<span class="hljs-comment">// Prints:</span> 1295<span class="hljs-comment">// Error: The message failed to send</span> 1296<span class="hljs-comment">// at REPL2:1:17</span> 1297<span class="hljs-comment">// at Script.runInThisContext (node:vm:130:12)</span> 1298<span class="hljs-comment">// ... 7 lines matching cause stack trace ...</span> 1299<span class="hljs-comment">// at [_line] [as _line] (node:internal/readline/interface:886:18) {</span> 1300<span class="hljs-comment">// [cause]: Error: The remote HTTP server responded with a 500 status</span> 1301<span class="hljs-comment">// at REPL1:1:15</span> 1302<span class="hljs-comment">// at Script.runInThisContext (node:vm:130:12)</span> 1303<span class="hljs-comment">// at REPLServer.defaultEval (node:repl:574:29)</span> 1304<span class="hljs-comment">// at bound (node:domain:426:15)</span> 1305<span class="hljs-comment">// at REPLServer.runBound [as eval] (node:domain:437:12)</span> 1306<span class="hljs-comment">// at REPLServer.onLine (node:repl:902:10)</span> 1307<span class="hljs-comment">// at REPLServer.emit (node:events:549:35)</span> 1308<span class="hljs-comment">// at REPLServer.emit (node:domain:482:12)</span> 1309<span class="hljs-comment">// at [_onLine] [as _onLine] (node:internal/readline/interface:425:12)</span> 1310<span class="hljs-comment">// at [_line] [as _line] (node:internal/readline/interface:886:18)</span></code> <button class="copy-button">copy</button></pre> 1311<h4><code>error.code</code><span><a class="mark" href="#errorcode" id="errorcode">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_code"></a></h4> 1312<ul> 1313<li><a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a></li> 1314</ul> 1315<p>The <code>error.code</code> property is a string label that identifies the kind of error. 1316<code>error.code</code> is the most stable way to identify an error. It will only change 1317between major versions of Node.js. In contrast, <code>error.message</code> strings may 1318change between any versions of Node.js. See <a href="#nodejs-error-codes">Node.js error codes</a> for details 1319about specific codes.</p> 1320<h4><code>error.message</code><span><a class="mark" href="#errormessage" id="errormessage">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_message"></a></h4> 1321<ul> 1322<li><a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a></li> 1323</ul> 1324<p>The <code>error.message</code> property is the string description of the error as set by 1325calling <code>new Error(message)</code>. The <code>message</code> passed to the constructor will also 1326appear in the first line of the stack trace of the <code>Error</code>, however changing 1327this property after the <code>Error</code> object is created <em>may not</em> change the first 1328line of the stack trace (for example, when <code>error.stack</code> is read before this 1329property is changed).</p> 1330<pre><code class="language-js"><span class="hljs-keyword">const</span> err = <span class="hljs-keyword">new</span> <span class="hljs-title class_">Error</span>(<span class="hljs-string">'The message'</span>); 1331<span class="hljs-variable language_">console</span>.<span class="hljs-title function_">error</span>(err.<span class="hljs-property">message</span>); 1332<span class="hljs-comment">// Prints: The message</span></code> <button class="copy-button">copy</button></pre> 1333<h4><code>error.stack</code><span><a class="mark" href="#errorstack" id="errorstack">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_stack"></a></h4> 1334<ul> 1335<li><a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a></li> 1336</ul> 1337<p>The <code>error.stack</code> property is a string describing the point in the code at which 1338the <code>Error</code> was instantiated.</p> 1339<pre><code class="language-console">Error: Things keep happening! 1340 at /home/gbusey/file.js:525:2 1341 at Frobnicator.refrobulate (/home/gbusey/business-logic.js:424:21) 1342 at Actor.<anonymous> (/home/gbusey/actors.js:400:8) 1343 at increaseSynergy (/home/gbusey/actors.js:701:6)</code> <button class="copy-button">copy</button></pre> 1344<p>The first line is formatted as <code><error class name>: <error message></code>, and 1345is followed by a series of stack frames (each line beginning with "at "). 1346Each frame describes a call site within the code that lead to the error being 1347generated. V8 attempts to display a name for each function (by variable name, 1348function name, or object method name), but occasionally it will not be able to 1349find a suitable name. If V8 cannot determine a name for the function, only 1350location information will be displayed for that frame. Otherwise, the 1351determined function name will be displayed with location information appended 1352in parentheses.</p> 1353<p>Frames are only generated for JavaScript functions. If, for example, execution 1354synchronously passes through a C++ addon function called <code>cheetahify</code> which 1355itself calls a JavaScript function, the frame representing the <code>cheetahify</code> call 1356will not be present in the stack traces:</p> 1357<pre><code class="language-js"><span class="hljs-keyword">const</span> cheetahify = <span class="hljs-built_in">require</span>(<span class="hljs-string">'./native-binding.node'</span>); 1358 1359<span class="hljs-keyword">function</span> <span class="hljs-title function_">makeFaster</span>(<span class="hljs-params"></span>) { 1360 <span class="hljs-comment">// `cheetahify()` *synchronously* calls speedy.</span> 1361 <span class="hljs-title function_">cheetahify</span>(<span class="hljs-keyword">function</span> <span class="hljs-title function_">speedy</span>(<span class="hljs-params"></span>) { 1362 <span class="hljs-keyword">throw</span> <span class="hljs-keyword">new</span> <span class="hljs-title class_">Error</span>(<span class="hljs-string">'oh no!'</span>); 1363 }); 1364} 1365 1366<span class="hljs-title function_">makeFaster</span>(); 1367<span class="hljs-comment">// will throw:</span> 1368<span class="hljs-comment">// /home/gbusey/file.js:6</span> 1369<span class="hljs-comment">// throw new Error('oh no!');</span> 1370<span class="hljs-comment">// ^</span> 1371<span class="hljs-comment">// Error: oh no!</span> 1372<span class="hljs-comment">// at speedy (/home/gbusey/file.js:6:11)</span> 1373<span class="hljs-comment">// at makeFaster (/home/gbusey/file.js:5:3)</span> 1374<span class="hljs-comment">// at Object.<anonymous> (/home/gbusey/file.js:10:1)</span> 1375<span class="hljs-comment">// at Module._compile (module.js:456:26)</span> 1376<span class="hljs-comment">// at Object.Module._extensions..js (module.js:474:10)</span> 1377<span class="hljs-comment">// at Module.load (module.js:356:32)</span> 1378<span class="hljs-comment">// at Function.Module._load (module.js:312:12)</span> 1379<span class="hljs-comment">// at Function.Module.runMain (module.js:497:10)</span> 1380<span class="hljs-comment">// at startup (node.js:119:16)</span> 1381<span class="hljs-comment">// at node.js:906:3</span></code> <button class="copy-button">copy</button></pre> 1382<p>The location information will be one of:</p> 1383<ul> 1384<li><code>native</code>, if the frame represents a call internal to V8 (as in <code>[].forEach</code>).</li> 1385<li><code>plain-filename.js:line:column</code>, if the frame represents a call internal 1386to Node.js.</li> 1387<li><code>/absolute/path/to/file.js:line:column</code>, if the frame represents a call in 1388a user program (using CommonJS module system), or its dependencies.</li> 1389<li><code><transport-protocol>:///url/to/module/file.mjs:line:column</code>, if the frame 1390represents a call in a user program (using ES module system), or 1391its dependencies.</li> 1392</ul> 1393<p>The string representing the stack trace is lazily generated when the 1394<code>error.stack</code> property is <strong>accessed</strong>.</p> 1395<p>The number of frames captured by the stack trace is bounded by the smaller of 1396<code>Error.stackTraceLimit</code> or the number of available frames on the current event 1397loop tick.</p> 1398</section><section><h3>Class: <code>AssertionError</code><span><a class="mark" href="#class-assertionerror" id="class-assertionerror">#</a></span><a aria-hidden="true" class="legacy" id="errors_class_assertionerror"></a></h3> 1399<ul> 1400<li>Extends: <a href="errors.html#class-error" class="type"><errors.Error></a></li> 1401</ul> 1402<p>Indicates the failure of an assertion. For details, see 1403<a href="assert.html#class-assertassertionerror"><code>Class: assert.AssertionError</code></a>.</p> 1404</section><section><h3>Class: <code>RangeError</code><span><a class="mark" href="#class-rangeerror" id="class-rangeerror">#</a></span><a aria-hidden="true" class="legacy" id="errors_class_rangeerror"></a></h3> 1405<ul> 1406<li>Extends: <a href="errors.html#class-error" class="type"><errors.Error></a></li> 1407</ul> 1408<p>Indicates that a provided argument was not within the set or range of 1409acceptable values for a function; whether that is a numeric range, or 1410outside the set of options for a given function parameter.</p> 1411<pre><code class="language-js"><span class="hljs-built_in">require</span>(<span class="hljs-string">'node:net'</span>).<span class="hljs-title function_">connect</span>(-<span class="hljs-number">1</span>); 1412<span class="hljs-comment">// Throws "RangeError: "port" option should be >= 0 and < 65536: -1"</span></code> <button class="copy-button">copy</button></pre> 1413<p>Node.js will generate and throw <code>RangeError</code> instances <em>immediately</em> as a form 1414of argument validation.</p> 1415</section><section><h3>Class: <code>ReferenceError</code><span><a class="mark" href="#class-referenceerror" id="class-referenceerror">#</a></span><a aria-hidden="true" class="legacy" id="errors_class_referenceerror"></a></h3> 1416<ul> 1417<li>Extends: <a href="errors.html#class-error" class="type"><errors.Error></a></li> 1418</ul> 1419<p>Indicates that an attempt is being made to access a variable that is not 1420defined. Such errors commonly indicate typos in code, or an otherwise broken 1421program.</p> 1422<p>While client code may generate and propagate these errors, in practice, only V8 1423will do so.</p> 1424<pre><code class="language-js">doesNotExist; 1425<span class="hljs-comment">// Throws ReferenceError, doesNotExist is not a variable in this program.</span></code> <button class="copy-button">copy</button></pre> 1426<p>Unless an application is dynamically generating and running code, 1427<code>ReferenceError</code> instances indicate a bug in the code or its dependencies.</p> 1428</section><section><h3>Class: <code>SyntaxError</code><span><a class="mark" href="#class-syntaxerror" id="class-syntaxerror">#</a></span><a aria-hidden="true" class="legacy" id="errors_class_syntaxerror"></a></h3> 1429<ul> 1430<li>Extends: <a href="errors.html#class-error" class="type"><errors.Error></a></li> 1431</ul> 1432<p>Indicates that a program is not valid JavaScript. These errors may only be 1433generated and propagated as a result of code evaluation. Code evaluation may 1434happen as a result of <code>eval</code>, <code>Function</code>, <code>require</code>, or <a href="vm.html">vm</a>. These errors 1435are almost always indicative of a broken program.</p> 1436<pre><code class="language-js"><span class="hljs-keyword">try</span> { 1437 <span class="hljs-built_in">require</span>(<span class="hljs-string">'node:vm'</span>).<span class="hljs-title function_">runInThisContext</span>(<span class="hljs-string">'binary ! isNotOk'</span>); 1438} <span class="hljs-keyword">catch</span> (err) { 1439 <span class="hljs-comment">// 'err' will be a SyntaxError.</span> 1440}</code> <button class="copy-button">copy</button></pre> 1441<p><code>SyntaxError</code> instances are unrecoverable in the context that created them – 1442they may only be caught by other contexts.</p> 1443</section><section><h3>Class: <code>SystemError</code><span><a class="mark" href="#class-systemerror" id="class-systemerror">#</a></span><a aria-hidden="true" class="legacy" id="errors_class_systemerror"></a></h3> 1444<ul> 1445<li>Extends: <a href="errors.html#class-error" class="type"><errors.Error></a></li> 1446</ul> 1447<p>Node.js generates system errors when exceptions occur within its runtime 1448environment. These usually occur when an application violates an operating 1449system constraint. For example, a system error will occur if an application 1450attempts to read a file that does not exist.</p> 1451<ul> 1452<li><code>address</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a> If present, the address to which a network connection 1453failed</li> 1454<li><code>code</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a> The string error code</li> 1455<li><code>dest</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a> If present, the file path destination when reporting a file 1456system error</li> 1457<li><code>errno</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type"><number></a> The system-provided error number</li> 1458<li><code>info</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object" class="type"><Object></a> If present, extra details about the error condition</li> 1459<li><code>message</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a> A system-provided human-readable description of the error</li> 1460<li><code>path</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a> If present, the file path when reporting a file system error</li> 1461<li><code>port</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type"><number></a> If present, the network connection port that is not available</li> 1462<li><code>syscall</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a> The name of the system call that triggered the error</li> 1463</ul> 1464<h4><code>error.address</code><span><a class="mark" href="#erroraddress" id="erroraddress">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_address"></a></h4> 1465<ul> 1466<li><a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a></li> 1467</ul> 1468<p>If present, <code>error.address</code> is a string describing the address to which a 1469network connection failed.</p> 1470<h4><code>error.code</code><span><a class="mark" href="#errorcode_1" id="errorcode_1">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_code_1"></a></h4> 1471<ul> 1472<li><a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a></li> 1473</ul> 1474<p>The <code>error.code</code> property is a string representing the error code.</p> 1475<h4><code>error.dest</code><span><a class="mark" href="#errordest" id="errordest">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_dest"></a></h4> 1476<ul> 1477<li><a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a></li> 1478</ul> 1479<p>If present, <code>error.dest</code> is the file path destination when reporting a file 1480system error.</p> 1481<h4><code>error.errno</code><span><a class="mark" href="#errorerrno" id="errorerrno">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_errno"></a></h4> 1482<ul> 1483<li><a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type"><number></a></li> 1484</ul> 1485<p>The <code>error.errno</code> property is a negative number which corresponds 1486to the error code defined in <a href="https://docs.libuv.org/en/v1.x/errors.html"><code>libuv Error handling</code></a>.</p> 1487<p>On Windows the error number provided by the system will be normalized by libuv.</p> 1488<p>To get the string representation of the error code, use 1489<a href="util.html#utilgetsystemerrornameerr"><code>util.getSystemErrorName(error.errno)</code></a>.</p> 1490<h4><code>error.info</code><span><a class="mark" href="#errorinfo" id="errorinfo">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_info"></a></h4> 1491<ul> 1492<li><a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object" class="type"><Object></a></li> 1493</ul> 1494<p>If present, <code>error.info</code> is an object with details about the error condition.</p> 1495<h4><code>error.message</code><span><a class="mark" href="#errormessage_1" id="errormessage_1">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_message_1"></a></h4> 1496<ul> 1497<li><a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a></li> 1498</ul> 1499<p><code>error.message</code> is a system-provided human-readable description of the error.</p> 1500<h4><code>error.path</code><span><a class="mark" href="#errorpath" id="errorpath">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_path"></a></h4> 1501<ul> 1502<li><a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a></li> 1503</ul> 1504<p>If present, <code>error.path</code> is a string containing a relevant invalid pathname.</p> 1505<h4><code>error.port</code><span><a class="mark" href="#errorport" id="errorport">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_port"></a></h4> 1506<ul> 1507<li><a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type"><number></a></li> 1508</ul> 1509<p>If present, <code>error.port</code> is the network connection port that is not available.</p> 1510<h4><code>error.syscall</code><span><a class="mark" href="#errorsyscall" id="errorsyscall">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_syscall"></a></h4> 1511<ul> 1512<li><a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a></li> 1513</ul> 1514<p>The <code>error.syscall</code> property is a string describing the <a href="https://man7.org/linux/man-pages/man2/syscalls.2.html">syscall</a> that failed.</p> 1515<h4>Common system errors<span><a class="mark" href="#common-system-errors" id="common-system-errors">#</a></span><a aria-hidden="true" class="legacy" id="errors_common_system_errors"></a></h4> 1516<p>This is a list of system errors commonly-encountered when writing a Node.js 1517program. For a comprehensive list, see the <a href="https://man7.org/linux/man-pages/man3/errno.3.html"><code>errno</code>(3) man page</a>.</p> 1518<ul> 1519<li> 1520<p><code>EACCES</code> (Permission denied): An attempt was made to access a file in a way 1521forbidden by its file access permissions.</p> 1522</li> 1523<li> 1524<p><code>EADDRINUSE</code> (Address already in use): An attempt to bind a server 1525(<a href="net.html"><code>net</code></a>, <a href="http.html"><code>http</code></a>, or <a href="https.html"><code>https</code></a>) to a local address failed due to 1526another server on the local system already occupying that address.</p> 1527</li> 1528<li> 1529<p><code>ECONNREFUSED</code> (Connection refused): No connection could be made because the 1530target machine actively refused it. This usually results from trying to 1531connect to a service that is inactive on the foreign host.</p> 1532</li> 1533<li> 1534<p><code>ECONNRESET</code> (Connection reset by peer): A connection was forcibly closed by 1535a peer. This normally results from a loss of the connection on the remote 1536socket due to a timeout or reboot. Commonly encountered via the <a href="http.html"><code>http</code></a> 1537and <a href="net.html"><code>net</code></a> modules.</p> 1538</li> 1539<li> 1540<p><code>EEXIST</code> (File exists): An existing file was the target of an operation that 1541required that the target not exist.</p> 1542</li> 1543<li> 1544<p><code>EISDIR</code> (Is a directory): An operation expected a file, but the given 1545pathname was a directory.</p> 1546</li> 1547<li> 1548<p><code>EMFILE</code> (Too many open files in system): Maximum number of 1549<a href="https://en.wikipedia.org/wiki/File_descriptor">file descriptors</a> allowable on the system has been reached, and 1550requests for another descriptor cannot be fulfilled until at least one 1551has been closed. This is encountered when opening many files at once in 1552parallel, especially on systems (in particular, macOS) where there is a low 1553file descriptor limit for processes. To remedy a low limit, run 1554<code>ulimit -n 2048</code> in the same shell that will run the Node.js process.</p> 1555</li> 1556<li> 1557<p><code>ENOENT</code> (No such file or directory): Commonly raised by <a href="fs.html"><code>fs</code></a> operations 1558to indicate that a component of the specified pathname does not exist. No 1559entity (file or directory) could be found by the given path.</p> 1560</li> 1561<li> 1562<p><code>ENOTDIR</code> (Not a directory): A component of the given pathname existed, but 1563was not a directory as expected. Commonly raised by <a href="fs.html#fsreaddirpath-options-callback"><code>fs.readdir</code></a>.</p> 1564</li> 1565<li> 1566<p><code>ENOTEMPTY</code> (Directory not empty): A directory with entries was the target 1567of an operation that requires an empty directory, usually <a href="fs.html#fsunlinkpath-callback"><code>fs.unlink</code></a>.</p> 1568</li> 1569<li> 1570<p><code>ENOTFOUND</code> (DNS lookup failed): Indicates a DNS failure of either 1571<code>EAI_NODATA</code> or <code>EAI_NONAME</code>. This is not a standard POSIX error.</p> 1572</li> 1573<li> 1574<p><code>EPERM</code> (Operation not permitted): An attempt was made to perform an 1575operation that requires elevated privileges.</p> 1576</li> 1577<li> 1578<p><code>EPIPE</code> (Broken pipe): A write on a pipe, socket, or FIFO for which there is 1579no process to read the data. Commonly encountered at the <a href="net.html"><code>net</code></a> and 1580<a href="http.html"><code>http</code></a> layers, indicative that the remote side of the stream being 1581written to has been closed.</p> 1582</li> 1583<li> 1584<p><code>ETIMEDOUT</code> (Operation timed out): A connect or send request failed because 1585the connected party did not properly respond after a period of time. Usually 1586encountered by <a href="http.html"><code>http</code></a> or <a href="net.html"><code>net</code></a>. Often a sign that a <code>socket.end()</code> 1587was not properly called.</p> 1588</li> 1589</ul> 1590</section><section><h3>Class: <code>TypeError</code><span><a class="mark" href="#class-typeerror" id="class-typeerror">#</a></span><a aria-hidden="true" class="legacy" id="errors_class_typeerror"></a></h3> 1591<ul> 1592<li>Extends <a href="errors.html#class-error" class="type"><errors.Error></a></li> 1593</ul> 1594<p>Indicates that a provided argument is not an allowable type. For example, 1595passing a function to a parameter which expects a string would be a <code>TypeError</code>.</p> 1596<pre><code class="language-js"><span class="hljs-built_in">require</span>(<span class="hljs-string">'node:url'</span>).<span class="hljs-title function_">parse</span>(<span class="hljs-function">() =></span> { }); 1597<span class="hljs-comment">// Throws TypeError, since it expected a string.</span></code> <button class="copy-button">copy</button></pre> 1598<p>Node.js will generate and throw <code>TypeError</code> instances <em>immediately</em> as a form 1599of argument validation.</p> 1600</section><section><h3>Exceptions vs. errors<span><a class="mark" href="#exceptions-vs-errors" id="exceptions-vs-errors">#</a></span><a aria-hidden="true" class="legacy" id="errors_exceptions_vs_errors"></a></h3> 1601 1602<p>A JavaScript exception is a value that is thrown as a result of an invalid 1603operation or as the target of a <code>throw</code> statement. While it is not required 1604that these values are instances of <code>Error</code> or classes which inherit from 1605<code>Error</code>, all exceptions thrown by Node.js or the JavaScript runtime <em>will</em> be 1606instances of <code>Error</code>.</p> 1607<p>Some exceptions are <em>unrecoverable</em> at the JavaScript layer. Such exceptions 1608will <em>always</em> cause the Node.js process to crash. Examples include <code>assert()</code> 1609checks or <code>abort()</code> calls in the C++ layer.</p> 1610</section><section><h3>OpenSSL errors<span><a class="mark" href="#openssl-errors" id="openssl-errors">#</a></span><a aria-hidden="true" class="legacy" id="errors_openssl_errors"></a></h3> 1611<p>Errors originating in <code>crypto</code> or <code>tls</code> are of class <code>Error</code>, and in addition to 1612the standard <code>.code</code> and <code>.message</code> properties, may have some additional 1613OpenSSL-specific properties.</p> 1614<h4><code>error.opensslErrorStack</code><span><a class="mark" href="#erroropensslerrorstack" id="erroropensslerrorstack">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_opensslerrorstack"></a></h4> 1615<p>An array of errors that can give context to where in the OpenSSL library an 1616error originates from.</p> 1617<h4><code>error.function</code><span><a class="mark" href="#errorfunction" id="errorfunction">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_function"></a></h4> 1618<p>The OpenSSL function the error originates in.</p> 1619<h4><code>error.library</code><span><a class="mark" href="#errorlibrary" id="errorlibrary">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_library"></a></h4> 1620<p>The OpenSSL library the error originates in.</p> 1621<h4><code>error.reason</code><span><a class="mark" href="#errorreason" id="errorreason">#</a></span><a aria-hidden="true" class="legacy" id="errors_error_reason"></a></h4> 1622<p>A human-readable string describing the reason for the error.</p> 1623<p><a id="nodejs-error-codes"></a></p> 1624</section><section><h3>Node.js error codes<span><a class="mark" href="#nodejs-error-codes" id="nodejs-error-codes">#</a></span><a aria-hidden="true" class="legacy" id="errors_node_js_error_codes"></a></h3> 1625<p><a id="ABORT_ERR"></a></p> 1626<h4><code>ABORT_ERR</code><span><a class="mark" href="#abort_err" id="abort_err">#</a></span><a aria-hidden="true" class="legacy" id="errors_abort_err"></a></h4> 1627<div class="api_metadata"> 1628<span>Added in: v15.0.0</span> 1629</div> 1630<p>Used when an operation has been aborted (typically using an <code>AbortController</code>).</p> 1631<p>APIs <em>not</em> using <code>AbortSignal</code>s typically do not raise an error with this code.</p> 1632<p>This code does not use the regular <code>ERR_*</code> convention Node.js errors use in 1633order to be compatible with the web platform's <code>AbortError</code>.</p> 1634<p><a id="ERR_ACCESS_DENIED"></a></p> 1635<h4><code>ERR_ACCESS_DENIED</code><span><a class="mark" href="#err_access_denied" id="err_access_denied">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_access_denied"></a></h4> 1636<p>A special type of error that is triggered whenever Node.js tries to get access 1637to a resource restricted by the <a href="permissions.html#policies">policy</a> manifest. 1638For example, <code>process.binding</code>.</p> 1639<p><a id="ERR_AMBIGUOUS_ARGUMENT"></a></p> 1640<h4><code>ERR_AMBIGUOUS_ARGUMENT</code><span><a class="mark" href="#err_ambiguous_argument" id="err_ambiguous_argument">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_ambiguous_argument"></a></h4> 1641<p>A function argument is being used in a way that suggests that the function 1642signature may be misunderstood. This is thrown by the <code>node:assert</code> module when 1643the <code>message</code> parameter in <code>assert.throws(block, message)</code> matches the error 1644message thrown by <code>block</code> because that usage suggests that the user believes 1645<code>message</code> is the expected message rather than the message the <code>AssertionError</code> 1646will display if <code>block</code> does not throw.</p> 1647<p><a id="ERR_ARG_NOT_ITERABLE"></a></p> 1648<h4><code>ERR_ARG_NOT_ITERABLE</code><span><a class="mark" href="#err_arg_not_iterable" id="err_arg_not_iterable">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_arg_not_iterable"></a></h4> 1649<p>An iterable argument (i.e. a value that works with <code>for...of</code> loops) was 1650required, but not provided to a Node.js API.</p> 1651<p><a id="ERR_ASSERTION"></a></p> 1652<h4><code>ERR_ASSERTION</code><span><a class="mark" href="#err_assertion" id="err_assertion">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_assertion"></a></h4> 1653<p>A special type of error that can be triggered whenever Node.js detects an 1654exceptional logic violation that should never occur. These are raised typically 1655by the <code>node:assert</code> module.</p> 1656<p><a id="ERR_ASYNC_CALLBACK"></a></p> 1657<h4><code>ERR_ASYNC_CALLBACK</code><span><a class="mark" href="#err_async_callback" id="err_async_callback">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_async_callback"></a></h4> 1658<p>An attempt was made to register something that is not a function as an 1659<code>AsyncHooks</code> callback.</p> 1660<p><a id="ERR_ASYNC_TYPE"></a></p> 1661<h4><code>ERR_ASYNC_TYPE</code><span><a class="mark" href="#err_async_type" id="err_async_type">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_async_type"></a></h4> 1662<p>The type of an asynchronous resource was invalid. Users are also able 1663to define their own types if using the public embedder API.</p> 1664<p><a id="ERR_BROTLI_COMPRESSION_FAILED"></a></p> 1665<h4><code>ERR_BROTLI_COMPRESSION_FAILED</code><span><a class="mark" href="#err_brotli_compression_failed" id="err_brotli_compression_failed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_brotli_compression_failed"></a></h4> 1666<p>Data passed to a Brotli stream was not successfully compressed.</p> 1667<p><a id="ERR_BROTLI_INVALID_PARAM"></a></p> 1668<h4><code>ERR_BROTLI_INVALID_PARAM</code><span><a class="mark" href="#err_brotli_invalid_param" id="err_brotli_invalid_param">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_brotli_invalid_param"></a></h4> 1669<p>An invalid parameter key was passed during construction of a Brotli stream.</p> 1670<p><a id="ERR_BUFFER_CONTEXT_NOT_AVAILABLE"></a></p> 1671<h4><code>ERR_BUFFER_CONTEXT_NOT_AVAILABLE</code><span><a class="mark" href="#err_buffer_context_not_available" id="err_buffer_context_not_available">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_buffer_context_not_available"></a></h4> 1672<p>An attempt was made to create a Node.js <code>Buffer</code> instance from addon or embedder 1673code, while in a JS engine Context that is not associated with a Node.js 1674instance. The data passed to the <code>Buffer</code> method will have been released 1675by the time the method returns.</p> 1676<p>When encountering this error, a possible alternative to creating a <code>Buffer</code> 1677instance is to create a normal <code>Uint8Array</code>, which only differs in the 1678prototype of the resulting object. <code>Uint8Array</code>s are generally accepted in all 1679Node.js core APIs where <code>Buffer</code>s are; they are available in all Contexts.</p> 1680<p><a id="ERR_BUFFER_OUT_OF_BOUNDS"></a></p> 1681<h4><code>ERR_BUFFER_OUT_OF_BOUNDS</code><span><a class="mark" href="#err_buffer_out_of_bounds" id="err_buffer_out_of_bounds">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_buffer_out_of_bounds"></a></h4> 1682<p>An operation outside the bounds of a <code>Buffer</code> was attempted.</p> 1683<p><a id="ERR_BUFFER_TOO_LARGE"></a></p> 1684<h4><code>ERR_BUFFER_TOO_LARGE</code><span><a class="mark" href="#err_buffer_too_large" id="err_buffer_too_large">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_buffer_too_large"></a></h4> 1685<p>An attempt has been made to create a <code>Buffer</code> larger than the maximum allowed 1686size.</p> 1687<p><a id="ERR_CANNOT_WATCH_SIGINT"></a></p> 1688<h4><code>ERR_CANNOT_WATCH_SIGINT</code><span><a class="mark" href="#err_cannot_watch_sigint" id="err_cannot_watch_sigint">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_cannot_watch_sigint"></a></h4> 1689<p>Node.js was unable to watch for the <code>SIGINT</code> signal.</p> 1690<p><a id="ERR_CHILD_CLOSED_BEFORE_REPLY"></a></p> 1691<h4><code>ERR_CHILD_CLOSED_BEFORE_REPLY</code><span><a class="mark" href="#err_child_closed_before_reply" id="err_child_closed_before_reply">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_child_closed_before_reply"></a></h4> 1692<p>A child process was closed before the parent received a reply.</p> 1693<p><a id="ERR_CHILD_PROCESS_IPC_REQUIRED"></a></p> 1694<h4><code>ERR_CHILD_PROCESS_IPC_REQUIRED</code><span><a class="mark" href="#err_child_process_ipc_required" id="err_child_process_ipc_required">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_child_process_ipc_required"></a></h4> 1695<p>Used when a child process is being forked without specifying an IPC channel.</p> 1696<p><a id="ERR_CHILD_PROCESS_STDIO_MAXBUFFER"></a></p> 1697<h4><code>ERR_CHILD_PROCESS_STDIO_MAXBUFFER</code><span><a class="mark" href="#err_child_process_stdio_maxbuffer" id="err_child_process_stdio_maxbuffer">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_child_process_stdio_maxbuffer"></a></h4> 1698<p>Used when the main process is trying to read data from the child process's 1699STDERR/STDOUT, and the data's length is longer than the <code>maxBuffer</code> option.</p> 1700<p><a id="ERR_CLOSED_MESSAGE_PORT"></a></p> 1701<h4><code>ERR_CLOSED_MESSAGE_PORT</code><span><a class="mark" href="#err_closed_message_port" id="err_closed_message_port">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_closed_message_port"></a></h4> 1702<!-- 1703added: 1704 - v16.2.0 1705 - v14.17.1 1706changes: 1707 - version: 11.12.0 1708 pr-url: https://github.com/nodejs/node/pull/26487 1709 description: The error message was removed. 1710 - version: 1711 - v16.2.0 1712 - v14.17.1 1713 pr-url: https://github.com/nodejs/node/pull/38510 1714 description: The error message was reintroduced. 1715--> 1716<p>There was an attempt to use a <code>MessagePort</code> instance in a closed 1717state, usually after <code>.close()</code> has been called.</p> 1718<p><a id="ERR_CONSOLE_WRITABLE_STREAM"></a></p> 1719<h4><code>ERR_CONSOLE_WRITABLE_STREAM</code><span><a class="mark" href="#err_console_writable_stream" id="err_console_writable_stream">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_console_writable_stream"></a></h4> 1720<p><code>Console</code> was instantiated without <code>stdout</code> stream, or <code>Console</code> has a 1721non-writable <code>stdout</code> or <code>stderr</code> stream.</p> 1722<p><a id="ERR_CONSTRUCT_CALL_INVALID"></a></p> 1723<h4><code>ERR_CONSTRUCT_CALL_INVALID</code><span><a class="mark" href="#err_construct_call_invalid" id="err_construct_call_invalid">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_construct_call_invalid"></a></h4> 1724<!-- 1725added: v12.5.0 1726--> 1727<p>A class constructor was called that is not callable.</p> 1728<p><a id="ERR_CONSTRUCT_CALL_REQUIRED"></a></p> 1729<h4><code>ERR_CONSTRUCT_CALL_REQUIRED</code><span><a class="mark" href="#err_construct_call_required" id="err_construct_call_required">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_construct_call_required"></a></h4> 1730<p>A constructor for a class was called without <code>new</code>.</p> 1731<p><a id="ERR_CONTEXT_NOT_INITIALIZED"></a></p> 1732<h4><code>ERR_CONTEXT_NOT_INITIALIZED</code><span><a class="mark" href="#err_context_not_initialized" id="err_context_not_initialized">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_context_not_initialized"></a></h4> 1733<p>The vm context passed into the API is not yet initialized. This could happen 1734when an error occurs (and is caught) during the creation of the 1735context, for example, when the allocation fails or the maximum call stack 1736size is reached when the context is created.</p> 1737<p><a id="ERR_CRYPTO_CUSTOM_ENGINE_NOT_SUPPORTED"></a></p> 1738<h4><code>ERR_CRYPTO_CUSTOM_ENGINE_NOT_SUPPORTED</code><span><a class="mark" href="#err_crypto_custom_engine_not_supported" id="err_crypto_custom_engine_not_supported">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_custom_engine_not_supported"></a></h4> 1739<p>An OpenSSL engine was requested (for example, through the <code>clientCertEngine</code> or 1740<code>privateKeyEngine</code> TLS options) that is not supported by the version of OpenSSL 1741being used, likely due to the compile-time flag <code>OPENSSL_NO_ENGINE</code>.</p> 1742<p><a id="ERR_CRYPTO_ECDH_INVALID_FORMAT"></a></p> 1743<h4><code>ERR_CRYPTO_ECDH_INVALID_FORMAT</code><span><a class="mark" href="#err_crypto_ecdh_invalid_format" id="err_crypto_ecdh_invalid_format">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_ecdh_invalid_format"></a></h4> 1744<p>An invalid value for the <code>format</code> argument was passed to the <code>crypto.ECDH()</code> 1745class <code>getPublicKey()</code> method.</p> 1746<p><a id="ERR_CRYPTO_ECDH_INVALID_PUBLIC_KEY"></a></p> 1747<h4><code>ERR_CRYPTO_ECDH_INVALID_PUBLIC_KEY</code><span><a class="mark" href="#err_crypto_ecdh_invalid_public_key" id="err_crypto_ecdh_invalid_public_key">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_ecdh_invalid_public_key"></a></h4> 1748<p>An invalid value for the <code>key</code> argument has been passed to the 1749<code>crypto.ECDH()</code> class <code>computeSecret()</code> method. It means that the public 1750key lies outside of the elliptic curve.</p> 1751<p><a id="ERR_CRYPTO_ENGINE_UNKNOWN"></a></p> 1752<h4><code>ERR_CRYPTO_ENGINE_UNKNOWN</code><span><a class="mark" href="#err_crypto_engine_unknown" id="err_crypto_engine_unknown">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_engine_unknown"></a></h4> 1753<p>An invalid crypto engine identifier was passed to 1754<a href="crypto.html#cryptosetengineengine-flags"><code>require('node:crypto').setEngine()</code></a>.</p> 1755<p><a id="ERR_CRYPTO_FIPS_FORCED"></a></p> 1756<h4><code>ERR_CRYPTO_FIPS_FORCED</code><span><a class="mark" href="#err_crypto_fips_forced" id="err_crypto_fips_forced">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_fips_forced"></a></h4> 1757<p>The <a href="cli.html#--force-fips"><code>--force-fips</code></a> command-line argument was used but there was an attempt 1758to enable or disable FIPS mode in the <code>node:crypto</code> module.</p> 1759<p><a id="ERR_CRYPTO_FIPS_UNAVAILABLE"></a></p> 1760<h4><code>ERR_CRYPTO_FIPS_UNAVAILABLE</code><span><a class="mark" href="#err_crypto_fips_unavailable" id="err_crypto_fips_unavailable">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_fips_unavailable"></a></h4> 1761<p>An attempt was made to enable or disable FIPS mode, but FIPS mode was not 1762available.</p> 1763<p><a id="ERR_CRYPTO_HASH_FINALIZED"></a></p> 1764<h4><code>ERR_CRYPTO_HASH_FINALIZED</code><span><a class="mark" href="#err_crypto_hash_finalized" id="err_crypto_hash_finalized">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_hash_finalized"></a></h4> 1765<p><a href="crypto.html#hashdigestencoding"><code>hash.digest()</code></a> was called multiple times. The <code>hash.digest()</code> method must 1766be called no more than one time per instance of a <code>Hash</code> object.</p> 1767<p><a id="ERR_CRYPTO_HASH_UPDATE_FAILED"></a></p> 1768<h4><code>ERR_CRYPTO_HASH_UPDATE_FAILED</code><span><a class="mark" href="#err_crypto_hash_update_failed" id="err_crypto_hash_update_failed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_hash_update_failed"></a></h4> 1769<p><a href="crypto.html#hashupdatedata-inputencoding"><code>hash.update()</code></a> failed for any reason. This should rarely, if ever, happen.</p> 1770<p><a id="ERR_CRYPTO_INCOMPATIBLE_KEY"></a></p> 1771<h4><code>ERR_CRYPTO_INCOMPATIBLE_KEY</code><span><a class="mark" href="#err_crypto_incompatible_key" id="err_crypto_incompatible_key">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_incompatible_key"></a></h4> 1772<p>The given crypto keys are incompatible with the attempted operation.</p> 1773<p><a id="ERR_CRYPTO_INCOMPATIBLE_KEY_OPTIONS"></a></p> 1774<h4><code>ERR_CRYPTO_INCOMPATIBLE_KEY_OPTIONS</code><span><a class="mark" href="#err_crypto_incompatible_key_options" id="err_crypto_incompatible_key_options">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_incompatible_key_options"></a></h4> 1775<p>The selected public or private key encoding is incompatible with other options.</p> 1776<p><a id="ERR_CRYPTO_INITIALIZATION_FAILED"></a></p> 1777<h4><code>ERR_CRYPTO_INITIALIZATION_FAILED</code><span><a class="mark" href="#err_crypto_initialization_failed" id="err_crypto_initialization_failed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_initialization_failed"></a></h4> 1778<div class="api_metadata"> 1779<span>Added in: v15.0.0</span> 1780</div> 1781<p>Initialization of the crypto subsystem failed.</p> 1782<p><a id="ERR_CRYPTO_INVALID_AUTH_TAG"></a></p> 1783<h4><code>ERR_CRYPTO_INVALID_AUTH_TAG</code><span><a class="mark" href="#err_crypto_invalid_auth_tag" id="err_crypto_invalid_auth_tag">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_invalid_auth_tag"></a></h4> 1784<div class="api_metadata"> 1785<span>Added in: v15.0.0</span> 1786</div> 1787<p>An invalid authentication tag was provided.</p> 1788<p><a id="ERR_CRYPTO_INVALID_COUNTER"></a></p> 1789<h4><code>ERR_CRYPTO_INVALID_COUNTER</code><span><a class="mark" href="#err_crypto_invalid_counter" id="err_crypto_invalid_counter">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_invalid_counter"></a></h4> 1790<div class="api_metadata"> 1791<span>Added in: v15.0.0</span> 1792</div> 1793<p>An invalid counter was provided for a counter-mode cipher.</p> 1794<p><a id="ERR_CRYPTO_INVALID_CURVE"></a></p> 1795<h4><code>ERR_CRYPTO_INVALID_CURVE</code><span><a class="mark" href="#err_crypto_invalid_curve" id="err_crypto_invalid_curve">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_invalid_curve"></a></h4> 1796<div class="api_metadata"> 1797<span>Added in: v15.0.0</span> 1798</div> 1799<p>An invalid elliptic-curve was provided.</p> 1800<p><a id="ERR_CRYPTO_INVALID_DIGEST"></a></p> 1801<h4><code>ERR_CRYPTO_INVALID_DIGEST</code><span><a class="mark" href="#err_crypto_invalid_digest" id="err_crypto_invalid_digest">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_invalid_digest"></a></h4> 1802<p>An invalid <a href="crypto.html#cryptogethashes">crypto digest algorithm</a> was specified.</p> 1803<p><a id="ERR_CRYPTO_INVALID_IV"></a></p> 1804<h4><code>ERR_CRYPTO_INVALID_IV</code><span><a class="mark" href="#err_crypto_invalid_iv" id="err_crypto_invalid_iv">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_invalid_iv"></a></h4> 1805<div class="api_metadata"> 1806<span>Added in: v15.0.0</span> 1807</div> 1808<p>An invalid initialization vector was provided.</p> 1809<p><a id="ERR_CRYPTO_INVALID_JWK"></a></p> 1810<h4><code>ERR_CRYPTO_INVALID_JWK</code><span><a class="mark" href="#err_crypto_invalid_jwk" id="err_crypto_invalid_jwk">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_invalid_jwk"></a></h4> 1811<div class="api_metadata"> 1812<span>Added in: v15.0.0</span> 1813</div> 1814<p>An invalid JSON Web Key was provided.</p> 1815<p><a id="ERR_CRYPTO_INVALID_KEY_OBJECT_TYPE"></a></p> 1816<h4><code>ERR_CRYPTO_INVALID_KEY_OBJECT_TYPE</code><span><a class="mark" href="#err_crypto_invalid_key_object_type" id="err_crypto_invalid_key_object_type">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_invalid_key_object_type"></a></h4> 1817<p>The given crypto key object's type is invalid for the attempted operation.</p> 1818<p><a id="ERR_CRYPTO_INVALID_KEYLEN"></a></p> 1819<h4><code>ERR_CRYPTO_INVALID_KEYLEN</code><span><a class="mark" href="#err_crypto_invalid_keylen" id="err_crypto_invalid_keylen">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_invalid_keylen"></a></h4> 1820<div class="api_metadata"> 1821<span>Added in: v15.0.0</span> 1822</div> 1823<p>An invalid key length was provided.</p> 1824<p><a id="ERR_CRYPTO_INVALID_KEYPAIR"></a></p> 1825<h4><code>ERR_CRYPTO_INVALID_KEYPAIR</code><span><a class="mark" href="#err_crypto_invalid_keypair" id="err_crypto_invalid_keypair">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_invalid_keypair"></a></h4> 1826<div class="api_metadata"> 1827<span>Added in: v15.0.0</span> 1828</div> 1829<p>An invalid key pair was provided.</p> 1830<p><a id="ERR_CRYPTO_INVALID_KEYTYPE"></a></p> 1831<h4><code>ERR_CRYPTO_INVALID_KEYTYPE</code><span><a class="mark" href="#err_crypto_invalid_keytype" id="err_crypto_invalid_keytype">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_invalid_keytype"></a></h4> 1832<div class="api_metadata"> 1833<span>Added in: v15.0.0</span> 1834</div> 1835<p>An invalid key type was provided.</p> 1836<p><a id="ERR_CRYPTO_INVALID_MESSAGELEN"></a></p> 1837<h4><code>ERR_CRYPTO_INVALID_MESSAGELEN</code><span><a class="mark" href="#err_crypto_invalid_messagelen" id="err_crypto_invalid_messagelen">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_invalid_messagelen"></a></h4> 1838<div class="api_metadata"> 1839<span>Added in: v15.0.0</span> 1840</div> 1841<p>An invalid message length was provided.</p> 1842<p><a id="ERR_CRYPTO_INVALID_SCRYPT_PARAMS"></a></p> 1843<h4><code>ERR_CRYPTO_INVALID_SCRYPT_PARAMS</code><span><a class="mark" href="#err_crypto_invalid_scrypt_params" id="err_crypto_invalid_scrypt_params">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_invalid_scrypt_params"></a></h4> 1844<div class="api_metadata"> 1845<span>Added in: v15.0.0</span> 1846</div> 1847<p>Invalid scrypt algorithm parameters were provided.</p> 1848<p><a id="ERR_CRYPTO_INVALID_STATE"></a></p> 1849<h4><code>ERR_CRYPTO_INVALID_STATE</code><span><a class="mark" href="#err_crypto_invalid_state" id="err_crypto_invalid_state">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_invalid_state"></a></h4> 1850<p>A crypto method was used on an object that was in an invalid state. For 1851instance, calling <a href="crypto.html#ciphergetauthtag"><code>cipher.getAuthTag()</code></a> before calling <code>cipher.final()</code>.</p> 1852<p><a id="ERR_CRYPTO_INVALID_TAG_LENGTH"></a></p> 1853<h4><code>ERR_CRYPTO_INVALID_TAG_LENGTH</code><span><a class="mark" href="#err_crypto_invalid_tag_length" id="err_crypto_invalid_tag_length">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_invalid_tag_length"></a></h4> 1854<div class="api_metadata"> 1855<span>Added in: v15.0.0</span> 1856</div> 1857<p>An invalid authentication tag length was provided.</p> 1858<p><a id="ERR_CRYPTO_JOB_INIT_FAILED"></a></p> 1859<h4><code>ERR_CRYPTO_JOB_INIT_FAILED</code><span><a class="mark" href="#err_crypto_job_init_failed" id="err_crypto_job_init_failed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_job_init_failed"></a></h4> 1860<div class="api_metadata"> 1861<span>Added in: v15.0.0</span> 1862</div> 1863<p>Initialization of an asynchronous crypto operation failed.</p> 1864<p><a id="ERR_CRYPTO_JWK_UNSUPPORTED_CURVE"></a></p> 1865<h4><code>ERR_CRYPTO_JWK_UNSUPPORTED_CURVE</code><span><a class="mark" href="#err_crypto_jwk_unsupported_curve" id="err_crypto_jwk_unsupported_curve">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_jwk_unsupported_curve"></a></h4> 1866<p>Key's Elliptic Curve is not registered for use in the 1867<a href="https://www.iana.org/assignments/jose/jose.xhtml#web-key-elliptic-curve">JSON Web Key Elliptic Curve Registry</a>.</p> 1868<p><a id="ERR_CRYPTO_JWK_UNSUPPORTED_KEY_TYPE"></a></p> 1869<h4><code>ERR_CRYPTO_JWK_UNSUPPORTED_KEY_TYPE</code><span><a class="mark" href="#err_crypto_jwk_unsupported_key_type" id="err_crypto_jwk_unsupported_key_type">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_jwk_unsupported_key_type"></a></h4> 1870<p>Key's Asymmetric Key Type is not registered for use in the 1871<a href="https://www.iana.org/assignments/jose/jose.xhtml#web-key-types">JSON Web Key Types Registry</a>.</p> 1872<p><a id="ERR_CRYPTO_OPERATION_FAILED"></a></p> 1873<h4><code>ERR_CRYPTO_OPERATION_FAILED</code><span><a class="mark" href="#err_crypto_operation_failed" id="err_crypto_operation_failed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_operation_failed"></a></h4> 1874<div class="api_metadata"> 1875<span>Added in: v15.0.0</span> 1876</div> 1877<p>A crypto operation failed for an otherwise unspecified reason.</p> 1878<p><a id="ERR_CRYPTO_PBKDF2_ERROR"></a></p> 1879<h4><code>ERR_CRYPTO_PBKDF2_ERROR</code><span><a class="mark" href="#err_crypto_pbkdf2_error" id="err_crypto_pbkdf2_error">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_pbkdf2_error"></a></h4> 1880<p>The PBKDF2 algorithm failed for unspecified reasons. OpenSSL does not provide 1881more details and therefore neither does Node.js.</p> 1882<p><a id="ERR_CRYPTO_SCRYPT_INVALID_PARAMETER"></a></p> 1883<h4><code>ERR_CRYPTO_SCRYPT_INVALID_PARAMETER</code><span><a class="mark" href="#err_crypto_scrypt_invalid_parameter" id="err_crypto_scrypt_invalid_parameter">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_scrypt_invalid_parameter"></a></h4> 1884<p>One or more <a href="crypto.html#cryptoscryptpassword-salt-keylen-options-callback"><code>crypto.scrypt()</code></a> or <a href="crypto.html#cryptoscryptsyncpassword-salt-keylen-options"><code>crypto.scryptSync()</code></a> parameters are 1885outside their legal range.</p> 1886<p><a id="ERR_CRYPTO_SCRYPT_NOT_SUPPORTED"></a></p> 1887<h4><code>ERR_CRYPTO_SCRYPT_NOT_SUPPORTED</code><span><a class="mark" href="#err_crypto_scrypt_not_supported" id="err_crypto_scrypt_not_supported">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_scrypt_not_supported"></a></h4> 1888<p>Node.js was compiled without <code>scrypt</code> support. Not possible with the official 1889release binaries but can happen with custom builds, including distro builds.</p> 1890<p><a id="ERR_CRYPTO_SIGN_KEY_REQUIRED"></a></p> 1891<h4><code>ERR_CRYPTO_SIGN_KEY_REQUIRED</code><span><a class="mark" href="#err_crypto_sign_key_required" id="err_crypto_sign_key_required">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_sign_key_required"></a></h4> 1892<p>A signing <code>key</code> was not provided to the <a href="crypto.html#signsignprivatekey-outputencoding"><code>sign.sign()</code></a> method.</p> 1893<p><a id="ERR_CRYPTO_TIMING_SAFE_EQUAL_LENGTH"></a></p> 1894<h4><code>ERR_CRYPTO_TIMING_SAFE_EQUAL_LENGTH</code><span><a class="mark" href="#err_crypto_timing_safe_equal_length" id="err_crypto_timing_safe_equal_length">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_timing_safe_equal_length"></a></h4> 1895<p><a href="crypto.html#cryptotimingsafeequala-b"><code>crypto.timingSafeEqual()</code></a> was called with <code>Buffer</code>, <code>TypedArray</code>, or 1896<code>DataView</code> arguments of different lengths.</p> 1897<p><a id="ERR_CRYPTO_UNKNOWN_CIPHER"></a></p> 1898<h4><code>ERR_CRYPTO_UNKNOWN_CIPHER</code><span><a class="mark" href="#err_crypto_unknown_cipher" id="err_crypto_unknown_cipher">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_unknown_cipher"></a></h4> 1899<p>An unknown cipher was specified.</p> 1900<p><a id="ERR_CRYPTO_UNKNOWN_DH_GROUP"></a></p> 1901<h4><code>ERR_CRYPTO_UNKNOWN_DH_GROUP</code><span><a class="mark" href="#err_crypto_unknown_dh_group" id="err_crypto_unknown_dh_group">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_unknown_dh_group"></a></h4> 1902<p>An unknown Diffie-Hellman group name was given. See 1903<a href="crypto.html#cryptogetdiffiehellmangroupname"><code>crypto.getDiffieHellman()</code></a> for a list of valid group names.</p> 1904<p><a id="ERR_CRYPTO_UNSUPPORTED_OPERATION"></a></p> 1905<h4><code>ERR_CRYPTO_UNSUPPORTED_OPERATION</code><span><a class="mark" href="#err_crypto_unsupported_operation" id="err_crypto_unsupported_operation">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_unsupported_operation"></a></h4> 1906<div class="api_metadata"> 1907<span>Added in: v15.0.0, v14.18.0</span> 1908</div> 1909<p>An attempt to invoke an unsupported crypto operation was made.</p> 1910<p><a id="ERR_DEBUGGER_ERROR"></a></p> 1911<h4><code>ERR_DEBUGGER_ERROR</code><span><a class="mark" href="#err_debugger_error" id="err_debugger_error">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_debugger_error"></a></h4> 1912<div class="api_metadata"> 1913<span>Added in: v16.4.0, v14.17.4</span> 1914</div> 1915<p>An error occurred with the <a href="debugger.html">debugger</a>.</p> 1916<p><a id="ERR_DEBUGGER_STARTUP_ERROR"></a></p> 1917<h4><code>ERR_DEBUGGER_STARTUP_ERROR</code><span><a class="mark" href="#err_debugger_startup_error" id="err_debugger_startup_error">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_debugger_startup_error"></a></h4> 1918<div class="api_metadata"> 1919<span>Added in: v16.4.0, v14.17.4</span> 1920</div> 1921<p>The <a href="debugger.html">debugger</a> timed out waiting for the required host/port to be free.</p> 1922<p><a id="ERR_DLOPEN_DISABLED"></a></p> 1923<h4><code>ERR_DLOPEN_DISABLED</code><span><a class="mark" href="#err_dlopen_disabled" id="err_dlopen_disabled">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_dlopen_disabled"></a></h4> 1924<div class="api_metadata"> 1925<span>Added in: v16.10.0, v14.19.0</span> 1926</div> 1927<p>Loading native addons has been disabled using <a href="cli.html#--no-addons"><code>--no-addons</code></a>.</p> 1928<p><a id="ERR_DLOPEN_FAILED"></a></p> 1929<h4><code>ERR_DLOPEN_FAILED</code><span><a class="mark" href="#err_dlopen_failed" id="err_dlopen_failed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_dlopen_failed"></a></h4> 1930<div class="api_metadata"> 1931<span>Added in: v15.0.0</span> 1932</div> 1933<p>A call to <code>process.dlopen()</code> failed.</p> 1934<p><a id="ERR_DIR_CLOSED"></a></p> 1935<h4><code>ERR_DIR_CLOSED</code><span><a class="mark" href="#err_dir_closed" id="err_dir_closed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_dir_closed"></a></h4> 1936<p>The <a href="fs.html#class-fsdir"><code>fs.Dir</code></a> was previously closed.</p> 1937<p><a id="ERR_DIR_CONCURRENT_OPERATION"></a></p> 1938<h4><code>ERR_DIR_CONCURRENT_OPERATION</code><span><a class="mark" href="#err_dir_concurrent_operation" id="err_dir_concurrent_operation">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_dir_concurrent_operation"></a></h4> 1939<div class="api_metadata"> 1940<span>Added in: v14.3.0</span> 1941</div> 1942<p>A synchronous read or close call was attempted on an <a href="fs.html#class-fsdir"><code>fs.Dir</code></a> which has 1943ongoing asynchronous operations.</p> 1944<p><a id="ERR_DNS_SET_SERVERS_FAILED"></a></p> 1945<h4><code>ERR_DNS_SET_SERVERS_FAILED</code><span><a class="mark" href="#err_dns_set_servers_failed" id="err_dns_set_servers_failed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_dns_set_servers_failed"></a></h4> 1946<p><code>c-ares</code> failed to set the DNS server.</p> 1947<p><a id="ERR_DOMAIN_CALLBACK_NOT_AVAILABLE"></a></p> 1948<h4><code>ERR_DOMAIN_CALLBACK_NOT_AVAILABLE</code><span><a class="mark" href="#err_domain_callback_not_available" id="err_domain_callback_not_available">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_domain_callback_not_available"></a></h4> 1949<p>The <code>node:domain</code> module was not usable since it could not establish the 1950required error handling hooks, because 1951<a href="process.html#processsetuncaughtexceptioncapturecallbackfn"><code>process.setUncaughtExceptionCaptureCallback()</code></a> had been called at an 1952earlier point in time.</p> 1953<p><a id="ERR_DOMAIN_CANNOT_SET_UNCAUGHT_EXCEPTION_CAPTURE"></a></p> 1954<h4><code>ERR_DOMAIN_CANNOT_SET_UNCAUGHT_EXCEPTION_CAPTURE</code><span><a class="mark" href="#err_domain_cannot_set_uncaught_exception_capture" id="err_domain_cannot_set_uncaught_exception_capture">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_domain_cannot_set_uncaught_exception_capture"></a></h4> 1955<p><a href="process.html#processsetuncaughtexceptioncapturecallbackfn"><code>process.setUncaughtExceptionCaptureCallback()</code></a> could not be called 1956because the <code>node:domain</code> module has been loaded at an earlier point in time.</p> 1957<p>The stack trace is extended to include the point in time at which the 1958<code>node:domain</code> module had been loaded.</p> 1959<p><a id="ERR_DUPLICATE_STARTUP_SNAPSHOT_MAIN_FUNCTION"></a></p> 1960<h4><code>ERR_DUPLICATE_STARTUP_SNAPSHOT_MAIN_FUNCTION</code><span><a class="mark" href="#err_duplicate_startup_snapshot_main_function" id="err_duplicate_startup_snapshot_main_function">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_duplicate_startup_snapshot_main_function"></a></h4> 1961<p><a href="v8.html#v8startupsnapshotsetdeserializemainfunctioncallback-data"><code>v8.startupSnapshot.setDeserializeMainFunction()</code></a> could not be called 1962because it had already been called before.</p> 1963<p><a id="ERR_ENCODING_INVALID_ENCODED_DATA"></a></p> 1964<h4><code>ERR_ENCODING_INVALID_ENCODED_DATA</code><span><a class="mark" href="#err_encoding_invalid_encoded_data" id="err_encoding_invalid_encoded_data">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_encoding_invalid_encoded_data"></a></h4> 1965<p>Data provided to <code>TextDecoder()</code> API was invalid according to the encoding 1966provided.</p> 1967<p><a id="ERR_ENCODING_NOT_SUPPORTED"></a></p> 1968<h4><code>ERR_ENCODING_NOT_SUPPORTED</code><span><a class="mark" href="#err_encoding_not_supported" id="err_encoding_not_supported">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_encoding_not_supported"></a></h4> 1969<p>Encoding provided to <code>TextDecoder()</code> API was not one of the 1970<a href="util.html#whatwg-supported-encodings">WHATWG Supported Encodings</a>.</p> 1971<p><a id="ERR_EVAL_ESM_CANNOT_PRINT"></a></p> 1972<h4><code>ERR_EVAL_ESM_CANNOT_PRINT</code><span><a class="mark" href="#err_eval_esm_cannot_print" id="err_eval_esm_cannot_print">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_eval_esm_cannot_print"></a></h4> 1973<p><code>--print</code> cannot be used with ESM input.</p> 1974<p><a id="ERR_EVENT_RECURSION"></a></p> 1975<h4><code>ERR_EVENT_RECURSION</code><span><a class="mark" href="#err_event_recursion" id="err_event_recursion">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_event_recursion"></a></h4> 1976<p>Thrown when an attempt is made to recursively dispatch an event on <code>EventTarget</code>.</p> 1977<p><a id="ERR_EXECUTION_ENVIRONMENT_NOT_AVAILABLE"></a></p> 1978<h4><code>ERR_EXECUTION_ENVIRONMENT_NOT_AVAILABLE</code><span><a class="mark" href="#err_execution_environment_not_available" id="err_execution_environment_not_available">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_execution_environment_not_available"></a></h4> 1979<p>The JS execution context is not associated with a Node.js environment. 1980This may occur when Node.js is used as an embedded library and some hooks 1981for the JS engine are not set up properly.</p> 1982<p><a id="ERR_FALSY_VALUE_REJECTION"></a></p> 1983<h4><code>ERR_FALSY_VALUE_REJECTION</code><span><a class="mark" href="#err_falsy_value_rejection" id="err_falsy_value_rejection">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_falsy_value_rejection"></a></h4> 1984<p>A <code>Promise</code> that was callbackified via <code>util.callbackify()</code> was rejected with a 1985falsy value.</p> 1986<p><a id="ERR_FEATURE_UNAVAILABLE_ON_PLATFORM"></a></p> 1987<h4><code>ERR_FEATURE_UNAVAILABLE_ON_PLATFORM</code><span><a class="mark" href="#err_feature_unavailable_on_platform" id="err_feature_unavailable_on_platform">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_feature_unavailable_on_platform"></a></h4> 1988<div class="api_metadata"> 1989<span>Added in: v14.0.0</span> 1990</div> 1991<p>Used when a feature that is not available 1992to the current platform which is running Node.js is used.</p> 1993<p><a id="ERR_FS_CP_DIR_TO_NON_DIR"></a></p> 1994<h4><code>ERR_FS_CP_DIR_TO_NON_DIR</code><span><a class="mark" href="#err_fs_cp_dir_to_non_dir" id="err_fs_cp_dir_to_non_dir">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_fs_cp_dir_to_non_dir"></a></h4> 1995<!-- 1996added: v16.7.0 1997--> 1998<p>An attempt was made to copy a directory to a non-directory (file, symlink, 1999etc.) using <a href="fs.html#fscpsrc-dest-options-callback"><code>fs.cp()</code></a>.</p> 2000<p><a id="ERR_FS_CP_EEXIST"></a></p> 2001<h4><code>ERR_FS_CP_EEXIST</code><span><a class="mark" href="#err_fs_cp_eexist" id="err_fs_cp_eexist">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_fs_cp_eexist"></a></h4> 2002<!-- 2003added: v16.7.0 2004--> 2005<p>An attempt was made to copy over a file that already existed with 2006<a href="fs.html#fscpsrc-dest-options-callback"><code>fs.cp()</code></a>, with the <code>force</code> and <code>errorOnExist</code> set to <code>true</code>.</p> 2007<p><a id="ERR_FS_CP_EINVAL"></a></p> 2008<h4><code>ERR_FS_CP_EINVAL</code><span><a class="mark" href="#err_fs_cp_einval" id="err_fs_cp_einval">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_fs_cp_einval"></a></h4> 2009<!-- 2010added: v16.7.0 2011--> 2012<p>When using <a href="fs.html#fscpsrc-dest-options-callback"><code>fs.cp()</code></a>, <code>src</code> or <code>dest</code> pointed to an invalid path.</p> 2013<p><a id="ERR_FS_CP_FIFO_PIPE"></a></p> 2014<h4><code>ERR_HTTP_BODY_NOT_ALLOWED</code><span><a class="mark" href="#err_http_body_not_allowed" id="err_http_body_not_allowed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http_body_not_allowed"></a></h4> 2015<p>An error is thrown when writing to an HTTP response which does not allow 2016contents. <a id="ERR_HTTP_BODY_NOT_ALLOWED"></a></p> 2017<h4><code>ERR_HTTP_CONTENT_LENGTH_MISMATCH</code><span><a class="mark" href="#err_http_content_length_mismatch" id="err_http_content_length_mismatch">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http_content_length_mismatch"></a></h4> 2018<p>Response body size doesn't match with the specified content-length header value.</p> 2019<p><a id="ERR_HTTP_CONTENT_LENGTH_MISMATCH"></a></p> 2020<h4><code>ERR_FS_CP_FIFO_PIPE</code><span><a class="mark" href="#err_fs_cp_fifo_pipe" id="err_fs_cp_fifo_pipe">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_fs_cp_fifo_pipe"></a></h4> 2021<!-- 2022added: v16.7.0 2023--> 2024<p>An attempt was made to copy a named pipe with <a href="fs.html#fscpsrc-dest-options-callback"><code>fs.cp()</code></a>.</p> 2025<p><a id="ERR_FS_CP_NON_DIR_TO_DIR"></a></p> 2026<h4><code>ERR_FS_CP_NON_DIR_TO_DIR</code><span><a class="mark" href="#err_fs_cp_non_dir_to_dir" id="err_fs_cp_non_dir_to_dir">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_fs_cp_non_dir_to_dir"></a></h4> 2027<!-- 2028added: v16.7.0 2029--> 2030<p>An attempt was made to copy a non-directory (file, symlink, etc.) to a directory 2031using <a href="fs.html#fscpsrc-dest-options-callback"><code>fs.cp()</code></a>.</p> 2032<p><a id="ERR_FS_CP_SOCKET"></a></p> 2033<h4><code>ERR_FS_CP_SOCKET</code><span><a class="mark" href="#err_fs_cp_socket" id="err_fs_cp_socket">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_fs_cp_socket"></a></h4> 2034<!-- 2035added: v16.7.0 2036--> 2037<p>An attempt was made to copy to a socket with <a href="fs.html#fscpsrc-dest-options-callback"><code>fs.cp()</code></a>.</p> 2038<p><a id="ERR_FS_CP_SYMLINK_TO_SUBDIRECTORY"></a></p> 2039<h4><code>ERR_FS_CP_SYMLINK_TO_SUBDIRECTORY</code><span><a class="mark" href="#err_fs_cp_symlink_to_subdirectory" id="err_fs_cp_symlink_to_subdirectory">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_fs_cp_symlink_to_subdirectory"></a></h4> 2040<!-- 2041added: v16.7.0 2042--> 2043<p>When using <a href="fs.html#fscpsrc-dest-options-callback"><code>fs.cp()</code></a>, a symlink in <code>dest</code> pointed to a subdirectory 2044of <code>src</code>.</p> 2045<p><a id="ERR_FS_CP_UNKNOWN"></a></p> 2046<h4><code>ERR_FS_CP_UNKNOWN</code><span><a class="mark" href="#err_fs_cp_unknown" id="err_fs_cp_unknown">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_fs_cp_unknown"></a></h4> 2047<!-- 2048added: v16.7.0 2049--> 2050<p>An attempt was made to copy to an unknown file type with <a href="fs.html#fscpsrc-dest-options-callback"><code>fs.cp()</code></a>.</p> 2051<p><a id="ERR_FS_EISDIR"></a></p> 2052<h4><code>ERR_FS_EISDIR</code><span><a class="mark" href="#err_fs_eisdir" id="err_fs_eisdir">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_fs_eisdir"></a></h4> 2053<p>Path is a directory.</p> 2054<p><a id="ERR_FS_FILE_TOO_LARGE"></a></p> 2055<h4><code>ERR_FS_FILE_TOO_LARGE</code><span><a class="mark" href="#err_fs_file_too_large" id="err_fs_file_too_large">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_fs_file_too_large"></a></h4> 2056<p>An attempt has been made to read a file whose size is larger than the maximum 2057allowed size for a <code>Buffer</code>.</p> 2058<p><a id="ERR_FS_INVALID_SYMLINK_TYPE"></a></p> 2059<h4><code>ERR_FS_INVALID_SYMLINK_TYPE</code><span><a class="mark" href="#err_fs_invalid_symlink_type" id="err_fs_invalid_symlink_type">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_fs_invalid_symlink_type"></a></h4> 2060<p>An invalid symlink type was passed to the <a href="fs.html#fssymlinktarget-path-type-callback"><code>fs.symlink()</code></a> or 2061<a href="fs.html#fssymlinksynctarget-path-type"><code>fs.symlinkSync()</code></a> methods.</p> 2062<p><a id="ERR_HTTP_HEADERS_SENT"></a></p> 2063<h4><code>ERR_HTTP_HEADERS_SENT</code><span><a class="mark" href="#err_http_headers_sent" id="err_http_headers_sent">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http_headers_sent"></a></h4> 2064<p>An attempt was made to add more headers after the headers had already been sent.</p> 2065<p><a id="ERR_HTTP_INVALID_HEADER_VALUE"></a></p> 2066<h4><code>ERR_HTTP_INVALID_HEADER_VALUE</code><span><a class="mark" href="#err_http_invalid_header_value" id="err_http_invalid_header_value">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http_invalid_header_value"></a></h4> 2067<p>An invalid HTTP header value was specified.</p> 2068<p><a id="ERR_HTTP_INVALID_STATUS_CODE"></a></p> 2069<h4><code>ERR_HTTP_INVALID_STATUS_CODE</code><span><a class="mark" href="#err_http_invalid_status_code" id="err_http_invalid_status_code">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http_invalid_status_code"></a></h4> 2070<p>Status code was outside the regular status code range (100-999).</p> 2071<p><a id="ERR_HTTP_REQUEST_TIMEOUT"></a></p> 2072<h4><code>ERR_HTTP_REQUEST_TIMEOUT</code><span><a class="mark" href="#err_http_request_timeout" id="err_http_request_timeout">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http_request_timeout"></a></h4> 2073<p>The client has not sent the entire request within the allowed time.</p> 2074<p><a id="ERR_HTTP_SOCKET_ASSIGNED"></a></p> 2075<h4><code>ERR_HTTP_SOCKET_ASSIGNED</code><span><a class="mark" href="#err_http_socket_assigned" id="err_http_socket_assigned">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http_socket_assigned"></a></h4> 2076<p>The given <a href="http.html#class-httpserverresponse"><code>ServerResponse</code></a> was already assigned a socket.</p> 2077<p><a id="ERR_HTTP_SOCKET_ENCODING"></a></p> 2078<h4><code>ERR_HTTP_SOCKET_ENCODING</code><span><a class="mark" href="#err_http_socket_encoding" id="err_http_socket_encoding">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http_socket_encoding"></a></h4> 2079<p>Changing the socket encoding is not allowed per <a href="https://tools.ietf.org/html/rfc7230#section-3">RFC 7230 Section 3</a>.</p> 2080<p><a id="ERR_HTTP_TRAILER_INVALID"></a></p> 2081<h4><code>ERR_HTTP_TRAILER_INVALID</code><span><a class="mark" href="#err_http_trailer_invalid" id="err_http_trailer_invalid">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http_trailer_invalid"></a></h4> 2082<p>The <code>Trailer</code> header was set even though the transfer encoding does not support 2083that.</p> 2084<p><a id="ERR_HTTP2_ALTSVC_INVALID_ORIGIN"></a></p> 2085<h4><code>ERR_HTTP2_ALTSVC_INVALID_ORIGIN</code><span><a class="mark" href="#err_http2_altsvc_invalid_origin" id="err_http2_altsvc_invalid_origin">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_altsvc_invalid_origin"></a></h4> 2086<p>HTTP/2 ALTSVC frames require a valid origin.</p> 2087<p><a id="ERR_HTTP2_ALTSVC_LENGTH"></a></p> 2088<h4><code>ERR_HTTP2_ALTSVC_LENGTH</code><span><a class="mark" href="#err_http2_altsvc_length" id="err_http2_altsvc_length">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_altsvc_length"></a></h4> 2089<p>HTTP/2 ALTSVC frames are limited to a maximum of 16,382 payload bytes.</p> 2090<p><a id="ERR_HTTP2_CONNECT_AUTHORITY"></a></p> 2091<h4><code>ERR_HTTP2_CONNECT_AUTHORITY</code><span><a class="mark" href="#err_http2_connect_authority" id="err_http2_connect_authority">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_connect_authority"></a></h4> 2092<p>For HTTP/2 requests using the <code>CONNECT</code> method, the <code>:authority</code> pseudo-header 2093is required.</p> 2094<p><a id="ERR_HTTP2_CONNECT_PATH"></a></p> 2095<h4><code>ERR_HTTP2_CONNECT_PATH</code><span><a class="mark" href="#err_http2_connect_path" id="err_http2_connect_path">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_connect_path"></a></h4> 2096<p>For HTTP/2 requests using the <code>CONNECT</code> method, the <code>:path</code> pseudo-header is 2097forbidden.</p> 2098<p><a id="ERR_HTTP2_CONNECT_SCHEME"></a></p> 2099<h4><code>ERR_HTTP2_CONNECT_SCHEME</code><span><a class="mark" href="#err_http2_connect_scheme" id="err_http2_connect_scheme">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_connect_scheme"></a></h4> 2100<p>For HTTP/2 requests using the <code>CONNECT</code> method, the <code>:scheme</code> pseudo-header is 2101forbidden.</p> 2102<p><a id="ERR_HTTP2_ERROR"></a></p> 2103<h4><code>ERR_HTTP2_ERROR</code><span><a class="mark" href="#err_http2_error" id="err_http2_error">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_error"></a></h4> 2104<p>A non-specific HTTP/2 error has occurred.</p> 2105<p><a id="ERR_HTTP2_GOAWAY_SESSION"></a></p> 2106<h4><code>ERR_HTTP2_GOAWAY_SESSION</code><span><a class="mark" href="#err_http2_goaway_session" id="err_http2_goaway_session">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_goaway_session"></a></h4> 2107<p>New HTTP/2 Streams may not be opened after the <code>Http2Session</code> has received a 2108<code>GOAWAY</code> frame from the connected peer.</p> 2109<p><a id="ERR_HTTP2_HEADER_SINGLE_VALUE"></a></p> 2110<h4><code>ERR_HTTP2_HEADER_SINGLE_VALUE</code><span><a class="mark" href="#err_http2_header_single_value" id="err_http2_header_single_value">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_header_single_value"></a></h4> 2111<p>Multiple values were provided for an HTTP/2 header field that was required to 2112have only a single value.</p> 2113<p><a id="ERR_HTTP2_HEADERS_AFTER_RESPOND"></a></p> 2114<h4><code>ERR_HTTP2_HEADERS_AFTER_RESPOND</code><span><a class="mark" href="#err_http2_headers_after_respond" id="err_http2_headers_after_respond">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_headers_after_respond"></a></h4> 2115<p>An additional headers was specified after an HTTP/2 response was initiated.</p> 2116<p><a id="ERR_HTTP2_HEADERS_SENT"></a></p> 2117<h4><code>ERR_HTTP2_HEADERS_SENT</code><span><a class="mark" href="#err_http2_headers_sent" id="err_http2_headers_sent">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_headers_sent"></a></h4> 2118<p>An attempt was made to send multiple response headers.</p> 2119<p><a id="ERR_HTTP2_INFO_STATUS_NOT_ALLOWED"></a></p> 2120<h4><code>ERR_HTTP2_INFO_STATUS_NOT_ALLOWED</code><span><a class="mark" href="#err_http2_info_status_not_allowed" id="err_http2_info_status_not_allowed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_info_status_not_allowed"></a></h4> 2121<p>Informational HTTP status codes (<code>1xx</code>) may not be set as the response status 2122code on HTTP/2 responses.</p> 2123<p><a id="ERR_HTTP2_INVALID_CONNECTION_HEADERS"></a></p> 2124<h4><code>ERR_HTTP2_INVALID_CONNECTION_HEADERS</code><span><a class="mark" href="#err_http2_invalid_connection_headers" id="err_http2_invalid_connection_headers">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_invalid_connection_headers"></a></h4> 2125<p>HTTP/1 connection specific headers are forbidden to be used in HTTP/2 2126requests and responses.</p> 2127<p><a id="ERR_HTTP2_INVALID_HEADER_VALUE"></a></p> 2128<h4><code>ERR_HTTP2_INVALID_HEADER_VALUE</code><span><a class="mark" href="#err_http2_invalid_header_value" id="err_http2_invalid_header_value">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_invalid_header_value"></a></h4> 2129<p>An invalid HTTP/2 header value was specified.</p> 2130<p><a id="ERR_HTTP2_INVALID_INFO_STATUS"></a></p> 2131<h4><code>ERR_HTTP2_INVALID_INFO_STATUS</code><span><a class="mark" href="#err_http2_invalid_info_status" id="err_http2_invalid_info_status">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_invalid_info_status"></a></h4> 2132<p>An invalid HTTP informational status code has been specified. Informational 2133status codes must be an integer between <code>100</code> and <code>199</code> (inclusive).</p> 2134<p><a id="ERR_HTTP2_INVALID_ORIGIN"></a></p> 2135<h4><code>ERR_HTTP2_INVALID_ORIGIN</code><span><a class="mark" href="#err_http2_invalid_origin" id="err_http2_invalid_origin">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_invalid_origin"></a></h4> 2136<p>HTTP/2 <code>ORIGIN</code> frames require a valid origin.</p> 2137<p><a id="ERR_HTTP2_INVALID_PACKED_SETTINGS_LENGTH"></a></p> 2138<h4><code>ERR_HTTP2_INVALID_PACKED_SETTINGS_LENGTH</code><span><a class="mark" href="#err_http2_invalid_packed_settings_length" id="err_http2_invalid_packed_settings_length">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_invalid_packed_settings_length"></a></h4> 2139<p>Input <code>Buffer</code> and <code>Uint8Array</code> instances passed to the 2140<code>http2.getUnpackedSettings()</code> API must have a length that is a multiple of 2141six.</p> 2142<p><a id="ERR_HTTP2_INVALID_PSEUDOHEADER"></a></p> 2143<h4><code>ERR_HTTP2_INVALID_PSEUDOHEADER</code><span><a class="mark" href="#err_http2_invalid_pseudoheader" id="err_http2_invalid_pseudoheader">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_invalid_pseudoheader"></a></h4> 2144<p>Only valid HTTP/2 pseudoheaders (<code>:status</code>, <code>:path</code>, <code>:authority</code>, <code>:scheme</code>, 2145and <code>:method</code>) may be used.</p> 2146<p><a id="ERR_HTTP2_INVALID_SESSION"></a></p> 2147<h4><code>ERR_HTTP2_INVALID_SESSION</code><span><a class="mark" href="#err_http2_invalid_session" id="err_http2_invalid_session">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_invalid_session"></a></h4> 2148<p>An action was performed on an <code>Http2Session</code> object that had already been 2149destroyed.</p> 2150<p><a id="ERR_HTTP2_INVALID_SETTING_VALUE"></a></p> 2151<h4><code>ERR_HTTP2_INVALID_SETTING_VALUE</code><span><a class="mark" href="#err_http2_invalid_setting_value" id="err_http2_invalid_setting_value">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_invalid_setting_value"></a></h4> 2152<p>An invalid value has been specified for an HTTP/2 setting.</p> 2153<p><a id="ERR_HTTP2_INVALID_STREAM"></a></p> 2154<h4><code>ERR_HTTP2_INVALID_STREAM</code><span><a class="mark" href="#err_http2_invalid_stream" id="err_http2_invalid_stream">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_invalid_stream"></a></h4> 2155<p>An operation was performed on a stream that had already been destroyed.</p> 2156<p><a id="ERR_HTTP2_MAX_PENDING_SETTINGS_ACK"></a></p> 2157<h4><code>ERR_HTTP2_MAX_PENDING_SETTINGS_ACK</code><span><a class="mark" href="#err_http2_max_pending_settings_ack" id="err_http2_max_pending_settings_ack">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_max_pending_settings_ack"></a></h4> 2158<p>Whenever an HTTP/2 <code>SETTINGS</code> frame is sent to a connected peer, the peer is 2159required to send an acknowledgment that it has received and applied the new 2160<code>SETTINGS</code>. By default, a maximum number of unacknowledged <code>SETTINGS</code> frames may 2161be sent at any given time. This error code is used when that limit has been 2162reached.</p> 2163<p><a id="ERR_HTTP2_NESTED_PUSH"></a></p> 2164<h4><code>ERR_HTTP2_NESTED_PUSH</code><span><a class="mark" href="#err_http2_nested_push" id="err_http2_nested_push">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_nested_push"></a></h4> 2165<p>An attempt was made to initiate a new push stream from within a push stream. 2166Nested push streams are not permitted.</p> 2167<p><a id="ERR_HTTP2_NO_MEM"></a></p> 2168<h4><code>ERR_HTTP2_NO_MEM</code><span><a class="mark" href="#err_http2_no_mem" id="err_http2_no_mem">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_no_mem"></a></h4> 2169<p>Out of memory when using the <code>http2session.setLocalWindowSize(windowSize)</code> API.</p> 2170<p><a id="ERR_HTTP2_NO_SOCKET_MANIPULATION"></a></p> 2171<h4><code>ERR_HTTP2_NO_SOCKET_MANIPULATION</code><span><a class="mark" href="#err_http2_no_socket_manipulation" id="err_http2_no_socket_manipulation">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_no_socket_manipulation"></a></h4> 2172<p>An attempt was made to directly manipulate (read, write, pause, resume, etc.) a 2173socket attached to an <code>Http2Session</code>.</p> 2174<p><a id="ERR_HTTP2_ORIGIN_LENGTH"></a></p> 2175<h4><code>ERR_HTTP2_ORIGIN_LENGTH</code><span><a class="mark" href="#err_http2_origin_length" id="err_http2_origin_length">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_origin_length"></a></h4> 2176<p>HTTP/2 <code>ORIGIN</code> frames are limited to a length of 16382 bytes.</p> 2177<p><a id="ERR_HTTP2_OUT_OF_STREAMS"></a></p> 2178<h4><code>ERR_HTTP2_OUT_OF_STREAMS</code><span><a class="mark" href="#err_http2_out_of_streams" id="err_http2_out_of_streams">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_out_of_streams"></a></h4> 2179<p>The number of streams created on a single HTTP/2 session reached the maximum 2180limit.</p> 2181<p><a id="ERR_HTTP2_PAYLOAD_FORBIDDEN"></a></p> 2182<h4><code>ERR_HTTP2_PAYLOAD_FORBIDDEN</code><span><a class="mark" href="#err_http2_payload_forbidden" id="err_http2_payload_forbidden">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_payload_forbidden"></a></h4> 2183<p>A message payload was specified for an HTTP response code for which a payload is 2184forbidden.</p> 2185<p><a id="ERR_HTTP2_PING_CANCEL"></a></p> 2186<h4><code>ERR_HTTP2_PING_CANCEL</code><span><a class="mark" href="#err_http2_ping_cancel" id="err_http2_ping_cancel">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_ping_cancel"></a></h4> 2187<p>An HTTP/2 ping was canceled.</p> 2188<p><a id="ERR_HTTP2_PING_LENGTH"></a></p> 2189<h4><code>ERR_HTTP2_PING_LENGTH</code><span><a class="mark" href="#err_http2_ping_length" id="err_http2_ping_length">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_ping_length"></a></h4> 2190<p>HTTP/2 ping payloads must be exactly 8 bytes in length.</p> 2191<p><a id="ERR_HTTP2_PSEUDOHEADER_NOT_ALLOWED"></a></p> 2192<h4><code>ERR_HTTP2_PSEUDOHEADER_NOT_ALLOWED</code><span><a class="mark" href="#err_http2_pseudoheader_not_allowed" id="err_http2_pseudoheader_not_allowed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_pseudoheader_not_allowed"></a></h4> 2193<p>An HTTP/2 pseudo-header has been used inappropriately. Pseudo-headers are header 2194key names that begin with the <code>:</code> prefix.</p> 2195<p><a id="ERR_HTTP2_PUSH_DISABLED"></a></p> 2196<h4><code>ERR_HTTP2_PUSH_DISABLED</code><span><a class="mark" href="#err_http2_push_disabled" id="err_http2_push_disabled">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_push_disabled"></a></h4> 2197<p>An attempt was made to create a push stream, which had been disabled by the 2198client.</p> 2199<p><a id="ERR_HTTP2_SEND_FILE"></a></p> 2200<h4><code>ERR_HTTP2_SEND_FILE</code><span><a class="mark" href="#err_http2_send_file" id="err_http2_send_file">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_send_file"></a></h4> 2201<p>An attempt was made to use the <code>Http2Stream.prototype.responseWithFile()</code> API to 2202send a directory.</p> 2203<p><a id="ERR_HTTP2_SEND_FILE_NOSEEK"></a></p> 2204<h4><code>ERR_HTTP2_SEND_FILE_NOSEEK</code><span><a class="mark" href="#err_http2_send_file_noseek" id="err_http2_send_file_noseek">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_send_file_noseek"></a></h4> 2205<p>An attempt was made to use the <code>Http2Stream.prototype.responseWithFile()</code> API to 2206send something other than a regular file, but <code>offset</code> or <code>length</code> options were 2207provided.</p> 2208<p><a id="ERR_HTTP2_SESSION_ERROR"></a></p> 2209<h4><code>ERR_HTTP2_SESSION_ERROR</code><span><a class="mark" href="#err_http2_session_error" id="err_http2_session_error">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_session_error"></a></h4> 2210<p>The <code>Http2Session</code> closed with a non-zero error code.</p> 2211<p><a id="ERR_HTTP2_SETTINGS_CANCEL"></a></p> 2212<h4><code>ERR_HTTP2_SETTINGS_CANCEL</code><span><a class="mark" href="#err_http2_settings_cancel" id="err_http2_settings_cancel">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_settings_cancel"></a></h4> 2213<p>The <code>Http2Session</code> settings canceled.</p> 2214<p><a id="ERR_HTTP2_SOCKET_BOUND"></a></p> 2215<h4><code>ERR_HTTP2_SOCKET_BOUND</code><span><a class="mark" href="#err_http2_socket_bound" id="err_http2_socket_bound">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_socket_bound"></a></h4> 2216<p>An attempt was made to connect a <code>Http2Session</code> object to a <code>net.Socket</code> or 2217<code>tls.TLSSocket</code> that had already been bound to another <code>Http2Session</code> object.</p> 2218<p><a id="ERR_HTTP2_SOCKET_UNBOUND"></a></p> 2219<h4><code>ERR_HTTP2_SOCKET_UNBOUND</code><span><a class="mark" href="#err_http2_socket_unbound" id="err_http2_socket_unbound">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_socket_unbound"></a></h4> 2220<p>An attempt was made to use the <code>socket</code> property of an <code>Http2Session</code> that 2221has already been closed.</p> 2222<p><a id="ERR_HTTP2_STATUS_101"></a></p> 2223<h4><code>ERR_HTTP2_STATUS_101</code><span><a class="mark" href="#err_http2_status_101" id="err_http2_status_101">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_status_101"></a></h4> 2224<p>Use of the <code>101</code> Informational status code is forbidden in HTTP/2.</p> 2225<p><a id="ERR_HTTP2_STATUS_INVALID"></a></p> 2226<h4><code>ERR_HTTP2_STATUS_INVALID</code><span><a class="mark" href="#err_http2_status_invalid" id="err_http2_status_invalid">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_status_invalid"></a></h4> 2227<p>An invalid HTTP status code has been specified. Status codes must be an integer 2228between <code>100</code> and <code>599</code> (inclusive).</p> 2229<p><a id="ERR_HTTP2_STREAM_CANCEL"></a></p> 2230<h4><code>ERR_HTTP2_STREAM_CANCEL</code><span><a class="mark" href="#err_http2_stream_cancel" id="err_http2_stream_cancel">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_stream_cancel"></a></h4> 2231<p>An <code>Http2Stream</code> was destroyed before any data was transmitted to the connected 2232peer.</p> 2233<p><a id="ERR_HTTP2_STREAM_ERROR"></a></p> 2234<h4><code>ERR_HTTP2_STREAM_ERROR</code><span><a class="mark" href="#err_http2_stream_error" id="err_http2_stream_error">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_stream_error"></a></h4> 2235<p>A non-zero error code was been specified in an <code>RST_STREAM</code> frame.</p> 2236<p><a id="ERR_HTTP2_STREAM_SELF_DEPENDENCY"></a></p> 2237<h4><code>ERR_HTTP2_STREAM_SELF_DEPENDENCY</code><span><a class="mark" href="#err_http2_stream_self_dependency" id="err_http2_stream_self_dependency">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_stream_self_dependency"></a></h4> 2238<p>When setting the priority for an HTTP/2 stream, the stream may be marked as 2239a dependency for a parent stream. This error code is used when an attempt is 2240made to mark a stream and dependent of itself.</p> 2241<p><a id="ERR_HTTP2_TOO_MANY_INVALID_FRAMES"></a></p> 2242<h4><code>ERR_HTTP2_TOO_MANY_INVALID_FRAMES</code><span><a class="mark" href="#err_http2_too_many_invalid_frames" id="err_http2_too_many_invalid_frames">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_too_many_invalid_frames"></a></h4> 2243<!-- 2244added: v15.14.0 2245--> 2246<p>The limit of acceptable invalid HTTP/2 protocol frames sent by the peer, 2247as specified through the <code>maxSessionInvalidFrames</code> option, has been exceeded.</p> 2248<p><a id="ERR_HTTP2_TRAILERS_ALREADY_SENT"></a></p> 2249<h4><code>ERR_HTTP2_TRAILERS_ALREADY_SENT</code><span><a class="mark" href="#err_http2_trailers_already_sent" id="err_http2_trailers_already_sent">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_trailers_already_sent"></a></h4> 2250<p>Trailing headers have already been sent on the <code>Http2Stream</code>.</p> 2251<p><a id="ERR_HTTP2_TRAILERS_NOT_READY"></a></p> 2252<h4><code>ERR_HTTP2_TRAILERS_NOT_READY</code><span><a class="mark" href="#err_http2_trailers_not_ready" id="err_http2_trailers_not_ready">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_trailers_not_ready"></a></h4> 2253<p>The <code>http2stream.sendTrailers()</code> method cannot be called until after the 2254<code>'wantTrailers'</code> event is emitted on an <code>Http2Stream</code> object. The 2255<code>'wantTrailers'</code> event will only be emitted if the <code>waitForTrailers</code> option 2256is set for the <code>Http2Stream</code>.</p> 2257<p><a id="ERR_HTTP2_UNSUPPORTED_PROTOCOL"></a></p> 2258<h4><code>ERR_HTTP2_UNSUPPORTED_PROTOCOL</code><span><a class="mark" href="#err_http2_unsupported_protocol" id="err_http2_unsupported_protocol">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_unsupported_protocol"></a></h4> 2259<p><code>http2.connect()</code> was passed a URL that uses any protocol other than <code>http:</code> or 2260<code>https:</code>.</p> 2261<p><a id="ERR_ILLEGAL_CONSTRUCTOR"></a></p> 2262<h4><code>ERR_ILLEGAL_CONSTRUCTOR</code><span><a class="mark" href="#err_illegal_constructor" id="err_illegal_constructor">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_illegal_constructor"></a></h4> 2263<p>An attempt was made to construct an object using a non-public constructor.</p> 2264<p><a id="ERR_IMPORT_ASSERTION_TYPE_FAILED"></a></p> 2265<h4><code>ERR_IMPORT_ASSERTION_TYPE_FAILED</code><span><a class="mark" href="#err_import_assertion_type_failed" id="err_import_assertion_type_failed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_import_assertion_type_failed"></a></h4> 2266<div class="api_metadata"> 2267<span>Added in: v17.1.0, v16.14.0</span> 2268</div> 2269<p>An import assertion has failed, preventing the specified module to be imported.</p> 2270<p><a id="ERR_IMPORT_ASSERTION_TYPE_MISSING"></a></p> 2271<h4><code>ERR_IMPORT_ASSERTION_TYPE_MISSING</code><span><a class="mark" href="#err_import_assertion_type_missing" id="err_import_assertion_type_missing">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_import_assertion_type_missing"></a></h4> 2272<div class="api_metadata"> 2273<span>Added in: v17.1.0, v16.14.0</span> 2274</div> 2275<p>An import assertion is missing, preventing the specified module to be imported.</p> 2276<p><a id="ERR_IMPORT_ASSERTION_TYPE_UNSUPPORTED"></a></p> 2277<h4><code>ERR_IMPORT_ASSERTION_TYPE_UNSUPPORTED</code><span><a class="mark" href="#err_import_assertion_type_unsupported" id="err_import_assertion_type_unsupported">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_import_assertion_type_unsupported"></a></h4> 2278<div class="api_metadata"> 2279<span>Added in: v17.1.0, v16.14.0</span> 2280</div> 2281<p>An import assertion is not supported by this version of Node.js.</p> 2282<p><a id="ERR_INCOMPATIBLE_OPTION_PAIR"></a></p> 2283<h4><code>ERR_INCOMPATIBLE_OPTION_PAIR</code><span><a class="mark" href="#err_incompatible_option_pair" id="err_incompatible_option_pair">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_incompatible_option_pair"></a></h4> 2284<p>An option pair is incompatible with each other and cannot be used at the same 2285time.</p> 2286<p><a id="ERR_INPUT_TYPE_NOT_ALLOWED"></a></p> 2287<h4><code>ERR_INPUT_TYPE_NOT_ALLOWED</code><span><a class="mark" href="#err_input_type_not_allowed" id="err_input_type_not_allowed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_input_type_not_allowed"></a></h4> 2288<p></p><div class="api_stability api_stability_1"><a href="documentation.html#stability-index">Stability: 1</a> - Experimental</div><p></p> 2289<p>The <code>--input-type</code> flag was used to attempt to execute a file. This flag can 2290only be used with input via <code>--eval</code>, <code>--print</code>, or <code>STDIN</code>.</p> 2291<p><a id="ERR_INSPECTOR_ALREADY_ACTIVATED"></a></p> 2292<h4><code>ERR_INSPECTOR_ALREADY_ACTIVATED</code><span><a class="mark" href="#err_inspector_already_activated" id="err_inspector_already_activated">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_inspector_already_activated"></a></h4> 2293<p>While using the <code>node:inspector</code> module, an attempt was made to activate the 2294inspector when it already started to listen on a port. Use <code>inspector.close()</code> 2295before activating it on a different address.</p> 2296<p><a id="ERR_INSPECTOR_ALREADY_CONNECTED"></a></p> 2297<h4><code>ERR_INSPECTOR_ALREADY_CONNECTED</code><span><a class="mark" href="#err_inspector_already_connected" id="err_inspector_already_connected">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_inspector_already_connected"></a></h4> 2298<p>While using the <code>node:inspector</code> module, an attempt was made to connect when the 2299inspector was already connected.</p> 2300<p><a id="ERR_INSPECTOR_CLOSED"></a></p> 2301<h4><code>ERR_INSPECTOR_CLOSED</code><span><a class="mark" href="#err_inspector_closed" id="err_inspector_closed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_inspector_closed"></a></h4> 2302<p>While using the <code>node:inspector</code> module, an attempt was made to use the 2303inspector after the session had already closed.</p> 2304<p><a id="ERR_INSPECTOR_COMMAND"></a></p> 2305<h4><code>ERR_INSPECTOR_COMMAND</code><span><a class="mark" href="#err_inspector_command" id="err_inspector_command">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_inspector_command"></a></h4> 2306<p>An error occurred while issuing a command via the <code>node:inspector</code> module.</p> 2307<p><a id="ERR_INSPECTOR_NOT_ACTIVE"></a></p> 2308<h4><code>ERR_INSPECTOR_NOT_ACTIVE</code><span><a class="mark" href="#err_inspector_not_active" id="err_inspector_not_active">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_inspector_not_active"></a></h4> 2309<p>The <code>inspector</code> is not active when <code>inspector.waitForDebugger()</code> is called.</p> 2310<p><a id="ERR_INSPECTOR_NOT_AVAILABLE"></a></p> 2311<h4><code>ERR_INSPECTOR_NOT_AVAILABLE</code><span><a class="mark" href="#err_inspector_not_available" id="err_inspector_not_available">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_inspector_not_available"></a></h4> 2312<p>The <code>node:inspector</code> module is not available for use.</p> 2313<p><a id="ERR_INSPECTOR_NOT_CONNECTED"></a></p> 2314<h4><code>ERR_INSPECTOR_NOT_CONNECTED</code><span><a class="mark" href="#err_inspector_not_connected" id="err_inspector_not_connected">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_inspector_not_connected"></a></h4> 2315<p>While using the <code>node:inspector</code> module, an attempt was made to use the 2316inspector before it was connected.</p> 2317<p><a id="ERR_INSPECTOR_NOT_WORKER"></a></p> 2318<h4><code>ERR_INSPECTOR_NOT_WORKER</code><span><a class="mark" href="#err_inspector_not_worker" id="err_inspector_not_worker">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_inspector_not_worker"></a></h4> 2319<p>An API was called on the main thread that can only be used from 2320the worker thread.</p> 2321<p><a id="ERR_INTERNAL_ASSERTION"></a></p> 2322<h4><code>ERR_INTERNAL_ASSERTION</code><span><a class="mark" href="#err_internal_assertion" id="err_internal_assertion">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_internal_assertion"></a></h4> 2323<p>There was a bug in Node.js or incorrect usage of Node.js internals. 2324To fix the error, open an issue at <a href="https://github.com/nodejs/node/issues">https://github.com/nodejs/node/issues</a>.</p> 2325<p><a id="ERR_INVALID_ADDRESS_FAMILY"></a></p> 2326<h4><code>ERR_INVALID_ADDRESS_FAMILY</code><span><a class="mark" href="#err_invalid_address_family" id="err_invalid_address_family">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_address_family"></a></h4> 2327<p>The provided address family is not understood by the Node.js API.</p> 2328<p><a id="ERR_INVALID_ARG_TYPE"></a></p> 2329<h4><code>ERR_INVALID_ARG_TYPE</code><span><a class="mark" href="#err_invalid_arg_type" id="err_invalid_arg_type">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_arg_type"></a></h4> 2330<p>An argument of the wrong type was passed to a Node.js API.</p> 2331<p><a id="ERR_INVALID_ARG_VALUE"></a></p> 2332<h4><code>ERR_INVALID_ARG_VALUE</code><span><a class="mark" href="#err_invalid_arg_value" id="err_invalid_arg_value">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_arg_value"></a></h4> 2333<p>An invalid or unsupported value was passed for a given argument.</p> 2334<p><a id="ERR_INVALID_ASYNC_ID"></a></p> 2335<h4><code>ERR_INVALID_ASYNC_ID</code><span><a class="mark" href="#err_invalid_async_id" id="err_invalid_async_id">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_async_id"></a></h4> 2336<p>An invalid <code>asyncId</code> or <code>triggerAsyncId</code> was passed using <code>AsyncHooks</code>. An id 2337less than -1 should never happen.</p> 2338<p><a id="ERR_INVALID_BUFFER_SIZE"></a></p> 2339<h4><code>ERR_INVALID_BUFFER_SIZE</code><span><a class="mark" href="#err_invalid_buffer_size" id="err_invalid_buffer_size">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_buffer_size"></a></h4> 2340<p>A swap was performed on a <code>Buffer</code> but its size was not compatible with the 2341operation.</p> 2342<p><a id="ERR_INVALID_CHAR"></a></p> 2343<h4><code>ERR_INVALID_CHAR</code><span><a class="mark" href="#err_invalid_char" id="err_invalid_char">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_char"></a></h4> 2344<p>Invalid characters were detected in headers.</p> 2345<p><a id="ERR_INVALID_CURSOR_POS"></a></p> 2346<h4><code>ERR_INVALID_CURSOR_POS</code><span><a class="mark" href="#err_invalid_cursor_pos" id="err_invalid_cursor_pos">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_cursor_pos"></a></h4> 2347<p>A cursor on a given stream cannot be moved to a specified row without a 2348specified column.</p> 2349<p><a id="ERR_INVALID_FD"></a></p> 2350<h4><code>ERR_INVALID_FD</code><span><a class="mark" href="#err_invalid_fd" id="err_invalid_fd">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_fd"></a></h4> 2351<p>A file descriptor ('fd') was not valid (e.g. it was a negative value).</p> 2352<p><a id="ERR_INVALID_FD_TYPE"></a></p> 2353<h4><code>ERR_INVALID_FD_TYPE</code><span><a class="mark" href="#err_invalid_fd_type" id="err_invalid_fd_type">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_fd_type"></a></h4> 2354<p>A file descriptor ('fd') type was not valid.</p> 2355<p><a id="ERR_INVALID_FILE_URL_HOST"></a></p> 2356<h4><code>ERR_INVALID_FILE_URL_HOST</code><span><a class="mark" href="#err_invalid_file_url_host" id="err_invalid_file_url_host">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_file_url_host"></a></h4> 2357<p>A Node.js API that consumes <code>file:</code> URLs (such as certain functions in the 2358<a href="fs.html"><code>fs</code></a> module) encountered a file URL with an incompatible host. This 2359situation can only occur on Unix-like systems where only <code>localhost</code> or an empty 2360host is supported.</p> 2361<p><a id="ERR_INVALID_FILE_URL_PATH"></a></p> 2362<h4><code>ERR_INVALID_FILE_URL_PATH</code><span><a class="mark" href="#err_invalid_file_url_path" id="err_invalid_file_url_path">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_file_url_path"></a></h4> 2363<p>A Node.js API that consumes <code>file:</code> URLs (such as certain functions in the 2364<a href="fs.html"><code>fs</code></a> module) encountered a file URL with an incompatible path. The exact 2365semantics for determining whether a path can be used is platform-dependent.</p> 2366<p><a id="ERR_INVALID_HANDLE_TYPE"></a></p> 2367<h4><code>ERR_INVALID_HANDLE_TYPE</code><span><a class="mark" href="#err_invalid_handle_type" id="err_invalid_handle_type">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_handle_type"></a></h4> 2368<p>An attempt was made to send an unsupported "handle" over an IPC communication 2369channel to a child process. See <a href="child_process.html#subprocesssendmessage-sendhandle-options-callback"><code>subprocess.send()</code></a> and <a href="process.html#processsendmessage-sendhandle-options-callback"><code>process.send()</code></a> 2370for more information.</p> 2371<p><a id="ERR_INVALID_HTTP_TOKEN"></a></p> 2372<h4><code>ERR_INVALID_HTTP_TOKEN</code><span><a class="mark" href="#err_invalid_http_token" id="err_invalid_http_token">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_http_token"></a></h4> 2373<p>An invalid HTTP token was supplied.</p> 2374<p><a id="ERR_INVALID_IP_ADDRESS"></a></p> 2375<h4><code>ERR_INVALID_IP_ADDRESS</code><span><a class="mark" href="#err_invalid_ip_address" id="err_invalid_ip_address">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_ip_address"></a></h4> 2376<p>An IP address is not valid.</p> 2377<p><a id="ERR_INVALID_MIME_SYNTAX"></a></p> 2378<h4><code>ERR_INVALID_MIME_SYNTAX</code><span><a class="mark" href="#err_invalid_mime_syntax" id="err_invalid_mime_syntax">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_mime_syntax"></a></h4> 2379<p>The syntax of a MIME is not valid.</p> 2380<p><a id="ERR_INVALID_MODULE"></a></p> 2381<h4><code>ERR_INVALID_MODULE</code><span><a class="mark" href="#err_invalid_module" id="err_invalid_module">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_module"></a></h4> 2382<div class="api_metadata"> 2383<span>Added in: v15.0.0, v14.18.0</span> 2384</div> 2385<p>An attempt was made to load a module that does not exist or was otherwise not 2386valid.</p> 2387<p><a id="ERR_INVALID_MODULE_SPECIFIER"></a></p> 2388<h4><code>ERR_INVALID_MODULE_SPECIFIER</code><span><a class="mark" href="#err_invalid_module_specifier" id="err_invalid_module_specifier">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_module_specifier"></a></h4> 2389<p>The imported module string is an invalid URL, package name, or package subpath 2390specifier.</p> 2391<p><a id="ERR_INVALID_OBJECT_DEFINE_PROPERTY"></a></p> 2392<h4><code>ERR_INVALID_OBJECT_DEFINE_PROPERTY</code><span><a class="mark" href="#err_invalid_object_define_property" id="err_invalid_object_define_property">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_object_define_property"></a></h4> 2393<p>An error occurred while setting an invalid attribute on the property of 2394an object.</p> 2395<p><a id="ERR_INVALID_PACKAGE_CONFIG"></a></p> 2396<h4><code>ERR_INVALID_PACKAGE_CONFIG</code><span><a class="mark" href="#err_invalid_package_config" id="err_invalid_package_config">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_package_config"></a></h4> 2397<p>An invalid <a href="packages.html#nodejs-packagejson-field-definitions"><code>package.json</code></a> file failed parsing.</p> 2398<p><a id="ERR_INVALID_PACKAGE_TARGET"></a></p> 2399<h4><code>ERR_INVALID_PACKAGE_TARGET</code><span><a class="mark" href="#err_invalid_package_target" id="err_invalid_package_target">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_package_target"></a></h4> 2400<p>The <code>package.json</code> <a href="packages.html#exports"><code>"exports"</code></a> field contains an invalid target mapping 2401value for the attempted module resolution.</p> 2402<p><a id="ERR_INVALID_PERFORMANCE_MARK"></a></p> 2403<h4><code>ERR_INVALID_PERFORMANCE_MARK</code><span><a class="mark" href="#err_invalid_performance_mark" id="err_invalid_performance_mark">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_performance_mark"></a></h4> 2404<p>While using the Performance Timing API (<code>perf_hooks</code>), a performance mark is 2405invalid.</p> 2406<p><a id="ERR_INVALID_PROTOCOL"></a></p> 2407<h4><code>ERR_INVALID_PROTOCOL</code><span><a class="mark" href="#err_invalid_protocol" id="err_invalid_protocol">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_protocol"></a></h4> 2408<p>An invalid <code>options.protocol</code> was passed to <code>http.request()</code>.</p> 2409<p><a id="ERR_INVALID_REPL_EVAL_CONFIG"></a></p> 2410<h4><code>ERR_INVALID_REPL_EVAL_CONFIG</code><span><a class="mark" href="#err_invalid_repl_eval_config" id="err_invalid_repl_eval_config">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_repl_eval_config"></a></h4> 2411<p>Both <code>breakEvalOnSigint</code> and <code>eval</code> options were set in the <a href="repl.html"><code>REPL</code></a> config, 2412which is not supported.</p> 2413<p><a id="ERR_INVALID_REPL_INPUT"></a></p> 2414<h4><code>ERR_INVALID_REPL_INPUT</code><span><a class="mark" href="#err_invalid_repl_input" id="err_invalid_repl_input">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_repl_input"></a></h4> 2415<p>The input may not be used in the <a href="repl.html"><code>REPL</code></a>. The conditions under which this 2416error is used are described in the <a href="repl.html"><code>REPL</code></a> documentation.</p> 2417<p><a id="ERR_INVALID_RETURN_PROPERTY"></a></p> 2418<h4><code>ERR_INVALID_RETURN_PROPERTY</code><span><a class="mark" href="#err_invalid_return_property" id="err_invalid_return_property">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_return_property"></a></h4> 2419<p>Thrown in case a function option does not provide a valid value for one of its 2420returned object properties on execution.</p> 2421<p><a id="ERR_INVALID_RETURN_PROPERTY_VALUE"></a></p> 2422<h4><code>ERR_INVALID_RETURN_PROPERTY_VALUE</code><span><a class="mark" href="#err_invalid_return_property_value" id="err_invalid_return_property_value">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_return_property_value"></a></h4> 2423<p>Thrown in case a function option does not provide an expected value 2424type for one of its returned object properties on execution.</p> 2425<p><a id="ERR_INVALID_RETURN_VALUE"></a></p> 2426<h4><code>ERR_INVALID_RETURN_VALUE</code><span><a class="mark" href="#err_invalid_return_value" id="err_invalid_return_value">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_return_value"></a></h4> 2427<p>Thrown in case a function option does not return an expected value 2428type on execution, such as when a function is expected to return a promise.</p> 2429<p><a id="ERR_INVALID_STATE"></a></p> 2430<h4><code>ERR_INVALID_STATE</code><span><a class="mark" href="#err_invalid_state" id="err_invalid_state">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_state"></a></h4> 2431<div class="api_metadata"> 2432<span>Added in: v15.0.0</span> 2433</div> 2434<p>Indicates that an operation cannot be completed due to an invalid state. 2435For instance, an object may have already been destroyed, or may be 2436performing another operation.</p> 2437<p><a id="ERR_INVALID_SYNC_FORK_INPUT"></a></p> 2438<h4><code>ERR_INVALID_SYNC_FORK_INPUT</code><span><a class="mark" href="#err_invalid_sync_fork_input" id="err_invalid_sync_fork_input">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_sync_fork_input"></a></h4> 2439<p>A <code>Buffer</code>, <code>TypedArray</code>, <code>DataView</code>, or <code>string</code> was provided as stdio input to 2440an asynchronous fork. See the documentation for the <a href="child_process.html"><code>child_process</code></a> module 2441for more information.</p> 2442<p><a id="ERR_INVALID_THIS"></a></p> 2443<h4><code>ERR_INVALID_THIS</code><span><a class="mark" href="#err_invalid_this" id="err_invalid_this">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_this"></a></h4> 2444<p>A Node.js API function was called with an incompatible <code>this</code> value.</p> 2445<pre><code class="language-js"><span class="hljs-keyword">const</span> urlSearchParams = <span class="hljs-keyword">new</span> <span class="hljs-title class_">URLSearchParams</span>(<span class="hljs-string">'foo=bar&baz=new'</span>); 2446 2447<span class="hljs-keyword">const</span> buf = <span class="hljs-title class_">Buffer</span>.<span class="hljs-title function_">alloc</span>(<span class="hljs-number">1</span>); 2448urlSearchParams.<span class="hljs-property">has</span>.<span class="hljs-title function_">call</span>(buf, <span class="hljs-string">'foo'</span>); 2449<span class="hljs-comment">// Throws a TypeError with code 'ERR_INVALID_THIS'</span></code> <button class="copy-button">copy</button></pre> 2450<p><a id="ERR_INVALID_TRANSFER_OBJECT"></a></p> 2451<h4><code>ERR_INVALID_TRANSFER_OBJECT</code><span><a class="mark" href="#err_invalid_transfer_object" id="err_invalid_transfer_object">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_transfer_object"></a></h4> 2452<p>An invalid transfer object was passed to <code>postMessage()</code>.</p> 2453<p><a id="ERR_INVALID_TUPLE"></a></p> 2454<h4><code>ERR_INVALID_TUPLE</code><span><a class="mark" href="#err_invalid_tuple" id="err_invalid_tuple">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_tuple"></a></h4> 2455<p>An element in the <code>iterable</code> provided to the <a href="url.html#the-whatwg-url-api">WHATWG</a> 2456<a href="url.html#new-urlsearchparamsiterable"><code>URLSearchParams</code> constructor</a> did not 2457represent a <code>[name, value]</code> tuple – that is, if an element is not iterable, or 2458does not consist of exactly two elements.</p> 2459<p><a id="ERR_INVALID_URI"></a></p> 2460<h4><code>ERR_INVALID_URI</code><span><a class="mark" href="#err_invalid_uri" id="err_invalid_uri">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_uri"></a></h4> 2461<p>An invalid URI was passed.</p> 2462<p><a id="ERR_INVALID_URL"></a></p> 2463<h4><code>ERR_INVALID_URL</code><span><a class="mark" href="#err_invalid_url" id="err_invalid_url">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_url"></a></h4> 2464<p>An invalid URL was passed to the <a href="url.html#the-whatwg-url-api">WHATWG</a> <a href="url.html#new-urlinput-base"><code>URL</code> 2465constructor</a> or the legacy <a href="url.html#urlparseurlstring-parsequerystring-slashesdenotehost"><code>url.parse()</code></a> to be parsed. 2466The thrown error object typically has an additional property <code>'input'</code> that 2467contains the URL that failed to parse.</p> 2468<p><a id="ERR_INVALID_URL_SCHEME"></a></p> 2469<h4><code>ERR_INVALID_URL_SCHEME</code><span><a class="mark" href="#err_invalid_url_scheme" id="err_invalid_url_scheme">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_url_scheme"></a></h4> 2470<p>An attempt was made to use a URL of an incompatible scheme (protocol) for a 2471specific purpose. It is only used in the <a href="url.html#the-whatwg-url-api">WHATWG URL API</a> support in the 2472<a href="fs.html"><code>fs</code></a> module (which only accepts URLs with <code>'file'</code> scheme), but may be used 2473in other Node.js APIs as well in the future.</p> 2474<p><a id="ERR_IPC_CHANNEL_CLOSED"></a></p> 2475<h4><code>ERR_IPC_CHANNEL_CLOSED</code><span><a class="mark" href="#err_ipc_channel_closed" id="err_ipc_channel_closed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_ipc_channel_closed"></a></h4> 2476<p>An attempt was made to use an IPC communication channel that was already closed.</p> 2477<p><a id="ERR_IPC_DISCONNECTED"></a></p> 2478<h4><code>ERR_IPC_DISCONNECTED</code><span><a class="mark" href="#err_ipc_disconnected" id="err_ipc_disconnected">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_ipc_disconnected"></a></h4> 2479<p>An attempt was made to disconnect an IPC communication channel that was already 2480disconnected. See the documentation for the <a href="child_process.html"><code>child_process</code></a> module 2481for more information.</p> 2482<p><a id="ERR_IPC_ONE_PIPE"></a></p> 2483<h4><code>ERR_IPC_ONE_PIPE</code><span><a class="mark" href="#err_ipc_one_pipe" id="err_ipc_one_pipe">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_ipc_one_pipe"></a></h4> 2484<p>An attempt was made to create a child Node.js process using more than one IPC 2485communication channel. See the documentation for the <a href="child_process.html"><code>child_process</code></a> module 2486for more information.</p> 2487<p><a id="ERR_IPC_SYNC_FORK"></a></p> 2488<h4><code>ERR_IPC_SYNC_FORK</code><span><a class="mark" href="#err_ipc_sync_fork" id="err_ipc_sync_fork">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_ipc_sync_fork"></a></h4> 2489<p>An attempt was made to open an IPC communication channel with a synchronously 2490forked Node.js process. See the documentation for the <a href="child_process.html"><code>child_process</code></a> module 2491for more information.</p> 2492<p><a id="ERR_LOADER_CHAIN_INCOMPLETE"></a></p> 2493<h4><code>ERR_LOADER_CHAIN_INCOMPLETE</code><span><a class="mark" href="#err_loader_chain_incomplete" id="err_loader_chain_incomplete">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_loader_chain_incomplete"></a></h4> 2494<div class="api_metadata"> 2495<span>Added in: v18.6.0</span> 2496</div> 2497<p>An ESM loader hook returned without calling <code>next()</code> and without explicitly 2498signaling a short circuit.</p> 2499<p><a id="ERR_MANIFEST_ASSERT_INTEGRITY"></a></p> 2500<h4><code>ERR_MANIFEST_ASSERT_INTEGRITY</code><span><a class="mark" href="#err_manifest_assert_integrity" id="err_manifest_assert_integrity">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_manifest_assert_integrity"></a></h4> 2501<p>An attempt was made to load a resource, but the resource did not match the 2502integrity defined by the policy manifest. See the documentation for <a href="permissions.html#policies">policy</a> 2503manifests for more information.</p> 2504<p><a id="ERR_MANIFEST_DEPENDENCY_MISSING"></a></p> 2505<h4><code>ERR_MANIFEST_DEPENDENCY_MISSING</code><span><a class="mark" href="#err_manifest_dependency_missing" id="err_manifest_dependency_missing">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_manifest_dependency_missing"></a></h4> 2506<p>An attempt was made to load a resource, but the resource was not listed as a 2507dependency from the location that attempted to load it. See the documentation 2508for <a href="permissions.html#policies">policy</a> manifests for more information.</p> 2509<p><a id="ERR_MANIFEST_INTEGRITY_MISMATCH"></a></p> 2510<h4><code>ERR_MANIFEST_INTEGRITY_MISMATCH</code><span><a class="mark" href="#err_manifest_integrity_mismatch" id="err_manifest_integrity_mismatch">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_manifest_integrity_mismatch"></a></h4> 2511<p>An attempt was made to load a policy manifest, but the manifest had multiple 2512entries for a resource which did not match each other. Update the manifest 2513entries to match in order to resolve this error. See the documentation for 2514<a href="permissions.html#policies">policy</a> manifests for more information.</p> 2515<p><a id="ERR_MANIFEST_INVALID_RESOURCE_FIELD"></a></p> 2516<h4><code>ERR_MANIFEST_INVALID_RESOURCE_FIELD</code><span><a class="mark" href="#err_manifest_invalid_resource_field" id="err_manifest_invalid_resource_field">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_manifest_invalid_resource_field"></a></h4> 2517<p>A policy manifest resource had an invalid value for one of its fields. Update 2518the manifest entry to match in order to resolve this error. See the 2519documentation for <a href="permissions.html#policies">policy</a> manifests for more information.</p> 2520<p><a id="ERR_MANIFEST_INVALID_SPECIFIER"></a></p> 2521<h4><code>ERR_MANIFEST_INVALID_SPECIFIER</code><span><a class="mark" href="#err_manifest_invalid_specifier" id="err_manifest_invalid_specifier">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_manifest_invalid_specifier"></a></h4> 2522<p>A policy manifest resource had an invalid value for one of its dependency 2523mappings. Update the manifest entry to match to resolve this error. See the 2524documentation for <a href="permissions.html#policies">policy</a> manifests for more information.</p> 2525<p><a id="ERR_MANIFEST_PARSE_POLICY"></a></p> 2526<h4><code>ERR_MANIFEST_PARSE_POLICY</code><span><a class="mark" href="#err_manifest_parse_policy" id="err_manifest_parse_policy">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_manifest_parse_policy"></a></h4> 2527<p>An attempt was made to load a policy manifest, but the manifest was unable to 2528be parsed. See the documentation for <a href="permissions.html#policies">policy</a> manifests for more information.</p> 2529<p><a id="ERR_MANIFEST_TDZ"></a></p> 2530<h4><code>ERR_MANIFEST_TDZ</code><span><a class="mark" href="#err_manifest_tdz" id="err_manifest_tdz">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_manifest_tdz"></a></h4> 2531<p>An attempt was made to read from a policy manifest, but the manifest 2532initialization has not yet taken place. This is likely a bug in Node.js.</p> 2533<p><a id="ERR_MANIFEST_UNKNOWN_ONERROR"></a></p> 2534<h4><code>ERR_MANIFEST_UNKNOWN_ONERROR</code><span><a class="mark" href="#err_manifest_unknown_onerror" id="err_manifest_unknown_onerror">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_manifest_unknown_onerror"></a></h4> 2535<p>A policy manifest was loaded, but had an unknown value for its "onerror" 2536behavior. See the documentation for <a href="permissions.html#policies">policy</a> manifests for more information.</p> 2537<p><a id="ERR_MEMORY_ALLOCATION_FAILED"></a></p> 2538<h4><code>ERR_MEMORY_ALLOCATION_FAILED</code><span><a class="mark" href="#err_memory_allocation_failed" id="err_memory_allocation_failed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_memory_allocation_failed"></a></h4> 2539<p>An attempt was made to allocate memory (usually in the C++ layer) but it 2540failed.</p> 2541<p><a id="ERR_MESSAGE_TARGET_CONTEXT_UNAVAILABLE"></a></p> 2542<h4><code>ERR_MESSAGE_TARGET_CONTEXT_UNAVAILABLE</code><span><a class="mark" href="#err_message_target_context_unavailable" id="err_message_target_context_unavailable">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_message_target_context_unavailable"></a></h4> 2543<div class="api_metadata"> 2544<span>Added in: v14.5.0, v12.19.0</span> 2545</div> 2546<p>A message posted to a <a href="worker_threads.html#class-messageport"><code>MessagePort</code></a> could not be deserialized in the target 2547<a href="vm.html">vm</a> <code>Context</code>. Not all Node.js objects can be successfully instantiated in 2548any context at this time, and attempting to transfer them using <code>postMessage()</code> 2549can fail on the receiving side in that case.</p> 2550<p><a id="ERR_METHOD_NOT_IMPLEMENTED"></a></p> 2551<h4><code>ERR_METHOD_NOT_IMPLEMENTED</code><span><a class="mark" href="#err_method_not_implemented" id="err_method_not_implemented">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_method_not_implemented"></a></h4> 2552<p>A method is required but not implemented.</p> 2553<p><a id="ERR_MISSING_ARGS"></a></p> 2554<h4><code>ERR_MISSING_ARGS</code><span><a class="mark" href="#err_missing_args" id="err_missing_args">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_missing_args"></a></h4> 2555<p>A required argument of a Node.js API was not passed. This is only used for 2556strict compliance with the API specification (which in some cases may accept 2557<code>func(undefined)</code> but not <code>func()</code>). In most native Node.js APIs, 2558<code>func(undefined)</code> and <code>func()</code> are treated identically, and the 2559<a href="#err_invalid_arg_type"><code>ERR_INVALID_ARG_TYPE</code></a> error code may be used instead.</p> 2560<p><a id="ERR_MISSING_OPTION"></a></p> 2561<h4><code>ERR_MISSING_OPTION</code><span><a class="mark" href="#err_missing_option" id="err_missing_option">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_missing_option"></a></h4> 2562<p>For APIs that accept options objects, some options might be mandatory. This code 2563is thrown if a required option is missing.</p> 2564<p><a id="ERR_MISSING_PASSPHRASE"></a></p> 2565<h4><code>ERR_MISSING_PASSPHRASE</code><span><a class="mark" href="#err_missing_passphrase" id="err_missing_passphrase">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_missing_passphrase"></a></h4> 2566<p>An attempt was made to read an encrypted key without specifying a passphrase.</p> 2567<p><a id="ERR_MISSING_PLATFORM_FOR_WORKER"></a></p> 2568<h4><code>ERR_MISSING_PLATFORM_FOR_WORKER</code><span><a class="mark" href="#err_missing_platform_for_worker" id="err_missing_platform_for_worker">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_missing_platform_for_worker"></a></h4> 2569<p>The V8 platform used by this instance of Node.js does not support creating 2570Workers. This is caused by lack of embedder support for Workers. In particular, 2571this error will not occur with standard builds of Node.js.</p> 2572<p><a id="ERR_MISSING_TRANSFERABLE_IN_TRANSFER_LIST"></a></p> 2573<h4><code>ERR_MISSING_TRANSFERABLE_IN_TRANSFER_LIST</code><span><a class="mark" href="#err_missing_transferable_in_transfer_list" id="err_missing_transferable_in_transfer_list">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_missing_transferable_in_transfer_list"></a></h4> 2574<div class="api_metadata"> 2575<span>Added in: v15.0.0</span> 2576</div> 2577<p>An object that needs to be explicitly listed in the <code>transferList</code> argument 2578is in the object passed to a <a href="worker_threads.html#portpostmessagevalue-transferlist"><code>postMessage()</code></a> call, but is not provided 2579in the <code>transferList</code> for that call. Usually, this is a <code>MessagePort</code>.</p> 2580<p>In Node.js versions prior to v15.0.0, the error code being used here was 2581<a href="#err_missing_message_port_in_transfer_list"><code>ERR_MISSING_MESSAGE_PORT_IN_TRANSFER_LIST</code></a>. However, the set of 2582transferable object types has been expanded to cover more types than 2583<code>MessagePort</code>.</p> 2584<p><a id="ERR_MODULE_NOT_FOUND"></a></p> 2585<h4><code>ERR_MODULE_NOT_FOUND</code><span><a class="mark" href="#err_module_not_found" id="err_module_not_found">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_module_not_found"></a></h4> 2586<p>A module file could not be resolved by the ECMAScript modules loader while 2587attempting an <code>import</code> operation or when loading the program entry point.</p> 2588<p><a id="ERR_MULTIPLE_CALLBACK"></a></p> 2589<h4><code>ERR_MULTIPLE_CALLBACK</code><span><a class="mark" href="#err_multiple_callback" id="err_multiple_callback">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_multiple_callback"></a></h4> 2590<p>A callback was called more than once.</p> 2591<p>A callback is almost always meant to only be called once as the query 2592can either be fulfilled or rejected but not both at the same time. The latter 2593would be possible by calling a callback more than once.</p> 2594<p><a id="ERR_NAPI_CONS_FUNCTION"></a></p> 2595<h4><code>ERR_NAPI_CONS_FUNCTION</code><span><a class="mark" href="#err_napi_cons_function" id="err_napi_cons_function">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_napi_cons_function"></a></h4> 2596<p>While using <code>Node-API</code>, a constructor passed was not a function.</p> 2597<p><a id="ERR_NAPI_INVALID_DATAVIEW_ARGS"></a></p> 2598<h4><code>ERR_NAPI_INVALID_DATAVIEW_ARGS</code><span><a class="mark" href="#err_napi_invalid_dataview_args" id="err_napi_invalid_dataview_args">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_napi_invalid_dataview_args"></a></h4> 2599<p>While calling <code>napi_create_dataview()</code>, a given <code>offset</code> was outside the bounds 2600of the dataview or <code>offset + length</code> was larger than a length of given <code>buffer</code>.</p> 2601<p><a id="ERR_NAPI_INVALID_TYPEDARRAY_ALIGNMENT"></a></p> 2602<h4><code>ERR_NAPI_INVALID_TYPEDARRAY_ALIGNMENT</code><span><a class="mark" href="#err_napi_invalid_typedarray_alignment" id="err_napi_invalid_typedarray_alignment">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_napi_invalid_typedarray_alignment"></a></h4> 2603<p>While calling <code>napi_create_typedarray()</code>, the provided <code>offset</code> was not a 2604multiple of the element size.</p> 2605<p><a id="ERR_NAPI_INVALID_TYPEDARRAY_LENGTH"></a></p> 2606<h4><code>ERR_NAPI_INVALID_TYPEDARRAY_LENGTH</code><span><a class="mark" href="#err_napi_invalid_typedarray_length" id="err_napi_invalid_typedarray_length">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_napi_invalid_typedarray_length"></a></h4> 2607<p>While calling <code>napi_create_typedarray()</code>, <code>(length * size_of_element) + byte_offset</code> was larger than the length of given <code>buffer</code>.</p> 2608<p><a id="ERR_NAPI_TSFN_CALL_JS"></a></p> 2609<h4><code>ERR_NAPI_TSFN_CALL_JS</code><span><a class="mark" href="#err_napi_tsfn_call_js" id="err_napi_tsfn_call_js">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_napi_tsfn_call_js"></a></h4> 2610<p>An error occurred while invoking the JavaScript portion of the thread-safe 2611function.</p> 2612<p><a id="ERR_NAPI_TSFN_GET_UNDEFINED"></a></p> 2613<h4><code>ERR_NAPI_TSFN_GET_UNDEFINED</code><span><a class="mark" href="#err_napi_tsfn_get_undefined" id="err_napi_tsfn_get_undefined">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_napi_tsfn_get_undefined"></a></h4> 2614<p>An error occurred while attempting to retrieve the JavaScript <code>undefined</code> 2615value.</p> 2616<p><a id="ERR_NAPI_TSFN_START_IDLE_LOOP"></a></p> 2617<h4><code>ERR_NAPI_TSFN_START_IDLE_LOOP</code><span><a class="mark" href="#err_napi_tsfn_start_idle_loop" id="err_napi_tsfn_start_idle_loop">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_napi_tsfn_start_idle_loop"></a></h4> 2618<p>On the main thread, values are removed from the queue associated with the 2619thread-safe function in an idle loop. This error indicates that an error 2620has occurred when attempting to start the loop.</p> 2621<p><a id="ERR_NAPI_TSFN_STOP_IDLE_LOOP"></a></p> 2622<h4><code>ERR_NAPI_TSFN_STOP_IDLE_LOOP</code><span><a class="mark" href="#err_napi_tsfn_stop_idle_loop" id="err_napi_tsfn_stop_idle_loop">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_napi_tsfn_stop_idle_loop"></a></h4> 2623<p>Once no more items are left in the queue, the idle loop must be suspended. This 2624error indicates that the idle loop has failed to stop.</p> 2625<p><a id="ERR_NOT_BUILDING_SNAPSHOT"></a></p> 2626<h4><code>ERR_NOT_BUILDING_SNAPSHOT</code><span><a class="mark" href="#err_not_building_snapshot" id="err_not_building_snapshot">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_not_building_snapshot"></a></h4> 2627<p>An attempt was made to use operations that can only be used when building 2628V8 startup snapshot even though Node.js isn't building one.</p> 2629<p><a id="ERR_NO_CRYPTO"></a></p> 2630<h4><code>ERR_NO_CRYPTO</code><span><a class="mark" href="#err_no_crypto" id="err_no_crypto">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_no_crypto"></a></h4> 2631<p>An attempt was made to use crypto features while Node.js was not compiled with 2632OpenSSL crypto support.</p> 2633<p><a id="ERR_NO_ICU"></a></p> 2634<h4><code>ERR_NO_ICU</code><span><a class="mark" href="#err_no_icu" id="err_no_icu">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_no_icu"></a></h4> 2635<p>An attempt was made to use features that require <a href="intl.html#internationalization-support">ICU</a>, but Node.js was not 2636compiled with ICU support.</p> 2637<p><a id="ERR_NON_CONTEXT_AWARE_DISABLED"></a></p> 2638<h4><code>ERR_NON_CONTEXT_AWARE_DISABLED</code><span><a class="mark" href="#err_non_context_aware_disabled" id="err_non_context_aware_disabled">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_non_context_aware_disabled"></a></h4> 2639<p>A non-context-aware native addon was loaded in a process that disallows them.</p> 2640<p><a id="ERR_OUT_OF_RANGE"></a></p> 2641<h4><code>ERR_OUT_OF_RANGE</code><span><a class="mark" href="#err_out_of_range" id="err_out_of_range">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_out_of_range"></a></h4> 2642<p>A given value is out of the accepted range.</p> 2643<p><a id="ERR_PACKAGE_IMPORT_NOT_DEFINED"></a></p> 2644<h4><code>ERR_PACKAGE_IMPORT_NOT_DEFINED</code><span><a class="mark" href="#err_package_import_not_defined" id="err_package_import_not_defined">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_package_import_not_defined"></a></h4> 2645<p>The <code>package.json</code> <a href="packages.html#imports"><code>"imports"</code></a> field does not define the given internal 2646package specifier mapping.</p> 2647<p><a id="ERR_PACKAGE_PATH_NOT_EXPORTED"></a></p> 2648<h4><code>ERR_PACKAGE_PATH_NOT_EXPORTED</code><span><a class="mark" href="#err_package_path_not_exported" id="err_package_path_not_exported">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_package_path_not_exported"></a></h4> 2649<p>The <code>package.json</code> <a href="packages.html#exports"><code>"exports"</code></a> field does not export the requested subpath. 2650Because exports are encapsulated, private internal modules that are not exported 2651cannot be imported through the package resolution, unless using an absolute URL.</p> 2652<p><a id="ERR_PARSE_ARGS_INVALID_OPTION_VALUE"></a></p> 2653<h4><code>ERR_PARSE_ARGS_INVALID_OPTION_VALUE</code><span><a class="mark" href="#err_parse_args_invalid_option_value" id="err_parse_args_invalid_option_value">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_parse_args_invalid_option_value"></a></h4> 2654<div class="api_metadata"> 2655<span>Added in: v18.3.0</span> 2656</div> 2657<p>When <code>strict</code> set to <code>true</code>, thrown by <a href="util.html#utilparseargsconfig"><code>util.parseArgs()</code></a> if a <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Boolean_type" class="type"><boolean></a> 2658value is provided for an option of type <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a>, or if a <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type"><string></a> 2659value is provided for an option of type <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Boolean_type" class="type"><boolean></a>.</p> 2660<p><a id="ERR_PARSE_ARGS_UNEXPECTED_POSITIONAL"></a></p> 2661<h4><code>ERR_PARSE_ARGS_UNEXPECTED_POSITIONAL</code><span><a class="mark" href="#err_parse_args_unexpected_positional" id="err_parse_args_unexpected_positional">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_parse_args_unexpected_positional"></a></h4> 2662<div class="api_metadata"> 2663<span>Added in: v18.3.0</span> 2664</div> 2665<p>Thrown by <a href="util.html#utilparseargsconfig"><code>util.parseArgs()</code></a>, when a positional argument is provided and 2666<code>allowPositionals</code> is set to <code>false</code>.</p> 2667<p><a id="ERR_PARSE_ARGS_UNKNOWN_OPTION"></a></p> 2668<h4><code>ERR_PARSE_ARGS_UNKNOWN_OPTION</code><span><a class="mark" href="#err_parse_args_unknown_option" id="err_parse_args_unknown_option">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_parse_args_unknown_option"></a></h4> 2669<div class="api_metadata"> 2670<span>Added in: v18.3.0</span> 2671</div> 2672<p>When <code>strict</code> set to <code>true</code>, thrown by <a href="util.html#utilparseargsconfig"><code>util.parseArgs()</code></a> if an argument 2673is not configured in <code>options</code>.</p> 2674<p><a id="ERR_PERFORMANCE_INVALID_TIMESTAMP"></a></p> 2675<h4><code>ERR_PERFORMANCE_INVALID_TIMESTAMP</code><span><a class="mark" href="#err_performance_invalid_timestamp" id="err_performance_invalid_timestamp">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_performance_invalid_timestamp"></a></h4> 2676<p>An invalid timestamp value was provided for a performance mark or measure.</p> 2677<p><a id="ERR_PERFORMANCE_MEASURE_INVALID_OPTIONS"></a></p> 2678<h4><code>ERR_PERFORMANCE_MEASURE_INVALID_OPTIONS</code><span><a class="mark" href="#err_performance_measure_invalid_options" id="err_performance_measure_invalid_options">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_performance_measure_invalid_options"></a></h4> 2679<p>Invalid options were provided for a performance measure.</p> 2680<p><a id="ERR_PROTO_ACCESS"></a></p> 2681<h4><code>ERR_PROTO_ACCESS</code><span><a class="mark" href="#err_proto_access" id="err_proto_access">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_proto_access"></a></h4> 2682<p>Accessing <code>Object.prototype.__proto__</code> has been forbidden using 2683<a href="cli.html#--disable-protomode"><code>--disable-proto=throw</code></a>. <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/getPrototypeOf"><code>Object.getPrototypeOf</code></a> and 2684<a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/setPrototypeOf"><code>Object.setPrototypeOf</code></a> should be used to get and set the prototype of an 2685object.</p> 2686<p><a id="ERR_REQUIRE_ESM"></a></p> 2687<h4><code>ERR_REQUIRE_ESM</code><span><a class="mark" href="#err_require_esm" id="err_require_esm">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_require_esm"></a></h4> 2688<p></p><div class="api_stability api_stability_1"><a href="documentation.html#stability-index">Stability: 1</a> - Experimental</div><p></p> 2689<p>An attempt was made to <code>require()</code> an <a href="esm.html">ES Module</a>.</p> 2690<p><a id="ERR_SCRIPT_EXECUTION_INTERRUPTED"></a></p> 2691<h4><code>ERR_SCRIPT_EXECUTION_INTERRUPTED</code><span><a class="mark" href="#err_script_execution_interrupted" id="err_script_execution_interrupted">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_script_execution_interrupted"></a></h4> 2692<p>Script execution was interrupted by <code>SIGINT</code> (For 2693example, <kbd>Ctrl</kbd>+<kbd>C</kbd> was pressed.)</p> 2694<p><a id="ERR_SCRIPT_EXECUTION_TIMEOUT"></a></p> 2695<h4><code>ERR_SCRIPT_EXECUTION_TIMEOUT</code><span><a class="mark" href="#err_script_execution_timeout" id="err_script_execution_timeout">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_script_execution_timeout"></a></h4> 2696<p>Script execution timed out, possibly due to bugs in the script being executed.</p> 2697<p><a id="ERR_SERVER_ALREADY_LISTEN"></a></p> 2698<h4><code>ERR_SERVER_ALREADY_LISTEN</code><span><a class="mark" href="#err_server_already_listen" id="err_server_already_listen">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_server_already_listen"></a></h4> 2699<p>The <a href="net.html#serverlisten"><code>server.listen()</code></a> method was called while a <code>net.Server</code> was already 2700listening. This applies to all instances of <code>net.Server</code>, including HTTP, HTTPS, 2701and HTTP/2 <code>Server</code> instances.</p> 2702<p><a id="ERR_SERVER_NOT_RUNNING"></a></p> 2703<h4><code>ERR_SERVER_NOT_RUNNING</code><span><a class="mark" href="#err_server_not_running" id="err_server_not_running">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_server_not_running"></a></h4> 2704<p>The <a href="net.html#serverclosecallback"><code>server.close()</code></a> method was called when a <code>net.Server</code> was not 2705running. This applies to all instances of <code>net.Server</code>, including HTTP, HTTPS, 2706and HTTP/2 <code>Server</code> instances.</p> 2707<p><a id="ERR_SOCKET_ALREADY_BOUND"></a></p> 2708<h4><code>ERR_SOCKET_ALREADY_BOUND</code><span><a class="mark" href="#err_socket_already_bound" id="err_socket_already_bound">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_socket_already_bound"></a></h4> 2709<p>An attempt was made to bind a socket that has already been bound.</p> 2710<p><a id="ERR_SOCKET_BAD_BUFFER_SIZE"></a></p> 2711<h4><code>ERR_SOCKET_BAD_BUFFER_SIZE</code><span><a class="mark" href="#err_socket_bad_buffer_size" id="err_socket_bad_buffer_size">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_socket_bad_buffer_size"></a></h4> 2712<p>An invalid (negative) size was passed for either the <code>recvBufferSize</code> or 2713<code>sendBufferSize</code> options in <a href="dgram.html#dgramcreatesocketoptions-callback"><code>dgram.createSocket()</code></a>.</p> 2714<p><a id="ERR_SOCKET_BAD_PORT"></a></p> 2715<h4><code>ERR_SOCKET_BAD_PORT</code><span><a class="mark" href="#err_socket_bad_port" id="err_socket_bad_port">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_socket_bad_port"></a></h4> 2716<p>An API function expecting a port >= 0 and < 65536 received an invalid value.</p> 2717<p><a id="ERR_SOCKET_BAD_TYPE"></a></p> 2718<h4><code>ERR_SOCKET_BAD_TYPE</code><span><a class="mark" href="#err_socket_bad_type" id="err_socket_bad_type">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_socket_bad_type"></a></h4> 2719<p>An API function expecting a socket type (<code>udp4</code> or <code>udp6</code>) received an invalid 2720value.</p> 2721<p><a id="ERR_SOCKET_BUFFER_SIZE"></a></p> 2722<h4><code>ERR_SOCKET_BUFFER_SIZE</code><span><a class="mark" href="#err_socket_buffer_size" id="err_socket_buffer_size">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_socket_buffer_size"></a></h4> 2723<p>While using <a href="dgram.html#dgramcreatesocketoptions-callback"><code>dgram.createSocket()</code></a>, the size of the receive or send <code>Buffer</code> 2724could not be determined.</p> 2725<p><a id="ERR_SOCKET_CLOSED"></a></p> 2726<h4><code>ERR_SOCKET_CLOSED</code><span><a class="mark" href="#err_socket_closed" id="err_socket_closed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_socket_closed"></a></h4> 2727<p>An attempt was made to operate on an already closed socket.</p> 2728<p><a id="ERR_SOCKET_CLOSED_BEFORE_CONNECTION"></a></p> 2729<h4><code>ERR_SOCKET_CLOSED_BEFORE_CONNECTION</code><span><a class="mark" href="#err_socket_closed_before_connection" id="err_socket_closed_before_connection">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_socket_closed_before_connection"></a></h4> 2730<p>When calling <a href="net.html#socketwritedata-encoding-callback"><code>net.Socket.write()</code></a> on a connecting socket and the socket was 2731closed before the connection was established.</p> 2732<p><a id="ERR_SOCKET_DGRAM_IS_CONNECTED"></a></p> 2733<h4><code>ERR_SOCKET_DGRAM_IS_CONNECTED</code><span><a class="mark" href="#err_socket_dgram_is_connected" id="err_socket_dgram_is_connected">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_socket_dgram_is_connected"></a></h4> 2734<p>A <a href="dgram.html#socketconnectport-address-callback"><code>dgram.connect()</code></a> call was made on an already connected socket.</p> 2735<p><a id="ERR_SOCKET_DGRAM_NOT_CONNECTED"></a></p> 2736<h4><code>ERR_SOCKET_DGRAM_NOT_CONNECTED</code><span><a class="mark" href="#err_socket_dgram_not_connected" id="err_socket_dgram_not_connected">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_socket_dgram_not_connected"></a></h4> 2737<p>A <a href="dgram.html#socketdisconnect"><code>dgram.disconnect()</code></a> or <a href="dgram.html#socketremoteaddress"><code>dgram.remoteAddress()</code></a> call was made on a 2738disconnected socket.</p> 2739<p><a id="ERR_SOCKET_DGRAM_NOT_RUNNING"></a></p> 2740<h4><code>ERR_SOCKET_DGRAM_NOT_RUNNING</code><span><a class="mark" href="#err_socket_dgram_not_running" id="err_socket_dgram_not_running">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_socket_dgram_not_running"></a></h4> 2741<p>A call was made and the UDP subsystem was not running.</p> 2742<p><a id="ERR_SRI_PARSE"></a></p> 2743<h4><code>ERR_SRI_PARSE</code><span><a class="mark" href="#err_sri_parse" id="err_sri_parse">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_sri_parse"></a></h4> 2744<p>A string was provided for a Subresource Integrity check, but was unable to be 2745parsed. Check the format of integrity attributes by looking at the 2746<a href="https://www.w3.org/TR/SRI/#the-integrity-attribute">Subresource Integrity specification</a>.</p> 2747<p><a id="ERR_STREAM_ALREADY_FINISHED"></a></p> 2748<h4><code>ERR_STREAM_ALREADY_FINISHED</code><span><a class="mark" href="#err_stream_already_finished" id="err_stream_already_finished">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_stream_already_finished"></a></h4> 2749<p>A stream method was called that cannot complete because the stream was 2750finished.</p> 2751<p><a id="ERR_STREAM_CANNOT_PIPE"></a></p> 2752<h4><code>ERR_STREAM_CANNOT_PIPE</code><span><a class="mark" href="#err_stream_cannot_pipe" id="err_stream_cannot_pipe">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_stream_cannot_pipe"></a></h4> 2753<p>An attempt was made to call <a href="stream.html#readablepipedestination-options"><code>stream.pipe()</code></a> on a <a href="stream.html#class-streamwritable"><code>Writable</code></a> stream.</p> 2754<p><a id="ERR_STREAM_DESTROYED"></a></p> 2755<h4><code>ERR_STREAM_DESTROYED</code><span><a class="mark" href="#err_stream_destroyed" id="err_stream_destroyed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_stream_destroyed"></a></h4> 2756<p>A stream method was called that cannot complete because the stream was 2757destroyed using <code>stream.destroy()</code>.</p> 2758<p><a id="ERR_STREAM_NULL_VALUES"></a></p> 2759<h4><code>ERR_STREAM_NULL_VALUES</code><span><a class="mark" href="#err_stream_null_values" id="err_stream_null_values">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_stream_null_values"></a></h4> 2760<p>An attempt was made to call <a href="stream.html#writablewritechunk-encoding-callback"><code>stream.write()</code></a> with a <code>null</code> chunk.</p> 2761<p><a id="ERR_STREAM_PREMATURE_CLOSE"></a></p> 2762<h4><code>ERR_STREAM_PREMATURE_CLOSE</code><span><a class="mark" href="#err_stream_premature_close" id="err_stream_premature_close">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_stream_premature_close"></a></h4> 2763<p>An error returned by <code>stream.finished()</code> and <code>stream.pipeline()</code>, when a stream 2764or a pipeline ends non gracefully with no explicit error.</p> 2765<p><a id="ERR_STREAM_PUSH_AFTER_EOF"></a></p> 2766<h4><code>ERR_STREAM_PUSH_AFTER_EOF</code><span><a class="mark" href="#err_stream_push_after_eof" id="err_stream_push_after_eof">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_stream_push_after_eof"></a></h4> 2767<p>An attempt was made to call <a href="stream.html#readablepushchunk-encoding"><code>stream.push()</code></a> after a <code>null</code>(EOF) had been 2768pushed to the stream.</p> 2769<p><a id="ERR_STREAM_UNSHIFT_AFTER_END_EVENT"></a></p> 2770<h4><code>ERR_STREAM_UNSHIFT_AFTER_END_EVENT</code><span><a class="mark" href="#err_stream_unshift_after_end_event" id="err_stream_unshift_after_end_event">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_stream_unshift_after_end_event"></a></h4> 2771<p>An attempt was made to call <a href="stream.html#readableunshiftchunk-encoding"><code>stream.unshift()</code></a> after the <code>'end'</code> event was 2772emitted.</p> 2773<p><a id="ERR_STREAM_WRAP"></a></p> 2774<h4><code>ERR_STREAM_WRAP</code><span><a class="mark" href="#err_stream_wrap" id="err_stream_wrap">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_stream_wrap"></a></h4> 2775<p>Prevents an abort if a string decoder was set on the Socket or if the decoder 2776is in <code>objectMode</code>.</p> 2777<pre><code class="language-js"><span class="hljs-keyword">const</span> <span class="hljs-title class_">Socket</span> = <span class="hljs-built_in">require</span>(<span class="hljs-string">'node:net'</span>).<span class="hljs-property">Socket</span>; 2778<span class="hljs-keyword">const</span> instance = <span class="hljs-keyword">new</span> <span class="hljs-title class_">Socket</span>(); 2779 2780instance.<span class="hljs-title function_">setEncoding</span>(<span class="hljs-string">'utf8'</span>);</code> <button class="copy-button">copy</button></pre> 2781<p><a id="ERR_STREAM_WRITE_AFTER_END"></a></p> 2782<h4><code>ERR_STREAM_WRITE_AFTER_END</code><span><a class="mark" href="#err_stream_write_after_end" id="err_stream_write_after_end">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_stream_write_after_end"></a></h4> 2783<p>An attempt was made to call <a href="stream.html#writablewritechunk-encoding-callback"><code>stream.write()</code></a> after <code>stream.end()</code> has been 2784called.</p> 2785<p><a id="ERR_STRING_TOO_LONG"></a></p> 2786<h4><code>ERR_STRING_TOO_LONG</code><span><a class="mark" href="#err_string_too_long" id="err_string_too_long">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_string_too_long"></a></h4> 2787<p>An attempt has been made to create a string longer than the maximum allowed 2788length.</p> 2789<p><a id="ERR_SYNTHETIC"></a></p> 2790<h4><code>ERR_SYNTHETIC</code><span><a class="mark" href="#err_synthetic" id="err_synthetic">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_synthetic"></a></h4> 2791<p>An artificial error object used to capture the call stack for diagnostic 2792reports.</p> 2793<p><a id="ERR_SYSTEM_ERROR"></a></p> 2794<h4><code>ERR_SYSTEM_ERROR</code><span><a class="mark" href="#err_system_error" id="err_system_error">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_system_error"></a></h4> 2795<p>An unspecified or non-specific system error has occurred within the Node.js 2796process. The error object will have an <code>err.info</code> object property with 2797additional details.</p> 2798<p><a id="ERR_TAP_LEXER_ERROR"></a></p> 2799<h4><code>ERR_TAP_LEXER_ERROR</code><span><a class="mark" href="#err_tap_lexer_error" id="err_tap_lexer_error">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tap_lexer_error"></a></h4> 2800<p>An error representing a failing lexer state.</p> 2801<p><a id="ERR_TAP_PARSER_ERROR"></a></p> 2802<h4><code>ERR_TAP_PARSER_ERROR</code><span><a class="mark" href="#err_tap_parser_error" id="err_tap_parser_error">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tap_parser_error"></a></h4> 2803<p>An error representing a failing parser state. Additional information about 2804the token causing the error is available via the <code>cause</code> property.</p> 2805<p><a id="ERR_TAP_VALIDATION_ERROR"></a></p> 2806<h4><code>ERR_TAP_VALIDATION_ERROR</code><span><a class="mark" href="#err_tap_validation_error" id="err_tap_validation_error">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tap_validation_error"></a></h4> 2807<p>This error represents a failed TAP validation.</p> 2808<p><a id="ERR_TEST_FAILURE"></a></p> 2809<h4><code>ERR_TEST_FAILURE</code><span><a class="mark" href="#err_test_failure" id="err_test_failure">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_test_failure"></a></h4> 2810<p>This error represents a failed test. Additional information about the failure 2811is available via the <code>cause</code> property. The <code>failureType</code> property specifies 2812what the test was doing when the failure occurred.</p> 2813<p><a id="ERR_TLS_CERT_ALTNAME_FORMAT"></a></p> 2814<h4><code>ERR_TLS_CERT_ALTNAME_FORMAT</code><span><a class="mark" href="#err_tls_cert_altname_format" id="err_tls_cert_altname_format">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tls_cert_altname_format"></a></h4> 2815<p>This error is thrown by <code>checkServerIdentity</code> if a user-supplied 2816<code>subjectaltname</code> property violates encoding rules. Certificate objects produced 2817by Node.js itself always comply with encoding rules and will never cause 2818this error.</p> 2819<p><a id="ERR_TLS_CERT_ALTNAME_INVALID"></a></p> 2820<h4><code>ERR_TLS_CERT_ALTNAME_INVALID</code><span><a class="mark" href="#err_tls_cert_altname_invalid" id="err_tls_cert_altname_invalid">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tls_cert_altname_invalid"></a></h4> 2821<p>While using TLS, the host name/IP of the peer did not match any of the 2822<code>subjectAltNames</code> in its certificate.</p> 2823<p><a id="ERR_TLS_DH_PARAM_SIZE"></a></p> 2824<h4><code>ERR_TLS_DH_PARAM_SIZE</code><span><a class="mark" href="#err_tls_dh_param_size" id="err_tls_dh_param_size">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tls_dh_param_size"></a></h4> 2825<p>While using TLS, the parameter offered for the Diffie-Hellman (<code>DH</code>) 2826key-agreement protocol is too small. By default, the key length must be greater 2827than or equal to 1024 bits to avoid vulnerabilities, even though it is strongly 2828recommended to use 2048 bits or larger for stronger security.</p> 2829<p><a id="ERR_TLS_HANDSHAKE_TIMEOUT"></a></p> 2830<h4><code>ERR_TLS_HANDSHAKE_TIMEOUT</code><span><a class="mark" href="#err_tls_handshake_timeout" id="err_tls_handshake_timeout">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tls_handshake_timeout"></a></h4> 2831<p>A TLS/SSL handshake timed out. In this case, the server must also abort the 2832connection.</p> 2833<p><a id="ERR_TLS_INVALID_CONTEXT"></a></p> 2834<h4><code>ERR_TLS_INVALID_CONTEXT</code><span><a class="mark" href="#err_tls_invalid_context" id="err_tls_invalid_context">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tls_invalid_context"></a></h4> 2835<div class="api_metadata"> 2836<span>Added in: v13.3.0</span> 2837</div> 2838<p>The context must be a <code>SecureContext</code>.</p> 2839<p><a id="ERR_TLS_INVALID_PROTOCOL_METHOD"></a></p> 2840<h4><code>ERR_TLS_INVALID_PROTOCOL_METHOD</code><span><a class="mark" href="#err_tls_invalid_protocol_method" id="err_tls_invalid_protocol_method">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tls_invalid_protocol_method"></a></h4> 2841<p>The specified <code>secureProtocol</code> method is invalid. It is either unknown, or 2842disabled because it is insecure.</p> 2843<p><a id="ERR_TLS_INVALID_PROTOCOL_VERSION"></a></p> 2844<h4><code>ERR_TLS_INVALID_PROTOCOL_VERSION</code><span><a class="mark" href="#err_tls_invalid_protocol_version" id="err_tls_invalid_protocol_version">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tls_invalid_protocol_version"></a></h4> 2845<p>Valid TLS protocol versions are <code>'TLSv1'</code>, <code>'TLSv1.1'</code>, or <code>'TLSv1.2'</code>.</p> 2846<p><a id="ERR_TLS_INVALID_STATE"></a></p> 2847<h4><code>ERR_TLS_INVALID_STATE</code><span><a class="mark" href="#err_tls_invalid_state" id="err_tls_invalid_state">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tls_invalid_state"></a></h4> 2848<div class="api_metadata"> 2849<span>Added in: v13.10.0, v12.17.0</span> 2850</div> 2851<p>The TLS socket must be connected and securely established. Ensure the 'secure' 2852event is emitted before continuing.</p> 2853<p><a id="ERR_TLS_PROTOCOL_VERSION_CONFLICT"></a></p> 2854<h4><code>ERR_TLS_PROTOCOL_VERSION_CONFLICT</code><span><a class="mark" href="#err_tls_protocol_version_conflict" id="err_tls_protocol_version_conflict">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tls_protocol_version_conflict"></a></h4> 2855<p>Attempting to set a TLS protocol <code>minVersion</code> or <code>maxVersion</code> conflicts with an 2856attempt to set the <code>secureProtocol</code> explicitly. Use one mechanism or the other.</p> 2857<p><a id="ERR_TLS_PSK_SET_IDENTIY_HINT_FAILED"></a></p> 2858<h4><code>ERR_TLS_PSK_SET_IDENTIY_HINT_FAILED</code><span><a class="mark" href="#err_tls_psk_set_identiy_hint_failed" id="err_tls_psk_set_identiy_hint_failed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tls_psk_set_identiy_hint_failed"></a></h4> 2859<p>Failed to set PSK identity hint. Hint may be too long.</p> 2860<p><a id="ERR_TLS_RENEGOTIATION_DISABLED"></a></p> 2861<h4><code>ERR_TLS_RENEGOTIATION_DISABLED</code><span><a class="mark" href="#err_tls_renegotiation_disabled" id="err_tls_renegotiation_disabled">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tls_renegotiation_disabled"></a></h4> 2862<p>An attempt was made to renegotiate TLS on a socket instance with renegotiation 2863disabled.</p> 2864<p><a id="ERR_TLS_REQUIRED_SERVER_NAME"></a></p> 2865<h4><code>ERR_TLS_REQUIRED_SERVER_NAME</code><span><a class="mark" href="#err_tls_required_server_name" id="err_tls_required_server_name">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tls_required_server_name"></a></h4> 2866<p>While using TLS, the <code>server.addContext()</code> method was called without providing 2867a host name in the first parameter.</p> 2868<p><a id="ERR_TLS_SESSION_ATTACK"></a></p> 2869<h4><code>ERR_TLS_SESSION_ATTACK</code><span><a class="mark" href="#err_tls_session_attack" id="err_tls_session_attack">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tls_session_attack"></a></h4> 2870<p>An excessive amount of TLS renegotiations is detected, which is a potential 2871vector for denial-of-service attacks.</p> 2872<p><a id="ERR_TLS_SNI_FROM_SERVER"></a></p> 2873<h4><code>ERR_TLS_SNI_FROM_SERVER</code><span><a class="mark" href="#err_tls_sni_from_server" id="err_tls_sni_from_server">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tls_sni_from_server"></a></h4> 2874<p>An attempt was made to issue Server Name Indication from a TLS server-side 2875socket, which is only valid from a client.</p> 2876<p><a id="ERR_TRACE_EVENTS_CATEGORY_REQUIRED"></a></p> 2877<h4><code>ERR_TRACE_EVENTS_CATEGORY_REQUIRED</code><span><a class="mark" href="#err_trace_events_category_required" id="err_trace_events_category_required">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_trace_events_category_required"></a></h4> 2878<p>The <code>trace_events.createTracing()</code> method requires at least one trace event 2879category.</p> 2880<p><a id="ERR_TRACE_EVENTS_UNAVAILABLE"></a></p> 2881<h4><code>ERR_TRACE_EVENTS_UNAVAILABLE</code><span><a class="mark" href="#err_trace_events_unavailable" id="err_trace_events_unavailable">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_trace_events_unavailable"></a></h4> 2882<p>The <code>node:trace_events</code> module could not be loaded because Node.js was compiled 2883with the <code>--without-v8-platform</code> flag.</p> 2884<p><a id="ERR_TRANSFORM_ALREADY_TRANSFORMING"></a></p> 2885<h4><code>ERR_TRANSFORM_ALREADY_TRANSFORMING</code><span><a class="mark" href="#err_transform_already_transforming" id="err_transform_already_transforming">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_transform_already_transforming"></a></h4> 2886<p>A <code>Transform</code> stream finished while it was still transforming.</p> 2887<p><a id="ERR_TRANSFORM_WITH_LENGTH_0"></a></p> 2888<h4><code>ERR_TRANSFORM_WITH_LENGTH_0</code><span><a class="mark" href="#err_transform_with_length_0" id="err_transform_with_length_0">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_transform_with_length_0"></a></h4> 2889<p>A <code>Transform</code> stream finished with data still in the write buffer.</p> 2890<p><a id="ERR_TTY_INIT_FAILED"></a></p> 2891<h4><code>ERR_TTY_INIT_FAILED</code><span><a class="mark" href="#err_tty_init_failed" id="err_tty_init_failed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tty_init_failed"></a></h4> 2892<p>The initialization of a TTY failed due to a system error.</p> 2893<p><a id="ERR_UNAVAILABLE_DURING_EXIT"></a></p> 2894<h4><code>ERR_UNAVAILABLE_DURING_EXIT</code><span><a class="mark" href="#err_unavailable_during_exit" id="err_unavailable_during_exit">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_unavailable_during_exit"></a></h4> 2895<p>Function was called within a <a href="process.html#event-exit"><code>process.on('exit')</code></a> handler that shouldn't be 2896called within <a href="process.html#event-exit"><code>process.on('exit')</code></a> handler.</p> 2897<p><a id="ERR_UNCAUGHT_EXCEPTION_CAPTURE_ALREADY_SET"></a></p> 2898<h4><code>ERR_UNCAUGHT_EXCEPTION_CAPTURE_ALREADY_SET</code><span><a class="mark" href="#err_uncaught_exception_capture_already_set" id="err_uncaught_exception_capture_already_set">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_uncaught_exception_capture_already_set"></a></h4> 2899<p><a href="process.html#processsetuncaughtexceptioncapturecallbackfn"><code>process.setUncaughtExceptionCaptureCallback()</code></a> was called twice, 2900without first resetting the callback to <code>null</code>.</p> 2901<p>This error is designed to prevent accidentally overwriting a callback registered 2902from another module.</p> 2903<p><a id="ERR_UNESCAPED_CHARACTERS"></a></p> 2904<h4><code>ERR_UNESCAPED_CHARACTERS</code><span><a class="mark" href="#err_unescaped_characters" id="err_unescaped_characters">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_unescaped_characters"></a></h4> 2905<p>A string that contained unescaped characters was received.</p> 2906<p><a id="ERR_UNHANDLED_ERROR"></a></p> 2907<h4><code>ERR_UNHANDLED_ERROR</code><span><a class="mark" href="#err_unhandled_error" id="err_unhandled_error">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_unhandled_error"></a></h4> 2908<p>An unhandled error occurred (for instance, when an <code>'error'</code> event is emitted 2909by an <a href="events.html#class-eventemitter"><code>EventEmitter</code></a> but an <code>'error'</code> handler is not registered).</p> 2910<p><a id="ERR_UNKNOWN_BUILTIN_MODULE"></a></p> 2911<h4><code>ERR_UNKNOWN_BUILTIN_MODULE</code><span><a class="mark" href="#err_unknown_builtin_module" id="err_unknown_builtin_module">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_unknown_builtin_module"></a></h4> 2912<p>Used to identify a specific kind of internal Node.js error that should not 2913typically be triggered by user code. Instances of this error point to an 2914internal bug within the Node.js binary itself.</p> 2915<p><a id="ERR_UNKNOWN_CREDENTIAL"></a></p> 2916<h4><code>ERR_UNKNOWN_CREDENTIAL</code><span><a class="mark" href="#err_unknown_credential" id="err_unknown_credential">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_unknown_credential"></a></h4> 2917<p>A Unix group or user identifier that does not exist was passed.</p> 2918<p><a id="ERR_UNKNOWN_ENCODING"></a></p> 2919<h4><code>ERR_UNKNOWN_ENCODING</code><span><a class="mark" href="#err_unknown_encoding" id="err_unknown_encoding">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_unknown_encoding"></a></h4> 2920<p>An invalid or unknown encoding option was passed to an API.</p> 2921<p><a id="ERR_UNKNOWN_FILE_EXTENSION"></a></p> 2922<h4><code>ERR_UNKNOWN_FILE_EXTENSION</code><span><a class="mark" href="#err_unknown_file_extension" id="err_unknown_file_extension">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_unknown_file_extension"></a></h4> 2923<p></p><div class="api_stability api_stability_1"><a href="documentation.html#stability-index">Stability: 1</a> - Experimental</div><p></p> 2924<p>An attempt was made to load a module with an unknown or unsupported file 2925extension.</p> 2926<p><a id="ERR_UNKNOWN_MODULE_FORMAT"></a></p> 2927<h4><code>ERR_UNKNOWN_MODULE_FORMAT</code><span><a class="mark" href="#err_unknown_module_format" id="err_unknown_module_format">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_unknown_module_format"></a></h4> 2928<p></p><div class="api_stability api_stability_1"><a href="documentation.html#stability-index">Stability: 1</a> - Experimental</div><p></p> 2929<p>An attempt was made to load a module with an unknown or unsupported format.</p> 2930<p><a id="ERR_UNKNOWN_SIGNAL"></a></p> 2931<h4><code>ERR_UNKNOWN_SIGNAL</code><span><a class="mark" href="#err_unknown_signal" id="err_unknown_signal">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_unknown_signal"></a></h4> 2932<p>An invalid or unknown process signal was passed to an API expecting a valid 2933signal (such as <a href="child_process.html#subprocesskillsignal"><code>subprocess.kill()</code></a>).</p> 2934<p><a id="ERR_UNSUPPORTED_DIR_IMPORT"></a></p> 2935<h4><code>ERR_UNSUPPORTED_DIR_IMPORT</code><span><a class="mark" href="#err_unsupported_dir_import" id="err_unsupported_dir_import">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_unsupported_dir_import"></a></h4> 2936<p><code>import</code> a directory URL is unsupported. Instead, 2937<a href="packages.html#self-referencing-a-package-using-its-name">self-reference a package using its name</a> and <a href="packages.html#subpath-exports">define a custom subpath</a> in 2938the <a href="packages.html#exports"><code>"exports"</code></a> field of the <a href="packages.html#nodejs-packagejson-field-definitions"><code>package.json</code></a> file.</p> 2939<!-- eslint-skip --> 2940<pre><code class="language-js"><span class="hljs-keyword">import</span> <span class="hljs-string">'./'</span>; <span class="hljs-comment">// unsupported</span> 2941<span class="hljs-keyword">import</span> <span class="hljs-string">'./index.js'</span>; <span class="hljs-comment">// supported</span> 2942<span class="hljs-keyword">import</span> <span class="hljs-string">'package-name'</span>; <span class="hljs-comment">// supported</span></code> <button class="copy-button">copy</button></pre> 2943<p><a id="ERR_UNSUPPORTED_ESM_URL_SCHEME"></a></p> 2944<h4><code>ERR_UNSUPPORTED_ESM_URL_SCHEME</code><span><a class="mark" href="#err_unsupported_esm_url_scheme" id="err_unsupported_esm_url_scheme">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_unsupported_esm_url_scheme"></a></h4> 2945<p><code>import</code> with URL schemes other than <code>file</code> and <code>data</code> is unsupported.</p> 2946<p><a id="ERR_USE_AFTER_CLOSE"></a></p> 2947<h4><code>ERR_USE_AFTER_CLOSE</code><span><a class="mark" href="#err_use_after_close" id="err_use_after_close">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_use_after_close"></a></h4> 2948<p></p><div class="api_stability api_stability_1"><a href="documentation.html#stability-index">Stability: 1</a> - Experimental</div><p></p> 2949<p>An attempt was made to use something that was already closed.</p> 2950<p><a id="ERR_VALID_PERFORMANCE_ENTRY_TYPE"></a></p> 2951<h4><code>ERR_VALID_PERFORMANCE_ENTRY_TYPE</code><span><a class="mark" href="#err_valid_performance_entry_type" id="err_valid_performance_entry_type">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_valid_performance_entry_type"></a></h4> 2952<p>While using the Performance Timing API (<code>perf_hooks</code>), no valid performance 2953entry types are found.</p> 2954<p><a id="ERR_VM_DYNAMIC_IMPORT_CALLBACK_MISSING"></a></p> 2955<h4><code>ERR_VM_DYNAMIC_IMPORT_CALLBACK_MISSING</code><span><a class="mark" href="#err_vm_dynamic_import_callback_missing" id="err_vm_dynamic_import_callback_missing">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_vm_dynamic_import_callback_missing"></a></h4> 2956<p>A dynamic import callback was not specified.</p> 2957<p><a id="ERR_VM_MODULE_ALREADY_LINKED"></a></p> 2958<h4><code>ERR_VM_MODULE_ALREADY_LINKED</code><span><a class="mark" href="#err_vm_module_already_linked" id="err_vm_module_already_linked">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_vm_module_already_linked"></a></h4> 2959<p>The module attempted to be linked is not eligible for linking, because of one of 2960the following reasons:</p> 2961<ul> 2962<li>It has already been linked (<code>linkingStatus</code> is <code>'linked'</code>)</li> 2963<li>It is being linked (<code>linkingStatus</code> is <code>'linking'</code>)</li> 2964<li>Linking has failed for this module (<code>linkingStatus</code> is <code>'errored'</code>)</li> 2965</ul> 2966<p><a id="ERR_VM_MODULE_CACHED_DATA_REJECTED"></a></p> 2967<h4><code>ERR_VM_MODULE_CACHED_DATA_REJECTED</code><span><a class="mark" href="#err_vm_module_cached_data_rejected" id="err_vm_module_cached_data_rejected">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_vm_module_cached_data_rejected"></a></h4> 2968<p>The <code>cachedData</code> option passed to a module constructor is invalid.</p> 2969<p><a id="ERR_VM_MODULE_CANNOT_CREATE_CACHED_DATA"></a></p> 2970<h4><code>ERR_VM_MODULE_CANNOT_CREATE_CACHED_DATA</code><span><a class="mark" href="#err_vm_module_cannot_create_cached_data" id="err_vm_module_cannot_create_cached_data">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_vm_module_cannot_create_cached_data"></a></h4> 2971<p>Cached data cannot be created for modules which have already been evaluated.</p> 2972<p><a id="ERR_VM_MODULE_DIFFERENT_CONTEXT"></a></p> 2973<h4><code>ERR_VM_MODULE_DIFFERENT_CONTEXT</code><span><a class="mark" href="#err_vm_module_different_context" id="err_vm_module_different_context">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_vm_module_different_context"></a></h4> 2974<p>The module being returned from the linker function is from a different context 2975than the parent module. Linked modules must share the same context.</p> 2976<p><a id="ERR_VM_MODULE_LINK_FAILURE"></a></p> 2977<h4><code>ERR_VM_MODULE_LINK_FAILURE</code><span><a class="mark" href="#err_vm_module_link_failure" id="err_vm_module_link_failure">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_vm_module_link_failure"></a></h4> 2978<p>The module was unable to be linked due to a failure.</p> 2979<p><a id="ERR_VM_MODULE_NOT_MODULE"></a></p> 2980<h4><code>ERR_VM_MODULE_NOT_MODULE</code><span><a class="mark" href="#err_vm_module_not_module" id="err_vm_module_not_module">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_vm_module_not_module"></a></h4> 2981<p>The fulfilled value of a linking promise is not a <code>vm.Module</code> object.</p> 2982<p><a id="ERR_VM_MODULE_STATUS"></a></p> 2983<h4><code>ERR_VM_MODULE_STATUS</code><span><a class="mark" href="#err_vm_module_status" id="err_vm_module_status">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_vm_module_status"></a></h4> 2984<p>The current module's status does not allow for this operation. The specific 2985meaning of the error depends on the specific function.</p> 2986<p><a id="ERR_WASI_ALREADY_STARTED"></a></p> 2987<h4><code>ERR_WASI_ALREADY_STARTED</code><span><a class="mark" href="#err_wasi_already_started" id="err_wasi_already_started">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_wasi_already_started"></a></h4> 2988<p>The WASI instance has already started.</p> 2989<p><a id="ERR_WASI_NOT_STARTED"></a></p> 2990<h4><code>ERR_WASI_NOT_STARTED</code><span><a class="mark" href="#err_wasi_not_started" id="err_wasi_not_started">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_wasi_not_started"></a></h4> 2991<p>The WASI instance has not been started.</p> 2992<p><a id="ERR_WEBASSEMBLY_RESPONSE"></a></p> 2993<h4><code>ERR_WEBASSEMBLY_RESPONSE</code><span><a class="mark" href="#err_webassembly_response" id="err_webassembly_response">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_webassembly_response"></a></h4> 2994<div class="api_metadata"> 2995<span>Added in: v18.1.0</span> 2996</div> 2997<p>The <code>Response</code> that has been passed to <code>WebAssembly.compileStreaming</code> or to 2998<code>WebAssembly.instantiateStreaming</code> is not a valid WebAssembly response.</p> 2999<p><a id="ERR_WORKER_INIT_FAILED"></a></p> 3000<h4><code>ERR_WORKER_INIT_FAILED</code><span><a class="mark" href="#err_worker_init_failed" id="err_worker_init_failed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_worker_init_failed"></a></h4> 3001<p>The <code>Worker</code> initialization failed.</p> 3002<p><a id="ERR_WORKER_INVALID_EXEC_ARGV"></a></p> 3003<h4><code>ERR_WORKER_INVALID_EXEC_ARGV</code><span><a class="mark" href="#err_worker_invalid_exec_argv" id="err_worker_invalid_exec_argv">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_worker_invalid_exec_argv"></a></h4> 3004<p>The <code>execArgv</code> option passed to the <code>Worker</code> constructor contains 3005invalid flags.</p> 3006<p><a id="ERR_WORKER_NOT_RUNNING"></a></p> 3007<h4><code>ERR_WORKER_NOT_RUNNING</code><span><a class="mark" href="#err_worker_not_running" id="err_worker_not_running">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_worker_not_running"></a></h4> 3008<p>An operation failed because the <code>Worker</code> instance is not currently running.</p> 3009<p><a id="ERR_WORKER_OUT_OF_MEMORY"></a></p> 3010<h4><code>ERR_WORKER_OUT_OF_MEMORY</code><span><a class="mark" href="#err_worker_out_of_memory" id="err_worker_out_of_memory">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_worker_out_of_memory"></a></h4> 3011<p>The <code>Worker</code> instance terminated because it reached its memory limit.</p> 3012<p><a id="ERR_WORKER_PATH"></a></p> 3013<h4><code>ERR_WORKER_PATH</code><span><a class="mark" href="#err_worker_path" id="err_worker_path">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_worker_path"></a></h4> 3014<p>The path for the main script of a worker is neither an absolute path 3015nor a relative path starting with <code>./</code> or <code>../</code>.</p> 3016<p><a id="ERR_WORKER_UNSERIALIZABLE_ERROR"></a></p> 3017<h4><code>ERR_WORKER_UNSERIALIZABLE_ERROR</code><span><a class="mark" href="#err_worker_unserializable_error" id="err_worker_unserializable_error">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_worker_unserializable_error"></a></h4> 3018<p>All attempts at serializing an uncaught exception from a worker thread failed.</p> 3019<p><a id="ERR_WORKER_UNSUPPORTED_OPERATION"></a></p> 3020<h4><code>ERR_WORKER_UNSUPPORTED_OPERATION</code><span><a class="mark" href="#err_worker_unsupported_operation" id="err_worker_unsupported_operation">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_worker_unsupported_operation"></a></h4> 3021<p>The requested functionality is not supported in worker threads.</p> 3022<p><a id="ERR_ZLIB_INITIALIZATION_FAILED"></a></p> 3023<h4><code>ERR_ZLIB_INITIALIZATION_FAILED</code><span><a class="mark" href="#err_zlib_initialization_failed" id="err_zlib_initialization_failed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_zlib_initialization_failed"></a></h4> 3024<p>Creation of a <a href="zlib.html"><code>zlib</code></a> object failed due to incorrect configuration.</p> 3025<p><a id="HPE_HEADER_OVERFLOW"></a></p> 3026<h4><code>HPE_HEADER_OVERFLOW</code><span><a class="mark" href="#hpe_header_overflow" id="hpe_header_overflow">#</a></span><a aria-hidden="true" class="legacy" id="errors_hpe_header_overflow"></a></h4> 3027<div class="api_metadata"> 3028<details class="changelog"><summary>History</summary> 3029<table> 3030<tbody><tr><th>Version</th><th>Changes</th></tr> 3031<tr><td>v11.4.0, v10.15.0</td> 3032<td><p>Max header size in <code>http_parser</code> was set to 8 KiB.</p></td></tr> 3033</tbody></table> 3034</details> 3035</div> 3036<p>Too much HTTP header data was received. In order to protect against malicious or 3037malconfigured clients, if more than 8 KiB of HTTP header data is received then 3038HTTP parsing will abort without a request or response object being created, and 3039an <code>Error</code> with this code will be emitted.</p> 3040<p><a id="HPE_UNEXPECTED_CONTENT_LENGTH"></a></p> 3041<h4><code>HPE_UNEXPECTED_CONTENT_LENGTH</code><span><a class="mark" href="#hpe_unexpected_content_length" id="hpe_unexpected_content_length">#</a></span><a aria-hidden="true" class="legacy" id="errors_hpe_unexpected_content_length"></a></h4> 3042<p>Server is sending both a <code>Content-Length</code> header and <code>Transfer-Encoding: chunked</code>.</p> 3043<p><code>Transfer-Encoding: chunked</code> allows the server to maintain an HTTP persistent 3044connection for dynamically generated content. 3045In this case, the <code>Content-Length</code> HTTP header cannot be used.</p> 3046<p>Use <code>Content-Length</code> or <code>Transfer-Encoding: chunked</code>.</p> 3047<p><a id="MODULE_NOT_FOUND"></a></p> 3048<h4><code>MODULE_NOT_FOUND</code><span><a class="mark" href="#module_not_found" id="module_not_found">#</a></span><a aria-hidden="true" class="legacy" id="errors_module_not_found"></a></h4> 3049<div class="api_metadata"> 3050<details class="changelog"><summary>History</summary> 3051<table> 3052<tbody><tr><th>Version</th><th>Changes</th></tr> 3053<tr><td>v12.0.0</td> 3054<td><p>Added <code>requireStack</code> property.</p></td></tr> 3055</tbody></table> 3056</details> 3057</div> 3058<p>A module file could not be resolved by the CommonJS modules loader while 3059attempting a <a href="modules.html#requireid"><code>require()</code></a> operation or when loading the program entry point.</p> 3060</section><section><h3>Legacy Node.js error codes<span><a class="mark" href="#legacy-nodejs-error-codes" id="legacy-nodejs-error-codes">#</a></span><a aria-hidden="true" class="legacy" id="errors_legacy_node_js_error_codes"></a></h3> 3061<p></p><div class="api_stability api_stability_0"><a href="documentation.html#stability-index">Stability: 0</a> - Deprecated. These error codes are either inconsistent, or have 3062been removed.</div><p></p> 3063<p><a id="ERR_CANNOT_TRANSFER_OBJECT"></a></p> 3064<h4><code>ERR_CANNOT_TRANSFER_OBJECT</code><span><a class="mark" href="#err_cannot_transfer_object" id="err_cannot_transfer_object">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_cannot_transfer_object"></a></h4> 3065<!-- 3066added: v10.5.0 3067removed: v12.5.0 3068--> 3069<p>The value passed to <code>postMessage()</code> contained an object that is not supported 3070for transferring.</p> 3071<p><a id="ERR_CRYPTO_HASH_DIGEST_NO_UTF16"></a></p> 3072<h4><code>ERR_CRYPTO_HASH_DIGEST_NO_UTF16</code><span><a class="mark" href="#err_crypto_hash_digest_no_utf16" id="err_crypto_hash_digest_no_utf16">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_crypto_hash_digest_no_utf16"></a></h4> 3073<div class="api_metadata"> 3074<span>Added in: v9.0.0</span><span>Removed in: v12.12.0</span> 3075</div> 3076<p>The UTF-16 encoding was used with <a href="crypto.html#hashdigestencoding"><code>hash.digest()</code></a>. While the 3077<code>hash.digest()</code> method does allow an <code>encoding</code> argument to be passed in, 3078causing the method to return a string rather than a <code>Buffer</code>, the UTF-16 3079encoding (e.g. <code>ucs</code> or <code>utf16le</code>) is not supported.</p> 3080<p><a id="ERR_HTTP2_FRAME_ERROR"></a></p> 3081<h4><code>ERR_HTTP2_FRAME_ERROR</code><span><a class="mark" href="#err_http2_frame_error" id="err_http2_frame_error">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_frame_error"></a></h4> 3082<div class="api_metadata"> 3083<span>Added in: v9.0.0</span><span>Removed in: v10.0.0</span> 3084</div> 3085<p>Used when a failure occurs sending an individual frame on the HTTP/2 3086session.</p> 3087<p><a id="ERR_HTTP2_HEADERS_OBJECT"></a></p> 3088<h4><code>ERR_HTTP2_HEADERS_OBJECT</code><span><a class="mark" href="#err_http2_headers_object" id="err_http2_headers_object">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_headers_object"></a></h4> 3089<div class="api_metadata"> 3090<span>Added in: v9.0.0</span><span>Removed in: v10.0.0</span> 3091</div> 3092<p>Used when an HTTP/2 Headers Object is expected.</p> 3093<p><a id="ERR_HTTP2_HEADER_REQUIRED"></a></p> 3094<h4><code>ERR_HTTP2_HEADER_REQUIRED</code><span><a class="mark" href="#err_http2_header_required" id="err_http2_header_required">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_header_required"></a></h4> 3095<div class="api_metadata"> 3096<span>Added in: v9.0.0</span><span>Removed in: v10.0.0</span> 3097</div> 3098<p>Used when a required header is missing in an HTTP/2 message.</p> 3099<p><a id="ERR_HTTP2_INFO_HEADERS_AFTER_RESPOND"></a></p> 3100<h4><code>ERR_HTTP2_INFO_HEADERS_AFTER_RESPOND</code><span><a class="mark" href="#err_http2_info_headers_after_respond" id="err_http2_info_headers_after_respond">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_info_headers_after_respond"></a></h4> 3101<div class="api_metadata"> 3102<span>Added in: v9.0.0</span><span>Removed in: v10.0.0</span> 3103</div> 3104<p>HTTP/2 informational headers must only be sent <em>prior</em> to calling the 3105<code>Http2Stream.prototype.respond()</code> method.</p> 3106<p><a id="ERR_HTTP2_STREAM_CLOSED"></a></p> 3107<h4><code>ERR_HTTP2_STREAM_CLOSED</code><span><a class="mark" href="#err_http2_stream_closed" id="err_http2_stream_closed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http2_stream_closed"></a></h4> 3108<div class="api_metadata"> 3109<span>Added in: v9.0.0</span><span>Removed in: v10.0.0</span> 3110</div> 3111<p>Used when an action has been performed on an HTTP/2 Stream that has already 3112been closed.</p> 3113<p><a id="ERR_HTTP_INVALID_CHAR"></a></p> 3114<h4><code>ERR_HTTP_INVALID_CHAR</code><span><a class="mark" href="#err_http_invalid_char" id="err_http_invalid_char">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_http_invalid_char"></a></h4> 3115<div class="api_metadata"> 3116<span>Added in: v9.0.0</span><span>Removed in: v10.0.0</span> 3117</div> 3118<p>Used when an invalid character is found in an HTTP response status message 3119(reason phrase).</p> 3120<p><a id="ERR_INDEX_OUT_OF_RANGE"></a></p> 3121<h4><code>ERR_INDEX_OUT_OF_RANGE</code><span><a class="mark" href="#err_index_out_of_range" id="err_index_out_of_range">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_index_out_of_range"></a></h4> 3122<div class="api_metadata"> 3123<span>Added in: v10.0.0</span><span>Removed in: v11.0.0</span> 3124</div> 3125<p>A given index was out of the accepted range (e.g. negative offsets).</p> 3126<p><a id="ERR_INVALID_OPT_VALUE"></a></p> 3127<h4><code>ERR_INVALID_OPT_VALUE</code><span><a class="mark" href="#err_invalid_opt_value" id="err_invalid_opt_value">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_opt_value"></a></h4> 3128<div class="api_metadata"> 3129<span>Added in: v8.0.0</span><span>Removed in: v15.0.0</span> 3130</div> 3131<p>An invalid or unexpected value was passed in an options object.</p> 3132<p><a id="ERR_INVALID_OPT_VALUE_ENCODING"></a></p> 3133<h4><code>ERR_INVALID_OPT_VALUE_ENCODING</code><span><a class="mark" href="#err_invalid_opt_value_encoding" id="err_invalid_opt_value_encoding">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_invalid_opt_value_encoding"></a></h4> 3134<div class="api_metadata"> 3135<span>Added in: v9.0.0</span><span>Removed in: v15.0.0</span> 3136</div> 3137<p>An invalid or unknown file encoding was passed.</p> 3138<p><a id="ERR_MISSING_MESSAGE_PORT_IN_TRANSFER_LIST"></a></p> 3139<h4><code>ERR_MISSING_MESSAGE_PORT_IN_TRANSFER_LIST</code><span><a class="mark" href="#err_missing_message_port_in_transfer_list" id="err_missing_message_port_in_transfer_list">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_missing_message_port_in_transfer_list"></a></h4> 3140<div class="api_metadata"> 3141<span>Removed in: v15.0.0</span> 3142</div> 3143<p>This error code was replaced by <a href="#err_missing_transferable_in_transfer_list"><code>ERR_MISSING_TRANSFERABLE_IN_TRANSFER_LIST</code></a> 3144in Node.js v15.0.0, because it is no longer accurate as other types of 3145transferable objects also exist now.</p> 3146<p><a id="ERR_NAPI_CONS_PROTOTYPE_OBJECT"></a></p> 3147<h4><code>ERR_NAPI_CONS_PROTOTYPE_OBJECT</code><span><a class="mark" href="#err_napi_cons_prototype_object" id="err_napi_cons_prototype_object">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_napi_cons_prototype_object"></a></h4> 3148<div class="api_metadata"> 3149<span>Added in: v9.0.0</span><span>Removed in: v10.0.0</span> 3150</div> 3151<p>Used by the <code>Node-API</code> when <code>Constructor.prototype</code> is not an object.</p> 3152<p><a id="ERR_NETWORK_IMPORT_BAD_RESPONSE"></a></p> 3153<h4><code>ERR_NETWORK_IMPORT_BAD_RESPONSE</code><span><a class="mark" href="#err_network_import_bad_response" id="err_network_import_bad_response">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_network_import_bad_response"></a></h4> 3154<p></p><div class="api_stability api_stability_1"><a href="documentation.html#stability-index">Stability: 1</a> - Experimental</div><p></p> 3155<p>Response was received but was invalid when importing a module over the network.</p> 3156<p><a id="ERR_NETWORK_IMPORT_DISALLOWED"></a></p> 3157<h4><code>ERR_NETWORK_IMPORT_DISALLOWED</code><span><a class="mark" href="#err_network_import_disallowed" id="err_network_import_disallowed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_network_import_disallowed"></a></h4> 3158<p></p><div class="api_stability api_stability_1"><a href="documentation.html#stability-index">Stability: 1</a> - Experimental</div><p></p> 3159<p>A network module attempted to load another module that it is not allowed to 3160load. Likely this restriction is for security reasons.</p> 3161<p><a id="ERR_NO_LONGER_SUPPORTED"></a></p> 3162<h4><code>ERR_NO_LONGER_SUPPORTED</code><span><a class="mark" href="#err_no_longer_supported" id="err_no_longer_supported">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_no_longer_supported"></a></h4> 3163<p>A Node.js API was called in an unsupported manner, such as 3164<code>Buffer.write(string, encoding, offset[, length])</code>.</p> 3165<p><a id="ERR_OPERATION_FAILED"></a></p> 3166<h4><code>ERR_OPERATION_FAILED</code><span><a class="mark" href="#err_operation_failed" id="err_operation_failed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_operation_failed"></a></h4> 3167<div class="api_metadata"> 3168<span>Added in: v15.0.0</span> 3169</div> 3170<p>An operation failed. This is typically used to signal the general failure 3171of an asynchronous operation.</p> 3172<p><a id="ERR_OUTOFMEMORY"></a></p> 3173<h4><code>ERR_OUTOFMEMORY</code><span><a class="mark" href="#err_outofmemory" id="err_outofmemory">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_outofmemory"></a></h4> 3174<div class="api_metadata"> 3175<span>Added in: v9.0.0</span><span>Removed in: v10.0.0</span> 3176</div> 3177<p>Used generically to identify that an operation caused an out of memory 3178condition.</p> 3179<p><a id="ERR_PARSE_HISTORY_DATA"></a></p> 3180<h4><code>ERR_PARSE_HISTORY_DATA</code><span><a class="mark" href="#err_parse_history_data" id="err_parse_history_data">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_parse_history_data"></a></h4> 3181<div class="api_metadata"> 3182<span>Added in: v9.0.0</span><span>Removed in: v10.0.0</span> 3183</div> 3184<p>The <code>node:repl</code> module was unable to parse data from the REPL history file.</p> 3185<p><a id="ERR_SOCKET_CANNOT_SEND"></a></p> 3186<h4><code>ERR_SOCKET_CANNOT_SEND</code><span><a class="mark" href="#err_socket_cannot_send" id="err_socket_cannot_send">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_socket_cannot_send"></a></h4> 3187<div class="api_metadata"> 3188<span>Added in: v9.0.0</span><span>Removed in: v14.0.0</span> 3189</div> 3190<p>Data could not be sent on a socket.</p> 3191<p><a id="ERR_STDERR_CLOSE"></a></p> 3192<h4><code>ERR_STDERR_CLOSE</code><span><a class="mark" href="#err_stderr_close" id="err_stderr_close">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_stderr_close"></a></h4> 3193<div class="api_metadata"> 3194<details class="changelog"><summary>History</summary> 3195<table> 3196<tbody><tr><th>Version</th><th>Changes</th></tr> 3197<tr><td>v10.12.0</td> 3198<td><p>Rather than emitting an error, <code>process.stderr.end()</code> now only closes the stream side but not the underlying resource, making this error obsolete.</p></td></tr> 3199<tr><td>v10.12.0</td> 3200<td><p><span>Removed in: v10.12.0</span></p></td></tr> 3201</tbody></table> 3202</details> 3203</div> 3204<p>An attempt was made to close the <code>process.stderr</code> stream. By design, Node.js 3205does not allow <code>stdout</code> or <code>stderr</code> streams to be closed by user code.</p> 3206<p><a id="ERR_STDOUT_CLOSE"></a></p> 3207<h4><code>ERR_STDOUT_CLOSE</code><span><a class="mark" href="#err_stdout_close" id="err_stdout_close">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_stdout_close"></a></h4> 3208<div class="api_metadata"> 3209<details class="changelog"><summary>History</summary> 3210<table> 3211<tbody><tr><th>Version</th><th>Changes</th></tr> 3212<tr><td>v10.12.0</td> 3213<td><p>Rather than emitting an error, <code>process.stderr.end()</code> now only closes the stream side but not the underlying resource, making this error obsolete.</p></td></tr> 3214<tr><td>v10.12.0</td> 3215<td><p><span>Removed in: v10.12.0</span></p></td></tr> 3216</tbody></table> 3217</details> 3218</div> 3219<p>An attempt was made to close the <code>process.stdout</code> stream. By design, Node.js 3220does not allow <code>stdout</code> or <code>stderr</code> streams to be closed by user code.</p> 3221<p><a id="ERR_STREAM_READ_NOT_IMPLEMENTED"></a></p> 3222<h4><code>ERR_STREAM_READ_NOT_IMPLEMENTED</code><span><a class="mark" href="#err_stream_read_not_implemented" id="err_stream_read_not_implemented">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_stream_read_not_implemented"></a></h4> 3223<div class="api_metadata"> 3224<span>Added in: v9.0.0</span><span>Removed in: v10.0.0</span> 3225</div> 3226<p>Used when an attempt is made to use a readable stream that has not implemented 3227<a href="stream.html#readable_readsize"><code>readable._read()</code></a>.</p> 3228<p><a id="ERR_TLS_RENEGOTIATION_FAILED"></a></p> 3229<h4><code>ERR_TLS_RENEGOTIATION_FAILED</code><span><a class="mark" href="#err_tls_renegotiation_failed" id="err_tls_renegotiation_failed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_tls_renegotiation_failed"></a></h4> 3230<div class="api_metadata"> 3231<span>Added in: v9.0.0</span><span>Removed in: v10.0.0</span> 3232</div> 3233<p>Used when a TLS renegotiation request has failed in a non-specific way.</p> 3234<p><a id="ERR_TRANSFERRING_EXTERNALIZED_SHAREDARRAYBUFFER"></a></p> 3235<h4><code>ERR_TRANSFERRING_EXTERNALIZED_SHAREDARRAYBUFFER</code><span><a class="mark" href="#err_transferring_externalized_sharedarraybuffer" id="err_transferring_externalized_sharedarraybuffer">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_transferring_externalized_sharedarraybuffer"></a></h4> 3236<div class="api_metadata"> 3237<span>Added in: v10.5.0</span><span>Removed in: v14.0.0</span> 3238</div> 3239<p>A <code>SharedArrayBuffer</code> whose memory is not managed by the JavaScript engine 3240or by Node.js was encountered during serialization. Such a <code>SharedArrayBuffer</code> 3241cannot be serialized.</p> 3242<p>This can only happen when native addons create <code>SharedArrayBuffer</code>s in 3243"externalized" mode, or put existing <code>SharedArrayBuffer</code> into externalized mode.</p> 3244<p><a id="ERR_UNKNOWN_STDIN_TYPE"></a></p> 3245<h4><code>ERR_UNKNOWN_STDIN_TYPE</code><span><a class="mark" href="#err_unknown_stdin_type" id="err_unknown_stdin_type">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_unknown_stdin_type"></a></h4> 3246<div class="api_metadata"> 3247<span>Added in: v8.0.0</span><span>Removed in: v11.7.0</span> 3248</div> 3249<p>An attempt was made to launch a Node.js process with an unknown <code>stdin</code> file 3250type. This error is usually an indication of a bug within Node.js itself, 3251although it is possible for user code to trigger it.</p> 3252<p><a id="ERR_UNKNOWN_STREAM_TYPE"></a></p> 3253<h4><code>ERR_UNKNOWN_STREAM_TYPE</code><span><a class="mark" href="#err_unknown_stream_type" id="err_unknown_stream_type">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_unknown_stream_type"></a></h4> 3254<div class="api_metadata"> 3255<span>Added in: v8.0.0</span><span>Removed in: v11.7.0</span> 3256</div> 3257<p>An attempt was made to launch a Node.js process with an unknown <code>stdout</code> or 3258<code>stderr</code> file type. This error is usually an indication of a bug within Node.js 3259itself, although it is possible for user code to trigger it.</p> 3260<p><a id="ERR_V8BREAKITERATOR"></a></p> 3261<h4><code>ERR_V8BREAKITERATOR</code><span><a class="mark" href="#err_v8breakiterator" id="err_v8breakiterator">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_v8breakiterator"></a></h4> 3262<p>The V8 <code>BreakIterator</code> API was used but the full ICU data set is not installed.</p> 3263<p><a id="ERR_VALUE_OUT_OF_RANGE"></a></p> 3264<h4><code>ERR_VALUE_OUT_OF_RANGE</code><span><a class="mark" href="#err_value_out_of_range" id="err_value_out_of_range">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_value_out_of_range"></a></h4> 3265<div class="api_metadata"> 3266<span>Added in: v9.0.0</span><span>Removed in: v10.0.0</span> 3267</div> 3268<p>Used when a given value is out of the accepted range.</p> 3269<p><a id="ERR_VM_MODULE_NOT_LINKED"></a></p> 3270<h4><code>ERR_VM_MODULE_NOT_LINKED</code><span><a class="mark" href="#err_vm_module_not_linked" id="err_vm_module_not_linked">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_vm_module_not_linked"></a></h4> 3271<p>The module must be successfully linked before instantiation.</p> 3272<p><a id="ERR_VM_MODULE_LINKING_ERRORED"></a></p> 3273<h4><code>ERR_VM_MODULE_LINKING_ERRORED</code><span><a class="mark" href="#err_vm_module_linking_errored" id="err_vm_module_linking_errored">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_vm_module_linking_errored"></a></h4> 3274<div class="api_metadata"> 3275<span>Added in: v10.0.0</span><span>Removed in: v18.1.0</span> 3276</div> 3277<p>The linker function returned a module for which linking has failed.</p> 3278<p><a id="ERR_WORKER_UNSUPPORTED_EXTENSION"></a></p> 3279<h4><code>ERR_WORKER_UNSUPPORTED_EXTENSION</code><span><a class="mark" href="#err_worker_unsupported_extension" id="err_worker_unsupported_extension">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_worker_unsupported_extension"></a></h4> 3280<div class="api_metadata"> 3281<span>Added in: v11.0.0</span><span>Removed in: v16.9.0</span> 3282</div> 3283<p>The pathname used for the main script of a worker has an 3284unknown file extension.</p> 3285<p><a id="ERR_ZLIB_BINDING_CLOSED"></a></p> 3286<h4><code>ERR_ZLIB_BINDING_CLOSED</code><span><a class="mark" href="#err_zlib_binding_closed" id="err_zlib_binding_closed">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_zlib_binding_closed"></a></h4> 3287<div class="api_metadata"> 3288<span>Added in: v9.0.0</span><span>Removed in: v10.0.0</span> 3289</div> 3290<p>Used when an attempt is made to use a <code>zlib</code> object after it has already been 3291closed.</p> 3292<p><a id="ERR_CPU_USAGE"></a></p> 3293<h4><code>ERR_CPU_USAGE</code><span><a class="mark" href="#err_cpu_usage" id="err_cpu_usage">#</a></span><a aria-hidden="true" class="legacy" id="errors_err_cpu_usage"></a></h4> 3294<div class="api_metadata"> 3295<span>Removed in: v15.0.0</span> 3296</div> 3297<p>The native call from <code>process.cpuUsage</code> could not be processed.</p></section> 3298 <!-- API END --> 3299 </div> 3300 </div> 3301 </div> 3302</body> 3303</html> 3304