• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Errors
2
3<!--introduced_in=v4.0.0-->
4
5<!--type=misc-->
6
7Applications running in Node.js will generally experience four categories of
8errors:
9
10* Standard JavaScript errors such as {EvalError}, {SyntaxError}, {RangeError},
11  {ReferenceError}, {TypeError}, and {URIError}.
12* System errors triggered by underlying operating system constraints such
13  as attempting to open a file that does not exist or attempting to send data
14  over a closed socket.
15* User-specified errors triggered by application code.
16* `AssertionError`s are a special class of error that can be triggered when
17  Node.js detects an exceptional logic violation that should never occur. These
18  are raised typically by the `node:assert` module.
19
20All JavaScript and system errors raised by Node.js inherit from, or are
21instances of, the standard JavaScript {Error} class and are guaranteed
22to provide _at least_ the properties available on that class.
23
24## Error propagation and interception
25
26<!--type=misc-->
27
28Node.js supports several mechanisms for propagating and handling errors that
29occur while an application is running. How these errors are reported and
30handled depends entirely on the type of `Error` and the style of the API that is
31called.
32
33All JavaScript errors are handled as exceptions that _immediately_ generate
34and throw an error using the standard JavaScript `throw` mechanism. These
35are handled using the [`try…catch` construct][try-catch] provided by the
36JavaScript language.
37
38```js
39// Throws with a ReferenceError because z is not defined.
40try {
41  const m = 1;
42  const n = m + z;
43} catch (err) {
44  // Handle the error here.
45}
46```
47
48Any use of the JavaScript `throw` mechanism will raise an exception that
49_must_ be handled or the Node.js process will exit immediately.
50
51With few exceptions, _Synchronous_ APIs (any blocking method that does not
52return a {Promise} nor accept a `callback` function, such as
53[`fs.readFileSync`][]), will use `throw` to report errors.
54
55Errors that occur within _Asynchronous APIs_ may be reported in multiple ways:
56
57* Some asynchronous methods returns a {Promise}, you should always take into
58  account that it might be rejected. See [`--unhandled-rejections`][] flag for
59  how the process will react to an unhandled promise rejection.
60
61  <!-- eslint-disable no-useless-return -->
62
63  ```js
64  const fs = require('fs/promises');
65
66  (async () => {
67    let data;
68    try {
69      data = await fs.readFile('a file that does not exist');
70    } catch (err) {
71      console.error('There was an error reading the file!', err);
72      return;
73    }
74    // Otherwise handle the data
75  })();
76  ```
77
78* Most asynchronous methods that accept a `callback` function will accept an
79  `Error` object passed as the first argument to that function. If that first
80  argument is not `null` and is an instance of `Error`, then an error occurred
81  that should be handled.
82
83  <!-- eslint-disable no-useless-return -->
84
85  ```js
86  const fs = require('node:fs');
87  fs.readFile('a file that does not exist', (err, data) => {
88    if (err) {
89      console.error('There was an error reading the file!', err);
90      return;
91    }
92    // Otherwise handle the data
93  });
94  ```
95
96* When an asynchronous method is called on an object that is an
97  [`EventEmitter`][], errors can be routed to that object's `'error'` event.
98
99  ```js
100  const net = require('node:net');
101  const connection = net.connect('localhost');
102
103  // Adding an 'error' event handler to a stream:
104  connection.on('error', (err) => {
105    // If the connection is reset by the server, or if it can't
106    // connect at all, or on any sort of error encountered by
107    // the connection, the error will be sent here.
108    console.error(err);
109  });
110
111  connection.pipe(process.stdout);
112  ```
113
114* A handful of typically asynchronous methods in the Node.js API may still
115  use the `throw` mechanism to raise exceptions that must be handled using
116  `try…catch`. There is no comprehensive list of such methods; please
117  refer to the documentation of each method to determine the appropriate
118  error handling mechanism required.
119
120The use of the `'error'` event mechanism is most common for [stream-based][]
121and [event emitter-based][] APIs, which themselves represent a series of
122asynchronous operations over time (as opposed to a single operation that may
123pass or fail).
124
125For _all_ [`EventEmitter`][] objects, if an `'error'` event handler is not
126provided, the error will be thrown, causing the Node.js process to report an
127uncaught exception and crash unless either: a handler has been registered for
128the [`'uncaughtException'`][] event, or the deprecated [`node:domain`][domains]
129module is used.
130
131```js
132const EventEmitter = require('node:events');
133const ee = new EventEmitter();
134
135setImmediate(() => {
136  // This will crash the process because no 'error' event
137  // handler has been added.
138  ee.emit('error', new Error('This will crash'));
139});
140```
141
142Errors generated in this way _cannot_ be intercepted using `try…catch` as
143they are thrown _after_ the calling code has already exited.
144
145Developers must refer to the documentation for each method to determine
146exactly how errors raised by those methods are propagated.
147
148## Class: `Error`
149
150<!--type=class-->
151
152A generic JavaScript {Error} object that does not denote any specific
153circumstance of why the error occurred. `Error` objects capture a "stack trace"
154detailing the point in the code at which the `Error` was instantiated, and may
155provide a text description of the error.
156
157All errors generated by Node.js, including all system and JavaScript errors,
158will either be instances of, or inherit from, the `Error` class.
159
160### `new Error(message[, options])`
161
162* `message` {string}
163* `options` {Object}
164  * `cause` {any} The error that caused the newly created error.
165
166Creates a new `Error` object and sets the `error.message` property to the
167provided text message. If an object is passed as `message`, the text message
168is generated by calling `String(message)`. If the `cause` option is provided,
169it is assigned to the `error.cause` property. The `error.stack` property will
170represent the point in the code at which `new Error()` was called. Stack traces
171are dependent on [V8's stack trace API][]. Stack traces extend only to either
172(a) the beginning of _synchronous code execution_, or (b) the number of frames
173given by the property `Error.stackTraceLimit`, whichever is smaller.
174
175### `Error.captureStackTrace(targetObject[, constructorOpt])`
176
177* `targetObject` {Object}
178* `constructorOpt` {Function}
179
180Creates a `.stack` property on `targetObject`, which when accessed returns
181a string representing the location in the code at which
182`Error.captureStackTrace()` was called.
183
184```js
185const myObject = {};
186Error.captureStackTrace(myObject);
187myObject.stack;  // Similar to `new Error().stack`
188```
189
190The first line of the trace will be prefixed with
191`${myObject.name}: ${myObject.message}`.
192
193The optional `constructorOpt` argument accepts a function. If given, all frames
194above `constructorOpt`, including `constructorOpt`, will be omitted from the
195generated stack trace.
196
197The `constructorOpt` argument is useful for hiding implementation
198details of error generation from the user. For instance:
199
200```js
201function a() {
202  b();
203}
204
205function b() {
206  c();
207}
208
209function c() {
210  // Create an error without stack trace to avoid calculating the stack trace twice.
211  const { stackTraceLimit } = Error;
212  Error.stackTraceLimit = 0;
213  const error = new Error();
214  Error.stackTraceLimit = stackTraceLimit;
215
216  // Capture the stack trace above function b
217  Error.captureStackTrace(error, b); // Neither function c, nor b is included in the stack trace
218  throw error;
219}
220
221a();
222```
223
224### `Error.stackTraceLimit`
225
226* {number}
227
228The `Error.stackTraceLimit` property specifies the number of stack frames
229collected by a stack trace (whether generated by `new Error().stack` or
230`Error.captureStackTrace(obj)`).
231
232The default value is `10` but may be set to any valid JavaScript number. Changes
233will affect any stack trace captured _after_ the value has been changed.
234
235If set to a non-number value, or set to a negative number, stack traces will
236not capture any frames.
237
238### `error.cause`
239
240<!-- YAML
241added: v16.9.0
242-->
243
244* {any}
245
246If present, the `error.cause` property is the underlying cause of the `Error`.
247It is used when catching an error and throwing a new one with a different
248message or code in order to still have access to the original error.
249
250The `error.cause` property is typically set by calling
251`new Error(message, { cause })`. It is not set by the constructor if the
252`cause` option is not provided.
253
254This property allows errors to be chained. When serializing `Error` objects,
255[`util.inspect()`][] recursively serializes `error.cause` if it is set.
256
257```js
258const cause = new Error('The remote HTTP server responded with a 500 status');
259const symptom = new Error('The message failed to send', { cause });
260
261console.log(symptom);
262// Prints:
263//   Error: The message failed to send
264//       at REPL2:1:17
265//       at Script.runInThisContext (node:vm:130:12)
266//       ... 7 lines matching cause stack trace ...
267//       at [_line] [as _line] (node:internal/readline/interface:886:18) {
268//     [cause]: Error: The remote HTTP server responded with a 500 status
269//         at REPL1:1:15
270//         at Script.runInThisContext (node:vm:130:12)
271//         at REPLServer.defaultEval (node:repl:574:29)
272//         at bound (node:domain:426:15)
273//         at REPLServer.runBound [as eval] (node:domain:437:12)
274//         at REPLServer.onLine (node:repl:902:10)
275//         at REPLServer.emit (node:events:549:35)
276//         at REPLServer.emit (node:domain:482:12)
277//         at [_onLine] [as _onLine] (node:internal/readline/interface:425:12)
278//         at [_line] [as _line] (node:internal/readline/interface:886:18)
279```
280
281### `error.code`
282
283* {string}
284
285The `error.code` property is a string label that identifies the kind of error.
286`error.code` is the most stable way to identify an error. It will only change
287between major versions of Node.js. In contrast, `error.message` strings may
288change between any versions of Node.js. See [Node.js error codes][] for details
289about specific codes.
290
291### `error.message`
292
293* {string}
294
295The `error.message` property is the string description of the error as set by
296calling `new Error(message)`. The `message` passed to the constructor will also
297appear in the first line of the stack trace of the `Error`, however changing
298this property after the `Error` object is created _may not_ change the first
299line of the stack trace (for example, when `error.stack` is read before this
300property is changed).
301
302```js
303const err = new Error('The message');
304console.error(err.message);
305// Prints: The message
306```
307
308### `error.stack`
309
310* {string}
311
312The `error.stack` property is a string describing the point in the code at which
313the `Error` was instantiated.
314
315```console
316Error: Things keep happening!
317   at /home/gbusey/file.js:525:2
318   at Frobnicator.refrobulate (/home/gbusey/business-logic.js:424:21)
319   at Actor.<anonymous> (/home/gbusey/actors.js:400:8)
320   at increaseSynergy (/home/gbusey/actors.js:701:6)
321```
322
323The first line is formatted as `<error class name>: <error message>`, and
324is followed by a series of stack frames (each line beginning with "at ").
325Each frame describes a call site within the code that lead to the error being
326generated. V8 attempts to display a name for each function (by variable name,
327function name, or object method name), but occasionally it will not be able to
328find a suitable name. If V8 cannot determine a name for the function, only
329location information will be displayed for that frame. Otherwise, the
330determined function name will be displayed with location information appended
331in parentheses.
332
333Frames are only generated for JavaScript functions. If, for example, execution
334synchronously passes through a C++ addon function called `cheetahify` which
335itself calls a JavaScript function, the frame representing the `cheetahify` call
336will not be present in the stack traces:
337
338```js
339const cheetahify = require('./native-binding.node');
340
341function makeFaster() {
342  // `cheetahify()` *synchronously* calls speedy.
343  cheetahify(function speedy() {
344    throw new Error('oh no!');
345  });
346}
347
348makeFaster();
349// will throw:
350//   /home/gbusey/file.js:6
351//       throw new Error('oh no!');
352//           ^
353//   Error: oh no!
354//       at speedy (/home/gbusey/file.js:6:11)
355//       at makeFaster (/home/gbusey/file.js:5:3)
356//       at Object.<anonymous> (/home/gbusey/file.js:10:1)
357//       at Module._compile (module.js:456:26)
358//       at Object.Module._extensions..js (module.js:474:10)
359//       at Module.load (module.js:356:32)
360//       at Function.Module._load (module.js:312:12)
361//       at Function.Module.runMain (module.js:497:10)
362//       at startup (node.js:119:16)
363//       at node.js:906:3
364```
365
366The location information will be one of:
367
368* `native`, if the frame represents a call internal to V8 (as in `[].forEach`).
369* `plain-filename.js:line:column`, if the frame represents a call internal
370  to Node.js.
371* `/absolute/path/to/file.js:line:column`, if the frame represents a call in
372  a user program (using CommonJS module system), or its dependencies.
373* `<transport-protocol>:///url/to/module/file.mjs:line:column`, if the frame
374  represents a call in a user program (using ES module system), or
375  its dependencies.
376
377The string representing the stack trace is lazily generated when the
378`error.stack` property is **accessed**.
379
380The number of frames captured by the stack trace is bounded by the smaller of
381`Error.stackTraceLimit` or the number of available frames on the current event
382loop tick.
383
384## Class: `AssertionError`
385
386* Extends: {errors.Error}
387
388Indicates the failure of an assertion. For details, see
389[`Class: assert.AssertionError`][].
390
391## Class: `RangeError`
392
393* Extends: {errors.Error}
394
395Indicates that a provided argument was not within the set or range of
396acceptable values for a function; whether that is a numeric range, or
397outside the set of options for a given function parameter.
398
399```js
400require('node:net').connect(-1);
401// Throws "RangeError: "port" option should be >= 0 and < 65536: -1"
402```
403
404Node.js will generate and throw `RangeError` instances _immediately_ as a form
405of argument validation.
406
407## Class: `ReferenceError`
408
409* Extends: {errors.Error}
410
411Indicates that an attempt is being made to access a variable that is not
412defined. Such errors commonly indicate typos in code, or an otherwise broken
413program.
414
415While client code may generate and propagate these errors, in practice, only V8
416will do so.
417
418```js
419doesNotExist;
420// Throws ReferenceError, doesNotExist is not a variable in this program.
421```
422
423Unless an application is dynamically generating and running code,
424`ReferenceError` instances indicate a bug in the code or its dependencies.
425
426## Class: `SyntaxError`
427
428* Extends: {errors.Error}
429
430Indicates that a program is not valid JavaScript. These errors may only be
431generated and propagated as a result of code evaluation. Code evaluation may
432happen as a result of `eval`, `Function`, `require`, or [vm][]. These errors
433are almost always indicative of a broken program.
434
435```js
436try {
437  require('node:vm').runInThisContext('binary ! isNotOk');
438} catch (err) {
439  // 'err' will be a SyntaxError.
440}
441```
442
443`SyntaxError` instances are unrecoverable in the context that created them –
444they may only be caught by other contexts.
445
446## Class: `SystemError`
447
448* Extends: {errors.Error}
449
450Node.js generates system errors when exceptions occur within its runtime
451environment. These usually occur when an application violates an operating
452system constraint. For example, a system error will occur if an application
453attempts to read a file that does not exist.
454
455* `address` {string} If present, the address to which a network connection
456  failed
457* `code` {string} The string error code
458* `dest` {string} If present, the file path destination when reporting a file
459  system error
460* `errno` {number} The system-provided error number
461* `info` {Object} If present, extra details about the error condition
462* `message` {string} A system-provided human-readable description of the error
463* `path` {string} If present, the file path when reporting a file system error
464* `port` {number} If present, the network connection port that is not available
465* `syscall` {string} The name of the system call that triggered the error
466
467### `error.address`
468
469* {string}
470
471If present, `error.address` is a string describing the address to which a
472network connection failed.
473
474### `error.code`
475
476* {string}
477
478The `error.code` property is a string representing the error code.
479
480### `error.dest`
481
482* {string}
483
484If present, `error.dest` is the file path destination when reporting a file
485system error.
486
487### `error.errno`
488
489* {number}
490
491The `error.errno` property is a negative number which corresponds
492to the error code defined in [`libuv Error handling`][].
493
494On Windows the error number provided by the system will be normalized by libuv.
495
496To get the string representation of the error code, use
497[`util.getSystemErrorName(error.errno)`][].
498
499### `error.info`
500
501* {Object}
502
503If present, `error.info` is an object with details about the error condition.
504
505### `error.message`
506
507* {string}
508
509`error.message` is a system-provided human-readable description of the error.
510
511### `error.path`
512
513* {string}
514
515If present, `error.path` is a string containing a relevant invalid pathname.
516
517### `error.port`
518
519* {number}
520
521If present, `error.port` is the network connection port that is not available.
522
523### `error.syscall`
524
525* {string}
526
527The `error.syscall` property is a string describing the [syscall][] that failed.
528
529### Common system errors
530
531This is a list of system errors commonly-encountered when writing a Node.js
532program. For a comprehensive list, see the [`errno`(3) man page][].
533
534* `EACCES` (Permission denied): An attempt was made to access a file in a way
535  forbidden by its file access permissions.
536
537* `EADDRINUSE` (Address already in use): An attempt to bind a server
538  ([`net`][], [`http`][], or [`https`][]) to a local address failed due to
539  another server on the local system already occupying that address.
540
541* `ECONNREFUSED` (Connection refused): No connection could be made because the
542  target machine actively refused it. This usually results from trying to
543  connect to a service that is inactive on the foreign host.
544
545* `ECONNRESET` (Connection reset by peer): A connection was forcibly closed by
546  a peer. This normally results from a loss of the connection on the remote
547  socket due to a timeout or reboot. Commonly encountered via the [`http`][]
548  and [`net`][] modules.
549
550* `EEXIST` (File exists): An existing file was the target of an operation that
551  required that the target not exist.
552
553* `EISDIR` (Is a directory): An operation expected a file, but the given
554  pathname was a directory.
555
556* `EMFILE` (Too many open files in system): Maximum number of
557  [file descriptors][] allowable on the system has been reached, and
558  requests for another descriptor cannot be fulfilled until at least one
559  has been closed. This is encountered when opening many files at once in
560  parallel, especially on systems (in particular, macOS) where there is a low
561  file descriptor limit for processes. To remedy a low limit, run
562  `ulimit -n 2048` in the same shell that will run the Node.js process.
563
564* `ENOENT` (No such file or directory): Commonly raised by [`fs`][] operations
565  to indicate that a component of the specified pathname does not exist. No
566  entity (file or directory) could be found by the given path.
567
568* `ENOTDIR` (Not a directory): A component of the given pathname existed, but
569  was not a directory as expected. Commonly raised by [`fs.readdir`][].
570
571* `ENOTEMPTY` (Directory not empty): A directory with entries was the target
572  of an operation that requires an empty directory, usually [`fs.unlink`][].
573
574* `ENOTFOUND` (DNS lookup failed): Indicates a DNS failure of either
575  `EAI_NODATA` or `EAI_NONAME`. This is not a standard POSIX error.
576
577* `EPERM` (Operation not permitted): An attempt was made to perform an
578  operation that requires elevated privileges.
579
580* `EPIPE` (Broken pipe): A write on a pipe, socket, or FIFO for which there is
581  no process to read the data. Commonly encountered at the [`net`][] and
582  [`http`][] layers, indicative that the remote side of the stream being
583  written to has been closed.
584
585* `ETIMEDOUT` (Operation timed out): A connect or send request failed because
586  the connected party did not properly respond after a period of time. Usually
587  encountered by [`http`][] or [`net`][]. Often a sign that a `socket.end()`
588  was not properly called.
589
590## Class: `TypeError`
591
592* Extends {errors.Error}
593
594Indicates that a provided argument is not an allowable type. For example,
595passing a function to a parameter which expects a string would be a `TypeError`.
596
597```js
598require('node:url').parse(() => { });
599// Throws TypeError, since it expected a string.
600```
601
602Node.js will generate and throw `TypeError` instances _immediately_ as a form
603of argument validation.
604
605## Exceptions vs. errors
606
607<!--type=misc-->
608
609A JavaScript exception is a value that is thrown as a result of an invalid
610operation or as the target of a `throw` statement. While it is not required
611that these values are instances of `Error` or classes which inherit from
612`Error`, all exceptions thrown by Node.js or the JavaScript runtime _will_ be
613instances of `Error`.
614
615Some exceptions are _unrecoverable_ at the JavaScript layer. Such exceptions
616will _always_ cause the Node.js process to crash. Examples include `assert()`
617checks or `abort()` calls in the C++ layer.
618
619## OpenSSL errors
620
621Errors originating in `crypto` or `tls` are of class `Error`, and in addition to
622the standard `.code` and `.message` properties, may have some additional
623OpenSSL-specific properties.
624
625### `error.opensslErrorStack`
626
627An array of errors that can give context to where in the OpenSSL library an
628error originates from.
629
630### `error.function`
631
632The OpenSSL function the error originates in.
633
634### `error.library`
635
636The OpenSSL library the error originates in.
637
638### `error.reason`
639
640A human-readable string describing the reason for the error.
641
642<a id="nodejs-error-codes"></a>
643
644## Node.js error codes
645
646<a id="ABORT_ERR"></a>
647
648### `ABORT_ERR`
649
650<!-- YAML
651added: v15.0.0
652-->
653
654Used when an operation has been aborted (typically using an `AbortController`).
655
656APIs _not_ using `AbortSignal`s typically do not raise an error with this code.
657
658This code does not use the regular `ERR_*` convention Node.js errors use in
659order to be compatible with the web platform's `AbortError`.
660
661<a id="ERR_ACCESS_DENIED"></a>
662
663### `ERR_ACCESS_DENIED`
664
665A special type of error that is triggered whenever Node.js tries to get access
666to a resource restricted by the [policy][] manifest.
667For example, `process.binding`.
668
669<a id="ERR_AMBIGUOUS_ARGUMENT"></a>
670
671### `ERR_AMBIGUOUS_ARGUMENT`
672
673A function argument is being used in a way that suggests that the function
674signature may be misunderstood. This is thrown by the `node:assert` module when
675the `message` parameter in `assert.throws(block, message)` matches the error
676message thrown by `block` because that usage suggests that the user believes
677`message` is the expected message rather than the message the `AssertionError`
678will display if `block` does not throw.
679
680<a id="ERR_ARG_NOT_ITERABLE"></a>
681
682### `ERR_ARG_NOT_ITERABLE`
683
684An iterable argument (i.e. a value that works with `for...of` loops) was
685required, but not provided to a Node.js API.
686
687<a id="ERR_ASSERTION"></a>
688
689### `ERR_ASSERTION`
690
691A special type of error that can be triggered whenever Node.js detects an
692exceptional logic violation that should never occur. These are raised typically
693by the `node:assert` module.
694
695<a id="ERR_ASYNC_CALLBACK"></a>
696
697### `ERR_ASYNC_CALLBACK`
698
699An attempt was made to register something that is not a function as an
700`AsyncHooks` callback.
701
702<a id="ERR_ASYNC_TYPE"></a>
703
704### `ERR_ASYNC_TYPE`
705
706The type of an asynchronous resource was invalid. Users are also able
707to define their own types if using the public embedder API.
708
709<a id="ERR_BROTLI_COMPRESSION_FAILED"></a>
710
711### `ERR_BROTLI_COMPRESSION_FAILED`
712
713Data passed to a Brotli stream was not successfully compressed.
714
715<a id="ERR_BROTLI_INVALID_PARAM"></a>
716
717### `ERR_BROTLI_INVALID_PARAM`
718
719An invalid parameter key was passed during construction of a Brotli stream.
720
721<a id="ERR_BUFFER_CONTEXT_NOT_AVAILABLE"></a>
722
723### `ERR_BUFFER_CONTEXT_NOT_AVAILABLE`
724
725An attempt was made to create a Node.js `Buffer` instance from addon or embedder
726code, while in a JS engine Context that is not associated with a Node.js
727instance. The data passed to the `Buffer` method will have been released
728by the time the method returns.
729
730When encountering this error, a possible alternative to creating a `Buffer`
731instance is to create a normal `Uint8Array`, which only differs in the
732prototype of the resulting object. `Uint8Array`s are generally accepted in all
733Node.js core APIs where `Buffer`s are; they are available in all Contexts.
734
735<a id="ERR_BUFFER_OUT_OF_BOUNDS"></a>
736
737### `ERR_BUFFER_OUT_OF_BOUNDS`
738
739An operation outside the bounds of a `Buffer` was attempted.
740
741<a id="ERR_BUFFER_TOO_LARGE"></a>
742
743### `ERR_BUFFER_TOO_LARGE`
744
745An attempt has been made to create a `Buffer` larger than the maximum allowed
746size.
747
748<a id="ERR_CANNOT_WATCH_SIGINT"></a>
749
750### `ERR_CANNOT_WATCH_SIGINT`
751
752Node.js was unable to watch for the `SIGINT` signal.
753
754<a id="ERR_CHILD_CLOSED_BEFORE_REPLY"></a>
755
756### `ERR_CHILD_CLOSED_BEFORE_REPLY`
757
758A child process was closed before the parent received a reply.
759
760<a id="ERR_CHILD_PROCESS_IPC_REQUIRED"></a>
761
762### `ERR_CHILD_PROCESS_IPC_REQUIRED`
763
764Used when a child process is being forked without specifying an IPC channel.
765
766<a id="ERR_CHILD_PROCESS_STDIO_MAXBUFFER"></a>
767
768### `ERR_CHILD_PROCESS_STDIO_MAXBUFFER`
769
770Used when the main process is trying to read data from the child process's
771STDERR/STDOUT, and the data's length is longer than the `maxBuffer` option.
772
773<a id="ERR_CLOSED_MESSAGE_PORT"></a>
774
775### `ERR_CLOSED_MESSAGE_PORT`
776
777<!--
778added:
779  - v16.2.0
780  - v14.17.1
781changes:
782  - version: 11.12.0
783    pr-url: https://github.com/nodejs/node/pull/26487
784    description: The error message was removed.
785  - version:
786      - v16.2.0
787      - v14.17.1
788    pr-url: https://github.com/nodejs/node/pull/38510
789    description: The error message was reintroduced.
790-->
791
792There was an attempt to use a `MessagePort` instance in a closed
793state, usually after `.close()` has been called.
794
795<a id="ERR_CONSOLE_WRITABLE_STREAM"></a>
796
797### `ERR_CONSOLE_WRITABLE_STREAM`
798
799`Console` was instantiated without `stdout` stream, or `Console` has a
800non-writable `stdout` or `stderr` stream.
801
802<a id="ERR_CONSTRUCT_CALL_INVALID"></a>
803
804### `ERR_CONSTRUCT_CALL_INVALID`
805
806<!--
807added: v12.5.0
808-->
809
810A class constructor was called that is not callable.
811
812<a id="ERR_CONSTRUCT_CALL_REQUIRED"></a>
813
814### `ERR_CONSTRUCT_CALL_REQUIRED`
815
816A constructor for a class was called without `new`.
817
818<a id="ERR_CONTEXT_NOT_INITIALIZED"></a>
819
820### `ERR_CONTEXT_NOT_INITIALIZED`
821
822The vm context passed into the API is not yet initialized. This could happen
823when an error occurs (and is caught) during the creation of the
824context, for example, when the allocation fails or the maximum call stack
825size is reached when the context is created.
826
827<a id="ERR_CRYPTO_CUSTOM_ENGINE_NOT_SUPPORTED"></a>
828
829### `ERR_CRYPTO_CUSTOM_ENGINE_NOT_SUPPORTED`
830
831An OpenSSL engine was requested (for example, through the `clientCertEngine` or
832`privateKeyEngine` TLS options) that is not supported by the version of OpenSSL
833being used, likely due to the compile-time flag `OPENSSL_NO_ENGINE`.
834
835<a id="ERR_CRYPTO_ECDH_INVALID_FORMAT"></a>
836
837### `ERR_CRYPTO_ECDH_INVALID_FORMAT`
838
839An invalid value for the `format` argument was passed to the `crypto.ECDH()`
840class `getPublicKey()` method.
841
842<a id="ERR_CRYPTO_ECDH_INVALID_PUBLIC_KEY"></a>
843
844### `ERR_CRYPTO_ECDH_INVALID_PUBLIC_KEY`
845
846An invalid value for the `key` argument has been passed to the
847`crypto.ECDH()` class `computeSecret()` method. It means that the public
848key lies outside of the elliptic curve.
849
850<a id="ERR_CRYPTO_ENGINE_UNKNOWN"></a>
851
852### `ERR_CRYPTO_ENGINE_UNKNOWN`
853
854An invalid crypto engine identifier was passed to
855[`require('node:crypto').setEngine()`][].
856
857<a id="ERR_CRYPTO_FIPS_FORCED"></a>
858
859### `ERR_CRYPTO_FIPS_FORCED`
860
861The [`--force-fips`][] command-line argument was used but there was an attempt
862to enable or disable FIPS mode in the `node:crypto` module.
863
864<a id="ERR_CRYPTO_FIPS_UNAVAILABLE"></a>
865
866### `ERR_CRYPTO_FIPS_UNAVAILABLE`
867
868An attempt was made to enable or disable FIPS mode, but FIPS mode was not
869available.
870
871<a id="ERR_CRYPTO_HASH_FINALIZED"></a>
872
873### `ERR_CRYPTO_HASH_FINALIZED`
874
875[`hash.digest()`][] was called multiple times. The `hash.digest()` method must
876be called no more than one time per instance of a `Hash` object.
877
878<a id="ERR_CRYPTO_HASH_UPDATE_FAILED"></a>
879
880### `ERR_CRYPTO_HASH_UPDATE_FAILED`
881
882[`hash.update()`][] failed for any reason. This should rarely, if ever, happen.
883
884<a id="ERR_CRYPTO_INCOMPATIBLE_KEY"></a>
885
886### `ERR_CRYPTO_INCOMPATIBLE_KEY`
887
888The given crypto keys are incompatible with the attempted operation.
889
890<a id="ERR_CRYPTO_INCOMPATIBLE_KEY_OPTIONS"></a>
891
892### `ERR_CRYPTO_INCOMPATIBLE_KEY_OPTIONS`
893
894The selected public or private key encoding is incompatible with other options.
895
896<a id="ERR_CRYPTO_INITIALIZATION_FAILED"></a>
897
898### `ERR_CRYPTO_INITIALIZATION_FAILED`
899
900<!-- YAML
901added: v15.0.0
902-->
903
904Initialization of the crypto subsystem failed.
905
906<a id="ERR_CRYPTO_INVALID_AUTH_TAG"></a>
907
908### `ERR_CRYPTO_INVALID_AUTH_TAG`
909
910<!-- YAML
911added: v15.0.0
912-->
913
914An invalid authentication tag was provided.
915
916<a id="ERR_CRYPTO_INVALID_COUNTER"></a>
917
918### `ERR_CRYPTO_INVALID_COUNTER`
919
920<!-- YAML
921added: v15.0.0
922-->
923
924An invalid counter was provided for a counter-mode cipher.
925
926<a id="ERR_CRYPTO_INVALID_CURVE"></a>
927
928### `ERR_CRYPTO_INVALID_CURVE`
929
930<!-- YAML
931added: v15.0.0
932-->
933
934An invalid elliptic-curve was provided.
935
936<a id="ERR_CRYPTO_INVALID_DIGEST"></a>
937
938### `ERR_CRYPTO_INVALID_DIGEST`
939
940An invalid [crypto digest algorithm][] was specified.
941
942<a id="ERR_CRYPTO_INVALID_IV"></a>
943
944### `ERR_CRYPTO_INVALID_IV`
945
946<!-- YAML
947added: v15.0.0
948-->
949
950An invalid initialization vector was provided.
951
952<a id="ERR_CRYPTO_INVALID_JWK"></a>
953
954### `ERR_CRYPTO_INVALID_JWK`
955
956<!-- YAML
957added: v15.0.0
958-->
959
960An invalid JSON Web Key was provided.
961
962<a id="ERR_CRYPTO_INVALID_KEY_OBJECT_TYPE"></a>
963
964### `ERR_CRYPTO_INVALID_KEY_OBJECT_TYPE`
965
966The given crypto key object's type is invalid for the attempted operation.
967
968<a id="ERR_CRYPTO_INVALID_KEYLEN"></a>
969
970### `ERR_CRYPTO_INVALID_KEYLEN`
971
972<!-- YAML
973added: v15.0.0
974-->
975
976An invalid key length was provided.
977
978<a id="ERR_CRYPTO_INVALID_KEYPAIR"></a>
979
980### `ERR_CRYPTO_INVALID_KEYPAIR`
981
982<!-- YAML
983added: v15.0.0
984-->
985
986An invalid key pair was provided.
987
988<a id="ERR_CRYPTO_INVALID_KEYTYPE"></a>
989
990### `ERR_CRYPTO_INVALID_KEYTYPE`
991
992<!-- YAML
993added: v15.0.0
994-->
995
996An invalid key type was provided.
997
998<a id="ERR_CRYPTO_INVALID_MESSAGELEN"></a>
999
1000### `ERR_CRYPTO_INVALID_MESSAGELEN`
1001
1002<!-- YAML
1003added: v15.0.0
1004-->
1005
1006An invalid message length was provided.
1007
1008<a id="ERR_CRYPTO_INVALID_SCRYPT_PARAMS"></a>
1009
1010### `ERR_CRYPTO_INVALID_SCRYPT_PARAMS`
1011
1012<!-- YAML
1013added: v15.0.0
1014-->
1015
1016Invalid scrypt algorithm parameters were provided.
1017
1018<a id="ERR_CRYPTO_INVALID_STATE"></a>
1019
1020### `ERR_CRYPTO_INVALID_STATE`
1021
1022A crypto method was used on an object that was in an invalid state. For
1023instance, calling [`cipher.getAuthTag()`][] before calling `cipher.final()`.
1024
1025<a id="ERR_CRYPTO_INVALID_TAG_LENGTH"></a>
1026
1027### `ERR_CRYPTO_INVALID_TAG_LENGTH`
1028
1029<!-- YAML
1030added: v15.0.0
1031-->
1032
1033An invalid authentication tag length was provided.
1034
1035<a id="ERR_CRYPTO_JOB_INIT_FAILED"></a>
1036
1037### `ERR_CRYPTO_JOB_INIT_FAILED`
1038
1039<!-- YAML
1040added: v15.0.0
1041-->
1042
1043Initialization of an asynchronous crypto operation failed.
1044
1045<a id="ERR_CRYPTO_JWK_UNSUPPORTED_CURVE"></a>
1046
1047### `ERR_CRYPTO_JWK_UNSUPPORTED_CURVE`
1048
1049Key's Elliptic Curve is not registered for use in the
1050[JSON Web Key Elliptic Curve Registry][].
1051
1052<a id="ERR_CRYPTO_JWK_UNSUPPORTED_KEY_TYPE"></a>
1053
1054### `ERR_CRYPTO_JWK_UNSUPPORTED_KEY_TYPE`
1055
1056Key's Asymmetric Key Type is not registered for use in the
1057[JSON Web Key Types Registry][].
1058
1059<a id="ERR_CRYPTO_OPERATION_FAILED"></a>
1060
1061### `ERR_CRYPTO_OPERATION_FAILED`
1062
1063<!-- YAML
1064added: v15.0.0
1065-->
1066
1067A crypto operation failed for an otherwise unspecified reason.
1068
1069<a id="ERR_CRYPTO_PBKDF2_ERROR"></a>
1070
1071### `ERR_CRYPTO_PBKDF2_ERROR`
1072
1073The PBKDF2 algorithm failed for unspecified reasons. OpenSSL does not provide
1074more details and therefore neither does Node.js.
1075
1076<a id="ERR_CRYPTO_SCRYPT_INVALID_PARAMETER"></a>
1077
1078### `ERR_CRYPTO_SCRYPT_INVALID_PARAMETER`
1079
1080One or more [`crypto.scrypt()`][] or [`crypto.scryptSync()`][] parameters are
1081outside their legal range.
1082
1083<a id="ERR_CRYPTO_SCRYPT_NOT_SUPPORTED"></a>
1084
1085### `ERR_CRYPTO_SCRYPT_NOT_SUPPORTED`
1086
1087Node.js was compiled without `scrypt` support. Not possible with the official
1088release binaries but can happen with custom builds, including distro builds.
1089
1090<a id="ERR_CRYPTO_SIGN_KEY_REQUIRED"></a>
1091
1092### `ERR_CRYPTO_SIGN_KEY_REQUIRED`
1093
1094A signing `key` was not provided to the [`sign.sign()`][] method.
1095
1096<a id="ERR_CRYPTO_TIMING_SAFE_EQUAL_LENGTH"></a>
1097
1098### `ERR_CRYPTO_TIMING_SAFE_EQUAL_LENGTH`
1099
1100[`crypto.timingSafeEqual()`][] was called with `Buffer`, `TypedArray`, or
1101`DataView` arguments of different lengths.
1102
1103<a id="ERR_CRYPTO_UNKNOWN_CIPHER"></a>
1104
1105### `ERR_CRYPTO_UNKNOWN_CIPHER`
1106
1107An unknown cipher was specified.
1108
1109<a id="ERR_CRYPTO_UNKNOWN_DH_GROUP"></a>
1110
1111### `ERR_CRYPTO_UNKNOWN_DH_GROUP`
1112
1113An unknown Diffie-Hellman group name was given. See
1114[`crypto.getDiffieHellman()`][] for a list of valid group names.
1115
1116<a id="ERR_CRYPTO_UNSUPPORTED_OPERATION"></a>
1117
1118### `ERR_CRYPTO_UNSUPPORTED_OPERATION`
1119
1120<!-- YAML
1121added:
1122  - v15.0.0
1123  - v14.18.0
1124-->
1125
1126An attempt to invoke an unsupported crypto operation was made.
1127
1128<a id="ERR_DEBUGGER_ERROR"></a>
1129
1130### `ERR_DEBUGGER_ERROR`
1131
1132<!-- YAML
1133added:
1134  - v16.4.0
1135  - v14.17.4
1136-->
1137
1138An error occurred with the [debugger][].
1139
1140<a id="ERR_DEBUGGER_STARTUP_ERROR"></a>
1141
1142### `ERR_DEBUGGER_STARTUP_ERROR`
1143
1144<!-- YAML
1145added:
1146  - v16.4.0
1147  - v14.17.4
1148-->
1149
1150The [debugger][] timed out waiting for the required host/port to be free.
1151
1152<a id="ERR_DLOPEN_DISABLED"></a>
1153
1154### `ERR_DLOPEN_DISABLED`
1155
1156<!-- YAML
1157added:
1158  - v16.10.0
1159  - v14.19.0
1160-->
1161
1162Loading native addons has been disabled using [`--no-addons`][].
1163
1164<a id="ERR_DLOPEN_FAILED"></a>
1165
1166### `ERR_DLOPEN_FAILED`
1167
1168<!-- YAML
1169added: v15.0.0
1170-->
1171
1172A call to `process.dlopen()` failed.
1173
1174<a id="ERR_DIR_CLOSED"></a>
1175
1176### `ERR_DIR_CLOSED`
1177
1178The [`fs.Dir`][] was previously closed.
1179
1180<a id="ERR_DIR_CONCURRENT_OPERATION"></a>
1181
1182### `ERR_DIR_CONCURRENT_OPERATION`
1183
1184<!-- YAML
1185added: v14.3.0
1186-->
1187
1188A synchronous read or close call was attempted on an [`fs.Dir`][] which has
1189ongoing asynchronous operations.
1190
1191<a id="ERR_DNS_SET_SERVERS_FAILED"></a>
1192
1193### `ERR_DNS_SET_SERVERS_FAILED`
1194
1195`c-ares` failed to set the DNS server.
1196
1197<a id="ERR_DOMAIN_CALLBACK_NOT_AVAILABLE"></a>
1198
1199### `ERR_DOMAIN_CALLBACK_NOT_AVAILABLE`
1200
1201The `node:domain` module was not usable since it could not establish the
1202required error handling hooks, because
1203[`process.setUncaughtExceptionCaptureCallback()`][] had been called at an
1204earlier point in time.
1205
1206<a id="ERR_DOMAIN_CANNOT_SET_UNCAUGHT_EXCEPTION_CAPTURE"></a>
1207
1208### `ERR_DOMAIN_CANNOT_SET_UNCAUGHT_EXCEPTION_CAPTURE`
1209
1210[`process.setUncaughtExceptionCaptureCallback()`][] could not be called
1211because the `node:domain` module has been loaded at an earlier point in time.
1212
1213The stack trace is extended to include the point in time at which the
1214`node:domain` module had been loaded.
1215
1216<a id="ERR_DUPLICATE_STARTUP_SNAPSHOT_MAIN_FUNCTION"></a>
1217
1218### `ERR_DUPLICATE_STARTUP_SNAPSHOT_MAIN_FUNCTION`
1219
1220[`v8.startupSnapshot.setDeserializeMainFunction()`][] could not be called
1221because it had already been called before.
1222
1223<a id="ERR_ENCODING_INVALID_ENCODED_DATA"></a>
1224
1225### `ERR_ENCODING_INVALID_ENCODED_DATA`
1226
1227Data provided to `TextDecoder()` API was invalid according to the encoding
1228provided.
1229
1230<a id="ERR_ENCODING_NOT_SUPPORTED"></a>
1231
1232### `ERR_ENCODING_NOT_SUPPORTED`
1233
1234Encoding provided to `TextDecoder()` API was not one of the
1235[WHATWG Supported Encodings][].
1236
1237<a id="ERR_EVAL_ESM_CANNOT_PRINT"></a>
1238
1239### `ERR_EVAL_ESM_CANNOT_PRINT`
1240
1241`--print` cannot be used with ESM input.
1242
1243<a id="ERR_EVENT_RECURSION"></a>
1244
1245### `ERR_EVENT_RECURSION`
1246
1247Thrown when an attempt is made to recursively dispatch an event on `EventTarget`.
1248
1249<a id="ERR_EXECUTION_ENVIRONMENT_NOT_AVAILABLE"></a>
1250
1251### `ERR_EXECUTION_ENVIRONMENT_NOT_AVAILABLE`
1252
1253The JS execution context is not associated with a Node.js environment.
1254This may occur when Node.js is used as an embedded library and some hooks
1255for the JS engine are not set up properly.
1256
1257<a id="ERR_FALSY_VALUE_REJECTION"></a>
1258
1259### `ERR_FALSY_VALUE_REJECTION`
1260
1261A `Promise` that was callbackified via `util.callbackify()` was rejected with a
1262falsy value.
1263
1264<a id="ERR_FEATURE_UNAVAILABLE_ON_PLATFORM"></a>
1265
1266### `ERR_FEATURE_UNAVAILABLE_ON_PLATFORM`
1267
1268<!-- YAML
1269added: v14.0.0
1270-->
1271
1272Used when a feature that is not available
1273to the current platform which is running Node.js is used.
1274
1275<a id="ERR_FS_CP_DIR_TO_NON_DIR"></a>
1276
1277### `ERR_FS_CP_DIR_TO_NON_DIR`
1278
1279<!--
1280added: v16.7.0
1281-->
1282
1283An attempt was made to copy a directory to a non-directory (file, symlink,
1284etc.) using [`fs.cp()`][].
1285
1286<a id="ERR_FS_CP_EEXIST"></a>
1287
1288### `ERR_FS_CP_EEXIST`
1289
1290<!--
1291added: v16.7.0
1292-->
1293
1294An attempt was made to copy over a file that already existed with
1295[`fs.cp()`][], with the `force` and `errorOnExist` set to `true`.
1296
1297<a id="ERR_FS_CP_EINVAL"></a>
1298
1299### `ERR_FS_CP_EINVAL`
1300
1301<!--
1302added: v16.7.0
1303-->
1304
1305When using [`fs.cp()`][], `src` or `dest` pointed to an invalid path.
1306
1307<a id="ERR_FS_CP_FIFO_PIPE"></a>
1308
1309### `ERR_HTTP_BODY_NOT_ALLOWED`
1310
1311An error is thrown when writing to an HTTP response which does not allow
1312contents. <a id="ERR_HTTP_BODY_NOT_ALLOWED"></a>
1313
1314### `ERR_HTTP_CONTENT_LENGTH_MISMATCH`
1315
1316Response body size doesn't match with the specified content-length header value.
1317
1318<a id="ERR_HTTP_CONTENT_LENGTH_MISMATCH"></a>
1319
1320### `ERR_FS_CP_FIFO_PIPE`
1321
1322<!--
1323added: v16.7.0
1324-->
1325
1326An attempt was made to copy a named pipe with [`fs.cp()`][].
1327
1328<a id="ERR_FS_CP_NON_DIR_TO_DIR"></a>
1329
1330### `ERR_FS_CP_NON_DIR_TO_DIR`
1331
1332<!--
1333added: v16.7.0
1334-->
1335
1336An attempt was made to copy a non-directory (file, symlink, etc.) to a directory
1337using [`fs.cp()`][].
1338
1339<a id="ERR_FS_CP_SOCKET"></a>
1340
1341### `ERR_FS_CP_SOCKET`
1342
1343<!--
1344added: v16.7.0
1345-->
1346
1347An attempt was made to copy to a socket with [`fs.cp()`][].
1348
1349<a id="ERR_FS_CP_SYMLINK_TO_SUBDIRECTORY"></a>
1350
1351### `ERR_FS_CP_SYMLINK_TO_SUBDIRECTORY`
1352
1353<!--
1354added: v16.7.0
1355-->
1356
1357When using [`fs.cp()`][], a symlink in `dest` pointed to a subdirectory
1358of `src`.
1359
1360<a id="ERR_FS_CP_UNKNOWN"></a>
1361
1362### `ERR_FS_CP_UNKNOWN`
1363
1364<!--
1365added: v16.7.0
1366-->
1367
1368An attempt was made to copy to an unknown file type with [`fs.cp()`][].
1369
1370<a id="ERR_FS_EISDIR"></a>
1371
1372### `ERR_FS_EISDIR`
1373
1374Path is a directory.
1375
1376<a id="ERR_FS_FILE_TOO_LARGE"></a>
1377
1378### `ERR_FS_FILE_TOO_LARGE`
1379
1380An attempt has been made to read a file whose size is larger than the maximum
1381allowed size for a `Buffer`.
1382
1383<a id="ERR_FS_INVALID_SYMLINK_TYPE"></a>
1384
1385### `ERR_FS_INVALID_SYMLINK_TYPE`
1386
1387An invalid symlink type was passed to the [`fs.symlink()`][] or
1388[`fs.symlinkSync()`][] methods.
1389
1390<a id="ERR_HTTP_HEADERS_SENT"></a>
1391
1392### `ERR_HTTP_HEADERS_SENT`
1393
1394An attempt was made to add more headers after the headers had already been sent.
1395
1396<a id="ERR_HTTP_INVALID_HEADER_VALUE"></a>
1397
1398### `ERR_HTTP_INVALID_HEADER_VALUE`
1399
1400An invalid HTTP header value was specified.
1401
1402<a id="ERR_HTTP_INVALID_STATUS_CODE"></a>
1403
1404### `ERR_HTTP_INVALID_STATUS_CODE`
1405
1406Status code was outside the regular status code range (100-999).
1407
1408<a id="ERR_HTTP_REQUEST_TIMEOUT"></a>
1409
1410### `ERR_HTTP_REQUEST_TIMEOUT`
1411
1412The client has not sent the entire request within the allowed time.
1413
1414<a id="ERR_HTTP_SOCKET_ASSIGNED"></a>
1415
1416### `ERR_HTTP_SOCKET_ASSIGNED`
1417
1418The given [`ServerResponse`][] was already assigned a socket.
1419
1420<a id="ERR_HTTP_SOCKET_ENCODING"></a>
1421
1422### `ERR_HTTP_SOCKET_ENCODING`
1423
1424Changing the socket encoding is not allowed per [RFC 7230 Section 3][].
1425
1426<a id="ERR_HTTP_TRAILER_INVALID"></a>
1427
1428### `ERR_HTTP_TRAILER_INVALID`
1429
1430The `Trailer` header was set even though the transfer encoding does not support
1431that.
1432
1433<a id="ERR_HTTP2_ALTSVC_INVALID_ORIGIN"></a>
1434
1435### `ERR_HTTP2_ALTSVC_INVALID_ORIGIN`
1436
1437HTTP/2 ALTSVC frames require a valid origin.
1438
1439<a id="ERR_HTTP2_ALTSVC_LENGTH"></a>
1440
1441### `ERR_HTTP2_ALTSVC_LENGTH`
1442
1443HTTP/2 ALTSVC frames are limited to a maximum of 16,382 payload bytes.
1444
1445<a id="ERR_HTTP2_CONNECT_AUTHORITY"></a>
1446
1447### `ERR_HTTP2_CONNECT_AUTHORITY`
1448
1449For HTTP/2 requests using the `CONNECT` method, the `:authority` pseudo-header
1450is required.
1451
1452<a id="ERR_HTTP2_CONNECT_PATH"></a>
1453
1454### `ERR_HTTP2_CONNECT_PATH`
1455
1456For HTTP/2 requests using the `CONNECT` method, the `:path` pseudo-header is
1457forbidden.
1458
1459<a id="ERR_HTTP2_CONNECT_SCHEME"></a>
1460
1461### `ERR_HTTP2_CONNECT_SCHEME`
1462
1463For HTTP/2 requests using the `CONNECT` method, the `:scheme` pseudo-header is
1464forbidden.
1465
1466<a id="ERR_HTTP2_ERROR"></a>
1467
1468### `ERR_HTTP2_ERROR`
1469
1470A non-specific HTTP/2 error has occurred.
1471
1472<a id="ERR_HTTP2_GOAWAY_SESSION"></a>
1473
1474### `ERR_HTTP2_GOAWAY_SESSION`
1475
1476New HTTP/2 Streams may not be opened after the `Http2Session` has received a
1477`GOAWAY` frame from the connected peer.
1478
1479<a id="ERR_HTTP2_HEADER_SINGLE_VALUE"></a>
1480
1481### `ERR_HTTP2_HEADER_SINGLE_VALUE`
1482
1483Multiple values were provided for an HTTP/2 header field that was required to
1484have only a single value.
1485
1486<a id="ERR_HTTP2_HEADERS_AFTER_RESPOND"></a>
1487
1488### `ERR_HTTP2_HEADERS_AFTER_RESPOND`
1489
1490An additional headers was specified after an HTTP/2 response was initiated.
1491
1492<a id="ERR_HTTP2_HEADERS_SENT"></a>
1493
1494### `ERR_HTTP2_HEADERS_SENT`
1495
1496An attempt was made to send multiple response headers.
1497
1498<a id="ERR_HTTP2_INFO_STATUS_NOT_ALLOWED"></a>
1499
1500### `ERR_HTTP2_INFO_STATUS_NOT_ALLOWED`
1501
1502Informational HTTP status codes (`1xx`) may not be set as the response status
1503code on HTTP/2 responses.
1504
1505<a id="ERR_HTTP2_INVALID_CONNECTION_HEADERS"></a>
1506
1507### `ERR_HTTP2_INVALID_CONNECTION_HEADERS`
1508
1509HTTP/1 connection specific headers are forbidden to be used in HTTP/2
1510requests and responses.
1511
1512<a id="ERR_HTTP2_INVALID_HEADER_VALUE"></a>
1513
1514### `ERR_HTTP2_INVALID_HEADER_VALUE`
1515
1516An invalid HTTP/2 header value was specified.
1517
1518<a id="ERR_HTTP2_INVALID_INFO_STATUS"></a>
1519
1520### `ERR_HTTP2_INVALID_INFO_STATUS`
1521
1522An invalid HTTP informational status code has been specified. Informational
1523status codes must be an integer between `100` and `199` (inclusive).
1524
1525<a id="ERR_HTTP2_INVALID_ORIGIN"></a>
1526
1527### `ERR_HTTP2_INVALID_ORIGIN`
1528
1529HTTP/2 `ORIGIN` frames require a valid origin.
1530
1531<a id="ERR_HTTP2_INVALID_PACKED_SETTINGS_LENGTH"></a>
1532
1533### `ERR_HTTP2_INVALID_PACKED_SETTINGS_LENGTH`
1534
1535Input `Buffer` and `Uint8Array` instances passed to the
1536`http2.getUnpackedSettings()` API must have a length that is a multiple of
1537six.
1538
1539<a id="ERR_HTTP2_INVALID_PSEUDOHEADER"></a>
1540
1541### `ERR_HTTP2_INVALID_PSEUDOHEADER`
1542
1543Only valid HTTP/2 pseudoheaders (`:status`, `:path`, `:authority`, `:scheme`,
1544and `:method`) may be used.
1545
1546<a id="ERR_HTTP2_INVALID_SESSION"></a>
1547
1548### `ERR_HTTP2_INVALID_SESSION`
1549
1550An action was performed on an `Http2Session` object that had already been
1551destroyed.
1552
1553<a id="ERR_HTTP2_INVALID_SETTING_VALUE"></a>
1554
1555### `ERR_HTTP2_INVALID_SETTING_VALUE`
1556
1557An invalid value has been specified for an HTTP/2 setting.
1558
1559<a id="ERR_HTTP2_INVALID_STREAM"></a>
1560
1561### `ERR_HTTP2_INVALID_STREAM`
1562
1563An operation was performed on a stream that had already been destroyed.
1564
1565<a id="ERR_HTTP2_MAX_PENDING_SETTINGS_ACK"></a>
1566
1567### `ERR_HTTP2_MAX_PENDING_SETTINGS_ACK`
1568
1569Whenever an HTTP/2 `SETTINGS` frame is sent to a connected peer, the peer is
1570required to send an acknowledgment that it has received and applied the new
1571`SETTINGS`. By default, a maximum number of unacknowledged `SETTINGS` frames may
1572be sent at any given time. This error code is used when that limit has been
1573reached.
1574
1575<a id="ERR_HTTP2_NESTED_PUSH"></a>
1576
1577### `ERR_HTTP2_NESTED_PUSH`
1578
1579An attempt was made to initiate a new push stream from within a push stream.
1580Nested push streams are not permitted.
1581
1582<a id="ERR_HTTP2_NO_MEM"></a>
1583
1584### `ERR_HTTP2_NO_MEM`
1585
1586Out of memory when using the `http2session.setLocalWindowSize(windowSize)` API.
1587
1588<a id="ERR_HTTP2_NO_SOCKET_MANIPULATION"></a>
1589
1590### `ERR_HTTP2_NO_SOCKET_MANIPULATION`
1591
1592An attempt was made to directly manipulate (read, write, pause, resume, etc.) a
1593socket attached to an `Http2Session`.
1594
1595<a id="ERR_HTTP2_ORIGIN_LENGTH"></a>
1596
1597### `ERR_HTTP2_ORIGIN_LENGTH`
1598
1599HTTP/2 `ORIGIN` frames are limited to a length of 16382 bytes.
1600
1601<a id="ERR_HTTP2_OUT_OF_STREAMS"></a>
1602
1603### `ERR_HTTP2_OUT_OF_STREAMS`
1604
1605The number of streams created on a single HTTP/2 session reached the maximum
1606limit.
1607
1608<a id="ERR_HTTP2_PAYLOAD_FORBIDDEN"></a>
1609
1610### `ERR_HTTP2_PAYLOAD_FORBIDDEN`
1611
1612A message payload was specified for an HTTP response code for which a payload is
1613forbidden.
1614
1615<a id="ERR_HTTP2_PING_CANCEL"></a>
1616
1617### `ERR_HTTP2_PING_CANCEL`
1618
1619An HTTP/2 ping was canceled.
1620
1621<a id="ERR_HTTP2_PING_LENGTH"></a>
1622
1623### `ERR_HTTP2_PING_LENGTH`
1624
1625HTTP/2 ping payloads must be exactly 8 bytes in length.
1626
1627<a id="ERR_HTTP2_PSEUDOHEADER_NOT_ALLOWED"></a>
1628
1629### `ERR_HTTP2_PSEUDOHEADER_NOT_ALLOWED`
1630
1631An HTTP/2 pseudo-header has been used inappropriately. Pseudo-headers are header
1632key names that begin with the `:` prefix.
1633
1634<a id="ERR_HTTP2_PUSH_DISABLED"></a>
1635
1636### `ERR_HTTP2_PUSH_DISABLED`
1637
1638An attempt was made to create a push stream, which had been disabled by the
1639client.
1640
1641<a id="ERR_HTTP2_SEND_FILE"></a>
1642
1643### `ERR_HTTP2_SEND_FILE`
1644
1645An attempt was made to use the `Http2Stream.prototype.responseWithFile()` API to
1646send a directory.
1647
1648<a id="ERR_HTTP2_SEND_FILE_NOSEEK"></a>
1649
1650### `ERR_HTTP2_SEND_FILE_NOSEEK`
1651
1652An attempt was made to use the `Http2Stream.prototype.responseWithFile()` API to
1653send something other than a regular file, but `offset` or `length` options were
1654provided.
1655
1656<a id="ERR_HTTP2_SESSION_ERROR"></a>
1657
1658### `ERR_HTTP2_SESSION_ERROR`
1659
1660The `Http2Session` closed with a non-zero error code.
1661
1662<a id="ERR_HTTP2_SETTINGS_CANCEL"></a>
1663
1664### `ERR_HTTP2_SETTINGS_CANCEL`
1665
1666The `Http2Session` settings canceled.
1667
1668<a id="ERR_HTTP2_SOCKET_BOUND"></a>
1669
1670### `ERR_HTTP2_SOCKET_BOUND`
1671
1672An attempt was made to connect a `Http2Session` object to a `net.Socket` or
1673`tls.TLSSocket` that had already been bound to another `Http2Session` object.
1674
1675<a id="ERR_HTTP2_SOCKET_UNBOUND"></a>
1676
1677### `ERR_HTTP2_SOCKET_UNBOUND`
1678
1679An attempt was made to use the `socket` property of an `Http2Session` that
1680has already been closed.
1681
1682<a id="ERR_HTTP2_STATUS_101"></a>
1683
1684### `ERR_HTTP2_STATUS_101`
1685
1686Use of the `101` Informational status code is forbidden in HTTP/2.
1687
1688<a id="ERR_HTTP2_STATUS_INVALID"></a>
1689
1690### `ERR_HTTP2_STATUS_INVALID`
1691
1692An invalid HTTP status code has been specified. Status codes must be an integer
1693between `100` and `599` (inclusive).
1694
1695<a id="ERR_HTTP2_STREAM_CANCEL"></a>
1696
1697### `ERR_HTTP2_STREAM_CANCEL`
1698
1699An `Http2Stream` was destroyed before any data was transmitted to the connected
1700peer.
1701
1702<a id="ERR_HTTP2_STREAM_ERROR"></a>
1703
1704### `ERR_HTTP2_STREAM_ERROR`
1705
1706A non-zero error code was been specified in an `RST_STREAM` frame.
1707
1708<a id="ERR_HTTP2_STREAM_SELF_DEPENDENCY"></a>
1709
1710### `ERR_HTTP2_STREAM_SELF_DEPENDENCY`
1711
1712When setting the priority for an HTTP/2 stream, the stream may be marked as
1713a dependency for a parent stream. This error code is used when an attempt is
1714made to mark a stream and dependent of itself.
1715
1716<a id="ERR_HTTP2_TOO_MANY_INVALID_FRAMES"></a>
1717
1718### `ERR_HTTP2_TOO_MANY_INVALID_FRAMES`
1719
1720<!--
1721added: v15.14.0
1722-->
1723
1724The limit of acceptable invalid HTTP/2 protocol frames sent by the peer,
1725as specified through the `maxSessionInvalidFrames` option, has been exceeded.
1726
1727<a id="ERR_HTTP2_TRAILERS_ALREADY_SENT"></a>
1728
1729### `ERR_HTTP2_TRAILERS_ALREADY_SENT`
1730
1731Trailing headers have already been sent on the `Http2Stream`.
1732
1733<a id="ERR_HTTP2_TRAILERS_NOT_READY"></a>
1734
1735### `ERR_HTTP2_TRAILERS_NOT_READY`
1736
1737The `http2stream.sendTrailers()` method cannot be called until after the
1738`'wantTrailers'` event is emitted on an `Http2Stream` object. The
1739`'wantTrailers'` event will only be emitted if the `waitForTrailers` option
1740is set for the `Http2Stream`.
1741
1742<a id="ERR_HTTP2_UNSUPPORTED_PROTOCOL"></a>
1743
1744### `ERR_HTTP2_UNSUPPORTED_PROTOCOL`
1745
1746`http2.connect()` was passed a URL that uses any protocol other than `http:` or
1747`https:`.
1748
1749<a id="ERR_ILLEGAL_CONSTRUCTOR"></a>
1750
1751### `ERR_ILLEGAL_CONSTRUCTOR`
1752
1753An attempt was made to construct an object using a non-public constructor.
1754
1755<a id="ERR_IMPORT_ASSERTION_TYPE_FAILED"></a>
1756
1757### `ERR_IMPORT_ASSERTION_TYPE_FAILED`
1758
1759<!-- YAML
1760added:
1761  - v17.1.0
1762  - v16.14.0
1763-->
1764
1765An import `type` attribute was provided, but the specified module is of a
1766different type.
1767
1768<a id="ERR_IMPORT_ASSERTION_TYPE_MISSING"></a>
1769
1770### `ERR_IMPORT_ASSERTION_TYPE_MISSING`
1771
1772<!-- YAML
1773added:
1774  - v17.1.0
1775  - v16.14.0
1776-->
1777
1778An import attribute is missing, preventing the specified module to be imported.
1779
1780<a id="ERR_IMPORT_ASSERTION_TYPE_UNSUPPORTED"></a>
1781
1782### `ERR_IMPORT_ASSERTION_TYPE_UNSUPPORTED`
1783
1784<!-- YAML
1785added:
1786  - v17.1.0
1787  - v16.14.0
1788-->
1789
1790An import attribute is not supported by this version of Node.js.
1791
1792<a id="ERR_IMPORT_ATTRIBUTE_UNSUPPORTED"></a>
1793
1794### `ERR_IMPORT_ATTRIBUTE_UNSUPPORTED`
1795
1796<!-- YAML
1797added: v18.19.0
1798-->
1799
1800An import attribute is not supported by this version of Node.js.
1801
1802<a id="ERR_INCOMPATIBLE_OPTION_PAIR"></a>
1803
1804### `ERR_INCOMPATIBLE_OPTION_PAIR`
1805
1806An option pair is incompatible with each other and cannot be used at the same
1807time.
1808
1809<a id="ERR_INPUT_TYPE_NOT_ALLOWED"></a>
1810
1811### `ERR_INPUT_TYPE_NOT_ALLOWED`
1812
1813> Stability: 1 - Experimental
1814
1815The `--input-type` flag was used to attempt to execute a file. This flag can
1816only be used with input via `--eval`, `--print`, or `STDIN`.
1817
1818<a id="ERR_INSPECTOR_ALREADY_ACTIVATED"></a>
1819
1820### `ERR_INSPECTOR_ALREADY_ACTIVATED`
1821
1822While using the `node:inspector` module, an attempt was made to activate the
1823inspector when it already started to listen on a port. Use `inspector.close()`
1824before activating it on a different address.
1825
1826<a id="ERR_INSPECTOR_ALREADY_CONNECTED"></a>
1827
1828### `ERR_INSPECTOR_ALREADY_CONNECTED`
1829
1830While using the `node:inspector` module, an attempt was made to connect when the
1831inspector was already connected.
1832
1833<a id="ERR_INSPECTOR_CLOSED"></a>
1834
1835### `ERR_INSPECTOR_CLOSED`
1836
1837While using the `node:inspector` module, an attempt was made to use the
1838inspector after the session had already closed.
1839
1840<a id="ERR_INSPECTOR_COMMAND"></a>
1841
1842### `ERR_INSPECTOR_COMMAND`
1843
1844An error occurred while issuing a command via the `node:inspector` module.
1845
1846<a id="ERR_INSPECTOR_NOT_ACTIVE"></a>
1847
1848### `ERR_INSPECTOR_NOT_ACTIVE`
1849
1850The `inspector` is not active when `inspector.waitForDebugger()` is called.
1851
1852<a id="ERR_INSPECTOR_NOT_AVAILABLE"></a>
1853
1854### `ERR_INSPECTOR_NOT_AVAILABLE`
1855
1856The `node:inspector` module is not available for use.
1857
1858<a id="ERR_INSPECTOR_NOT_CONNECTED"></a>
1859
1860### `ERR_INSPECTOR_NOT_CONNECTED`
1861
1862While using the `node:inspector` module, an attempt was made to use the
1863inspector before it was connected.
1864
1865<a id="ERR_INSPECTOR_NOT_WORKER"></a>
1866
1867### `ERR_INSPECTOR_NOT_WORKER`
1868
1869An API was called on the main thread that can only be used from
1870the worker thread.
1871
1872<a id="ERR_INTERNAL_ASSERTION"></a>
1873
1874### `ERR_INTERNAL_ASSERTION`
1875
1876There was a bug in Node.js or incorrect usage of Node.js internals.
1877To fix the error, open an issue at <https://github.com/nodejs/node/issues>.
1878
1879<a id="ERR_INVALID_ADDRESS_FAMILY"></a>
1880
1881### `ERR_INVALID_ADDRESS_FAMILY`
1882
1883The provided address family is not understood by the Node.js API.
1884
1885<a id="ERR_INVALID_ARG_TYPE"></a>
1886
1887### `ERR_INVALID_ARG_TYPE`
1888
1889An argument of the wrong type was passed to a Node.js API.
1890
1891<a id="ERR_INVALID_ARG_VALUE"></a>
1892
1893### `ERR_INVALID_ARG_VALUE`
1894
1895An invalid or unsupported value was passed for a given argument.
1896
1897<a id="ERR_INVALID_ASYNC_ID"></a>
1898
1899### `ERR_INVALID_ASYNC_ID`
1900
1901An invalid `asyncId` or `triggerAsyncId` was passed using `AsyncHooks`. An id
1902less than -1 should never happen.
1903
1904<a id="ERR_INVALID_BUFFER_SIZE"></a>
1905
1906### `ERR_INVALID_BUFFER_SIZE`
1907
1908A swap was performed on a `Buffer` but its size was not compatible with the
1909operation.
1910
1911<a id="ERR_INVALID_CHAR"></a>
1912
1913### `ERR_INVALID_CHAR`
1914
1915Invalid characters were detected in headers.
1916
1917<a id="ERR_INVALID_CURSOR_POS"></a>
1918
1919### `ERR_INVALID_CURSOR_POS`
1920
1921A cursor on a given stream cannot be moved to a specified row without a
1922specified column.
1923
1924<a id="ERR_INVALID_FD"></a>
1925
1926### `ERR_INVALID_FD`
1927
1928A file descriptor ('fd') was not valid (e.g. it was a negative value).
1929
1930<a id="ERR_INVALID_FD_TYPE"></a>
1931
1932### `ERR_INVALID_FD_TYPE`
1933
1934A file descriptor ('fd') type was not valid.
1935
1936<a id="ERR_INVALID_FILE_URL_HOST"></a>
1937
1938### `ERR_INVALID_FILE_URL_HOST`
1939
1940A Node.js API that consumes `file:` URLs (such as certain functions in the
1941[`fs`][] module) encountered a file URL with an incompatible host. This
1942situation can only occur on Unix-like systems where only `localhost` or an empty
1943host is supported.
1944
1945<a id="ERR_INVALID_FILE_URL_PATH"></a>
1946
1947### `ERR_INVALID_FILE_URL_PATH`
1948
1949A Node.js API that consumes `file:` URLs (such as certain functions in the
1950[`fs`][] module) encountered a file URL with an incompatible path. The exact
1951semantics for determining whether a path can be used is platform-dependent.
1952
1953<a id="ERR_INVALID_HANDLE_TYPE"></a>
1954
1955### `ERR_INVALID_HANDLE_TYPE`
1956
1957An attempt was made to send an unsupported "handle" over an IPC communication
1958channel to a child process. See [`subprocess.send()`][] and [`process.send()`][]
1959for more information.
1960
1961<a id="ERR_INVALID_HTTP_TOKEN"></a>
1962
1963### `ERR_INVALID_HTTP_TOKEN`
1964
1965An invalid HTTP token was supplied.
1966
1967<a id="ERR_INVALID_IP_ADDRESS"></a>
1968
1969### `ERR_INVALID_IP_ADDRESS`
1970
1971An IP address is not valid.
1972
1973<a id="ERR_INVALID_MIME_SYNTAX"></a>
1974
1975### `ERR_INVALID_MIME_SYNTAX`
1976
1977The syntax of a MIME is not valid.
1978
1979<a id="ERR_INVALID_MODULE"></a>
1980
1981### `ERR_INVALID_MODULE`
1982
1983<!-- YAML
1984added:
1985  - v15.0.0
1986  - v14.18.0
1987-->
1988
1989An attempt was made to load a module that does not exist or was otherwise not
1990valid.
1991
1992<a id="ERR_INVALID_MODULE_SPECIFIER"></a>
1993
1994### `ERR_INVALID_MODULE_SPECIFIER`
1995
1996The imported module string is an invalid URL, package name, or package subpath
1997specifier.
1998
1999<a id="ERR_INVALID_OBJECT_DEFINE_PROPERTY"></a>
2000
2001### `ERR_INVALID_OBJECT_DEFINE_PROPERTY`
2002
2003An error occurred while setting an invalid attribute on the property of
2004an object.
2005
2006<a id="ERR_INVALID_PACKAGE_CONFIG"></a>
2007
2008### `ERR_INVALID_PACKAGE_CONFIG`
2009
2010An invalid [`package.json`][] file failed parsing.
2011
2012<a id="ERR_INVALID_PACKAGE_TARGET"></a>
2013
2014### `ERR_INVALID_PACKAGE_TARGET`
2015
2016The `package.json` [`"exports"`][] field contains an invalid target mapping
2017value for the attempted module resolution.
2018
2019<a id="ERR_INVALID_PERFORMANCE_MARK"></a>
2020
2021### `ERR_INVALID_PERFORMANCE_MARK`
2022
2023While using the Performance Timing API (`perf_hooks`), a performance mark is
2024invalid.
2025
2026<a id="ERR_INVALID_PROTOCOL"></a>
2027
2028### `ERR_INVALID_PROTOCOL`
2029
2030An invalid `options.protocol` was passed to `http.request()`.
2031
2032<a id="ERR_INVALID_REPL_EVAL_CONFIG"></a>
2033
2034### `ERR_INVALID_REPL_EVAL_CONFIG`
2035
2036Both `breakEvalOnSigint` and `eval` options were set in the [`REPL`][] config,
2037which is not supported.
2038
2039<a id="ERR_INVALID_REPL_INPUT"></a>
2040
2041### `ERR_INVALID_REPL_INPUT`
2042
2043The input may not be used in the [`REPL`][]. The conditions under which this
2044error is used are described in the [`REPL`][] documentation.
2045
2046<a id="ERR_INVALID_RETURN_PROPERTY"></a>
2047
2048### `ERR_INVALID_RETURN_PROPERTY`
2049
2050Thrown in case a function option does not provide a valid value for one of its
2051returned object properties on execution.
2052
2053<a id="ERR_INVALID_RETURN_PROPERTY_VALUE"></a>
2054
2055### `ERR_INVALID_RETURN_PROPERTY_VALUE`
2056
2057Thrown in case a function option does not provide an expected value
2058type for one of its returned object properties on execution.
2059
2060<a id="ERR_INVALID_RETURN_VALUE"></a>
2061
2062### `ERR_INVALID_RETURN_VALUE`
2063
2064Thrown in case a function option does not return an expected value
2065type on execution, such as when a function is expected to return a promise.
2066
2067<a id="ERR_INVALID_STATE"></a>
2068
2069### `ERR_INVALID_STATE`
2070
2071<!-- YAML
2072added: v15.0.0
2073-->
2074
2075Indicates that an operation cannot be completed due to an invalid state.
2076For instance, an object may have already been destroyed, or may be
2077performing another operation.
2078
2079<a id="ERR_INVALID_SYNC_FORK_INPUT"></a>
2080
2081### `ERR_INVALID_SYNC_FORK_INPUT`
2082
2083A `Buffer`, `TypedArray`, `DataView`, or `string` was provided as stdio input to
2084an asynchronous fork. See the documentation for the [`child_process`][] module
2085for more information.
2086
2087<a id="ERR_INVALID_THIS"></a>
2088
2089### `ERR_INVALID_THIS`
2090
2091A Node.js API function was called with an incompatible `this` value.
2092
2093```js
2094const urlSearchParams = new URLSearchParams('foo=bar&baz=new');
2095
2096const buf = Buffer.alloc(1);
2097urlSearchParams.has.call(buf, 'foo');
2098// Throws a TypeError with code 'ERR_INVALID_THIS'
2099```
2100
2101<a id="ERR_INVALID_TRANSFER_OBJECT"></a>
2102
2103### `ERR_INVALID_TRANSFER_OBJECT`
2104
2105An invalid transfer object was passed to `postMessage()`.
2106
2107<a id="ERR_INVALID_TUPLE"></a>
2108
2109### `ERR_INVALID_TUPLE`
2110
2111An element in the `iterable` provided to the [WHATWG][WHATWG URL API]
2112[`URLSearchParams` constructor][`new URLSearchParams(iterable)`] did not
2113represent a `[name, value]` tuple – that is, if an element is not iterable, or
2114does not consist of exactly two elements.
2115
2116<a id="ERR_INVALID_URI"></a>
2117
2118### `ERR_INVALID_URI`
2119
2120An invalid URI was passed.
2121
2122<a id="ERR_INVALID_URL"></a>
2123
2124### `ERR_INVALID_URL`
2125
2126An invalid URL was passed to the [WHATWG][WHATWG URL API] [`URL`
2127constructor][`new URL(input)`] or the legacy [`url.parse()`][] to be parsed.
2128The thrown error object typically has an additional property `'input'` that
2129contains the URL that failed to parse.
2130
2131<a id="ERR_INVALID_URL_SCHEME"></a>
2132
2133### `ERR_INVALID_URL_SCHEME`
2134
2135An attempt was made to use a URL of an incompatible scheme (protocol) for a
2136specific purpose. It is only used in the [WHATWG URL API][] support in the
2137[`fs`][] module (which only accepts URLs with `'file'` scheme), but may be used
2138in other Node.js APIs as well in the future.
2139
2140<a id="ERR_IPC_CHANNEL_CLOSED"></a>
2141
2142### `ERR_IPC_CHANNEL_CLOSED`
2143
2144An attempt was made to use an IPC communication channel that was already closed.
2145
2146<a id="ERR_IPC_DISCONNECTED"></a>
2147
2148### `ERR_IPC_DISCONNECTED`
2149
2150An attempt was made to disconnect an IPC communication channel that was already
2151disconnected. See the documentation for the [`child_process`][] module
2152for more information.
2153
2154<a id="ERR_IPC_ONE_PIPE"></a>
2155
2156### `ERR_IPC_ONE_PIPE`
2157
2158An attempt was made to create a child Node.js process using more than one IPC
2159communication channel. See the documentation for the [`child_process`][] module
2160for more information.
2161
2162<a id="ERR_IPC_SYNC_FORK"></a>
2163
2164### `ERR_IPC_SYNC_FORK`
2165
2166An attempt was made to open an IPC communication channel with a synchronously
2167forked Node.js process. See the documentation for the [`child_process`][] module
2168for more information.
2169
2170<a id="ERR_LOADER_CHAIN_INCOMPLETE"></a>
2171
2172### `ERR_LOADER_CHAIN_INCOMPLETE`
2173
2174<!-- YAML
2175added: v18.6.0
2176-->
2177
2178An ESM loader hook returned without calling `next()` and without explicitly
2179signaling a short circuit.
2180
2181<a id="ERR_MANIFEST_ASSERT_INTEGRITY"></a>
2182
2183### `ERR_MANIFEST_ASSERT_INTEGRITY`
2184
2185An attempt was made to load a resource, but the resource did not match the
2186integrity defined by the policy manifest. See the documentation for [policy][]
2187manifests for more information.
2188
2189<a id="ERR_MANIFEST_DEPENDENCY_MISSING"></a>
2190
2191### `ERR_MANIFEST_DEPENDENCY_MISSING`
2192
2193An attempt was made to load a resource, but the resource was not listed as a
2194dependency from the location that attempted to load it. See the documentation
2195for [policy][] manifests for more information.
2196
2197<a id="ERR_MANIFEST_INTEGRITY_MISMATCH"></a>
2198
2199### `ERR_MANIFEST_INTEGRITY_MISMATCH`
2200
2201An attempt was made to load a policy manifest, but the manifest had multiple
2202entries for a resource which did not match each other. Update the manifest
2203entries to match in order to resolve this error. See the documentation for
2204[policy][] manifests for more information.
2205
2206<a id="ERR_MANIFEST_INVALID_RESOURCE_FIELD"></a>
2207
2208### `ERR_MANIFEST_INVALID_RESOURCE_FIELD`
2209
2210A policy manifest resource had an invalid value for one of its fields. Update
2211the manifest entry to match in order to resolve this error. See the
2212documentation for [policy][] manifests for more information.
2213
2214<a id="ERR_MANIFEST_INVALID_SPECIFIER"></a>
2215
2216### `ERR_MANIFEST_INVALID_SPECIFIER`
2217
2218A policy manifest resource had an invalid value for one of its dependency
2219mappings. Update the manifest entry to match to resolve this error. See the
2220documentation for [policy][] manifests for more information.
2221
2222<a id="ERR_MANIFEST_PARSE_POLICY"></a>
2223
2224### `ERR_MANIFEST_PARSE_POLICY`
2225
2226An attempt was made to load a policy manifest, but the manifest was unable to
2227be parsed. See the documentation for [policy][] manifests for more information.
2228
2229<a id="ERR_MANIFEST_TDZ"></a>
2230
2231### `ERR_MANIFEST_TDZ`
2232
2233An attempt was made to read from a policy manifest, but the manifest
2234initialization has not yet taken place. This is likely a bug in Node.js.
2235
2236<a id="ERR_MANIFEST_UNKNOWN_ONERROR"></a>
2237
2238### `ERR_MANIFEST_UNKNOWN_ONERROR`
2239
2240A policy manifest was loaded, but had an unknown value for its "onerror"
2241behavior. See the documentation for [policy][] manifests for more information.
2242
2243<a id="ERR_MEMORY_ALLOCATION_FAILED"></a>
2244
2245### `ERR_MEMORY_ALLOCATION_FAILED`
2246
2247An attempt was made to allocate memory (usually in the C++ layer) but it
2248failed.
2249
2250<a id="ERR_MESSAGE_TARGET_CONTEXT_UNAVAILABLE"></a>
2251
2252### `ERR_MESSAGE_TARGET_CONTEXT_UNAVAILABLE`
2253
2254<!-- YAML
2255added:
2256  - v14.5.0
2257  - v12.19.0
2258-->
2259
2260A message posted to a [`MessagePort`][] could not be deserialized in the target
2261[vm][] `Context`. Not all Node.js objects can be successfully instantiated in
2262any context at this time, and attempting to transfer them using `postMessage()`
2263can fail on the receiving side in that case.
2264
2265<a id="ERR_METHOD_NOT_IMPLEMENTED"></a>
2266
2267### `ERR_METHOD_NOT_IMPLEMENTED`
2268
2269A method is required but not implemented.
2270
2271<a id="ERR_MISSING_ARGS"></a>
2272
2273### `ERR_MISSING_ARGS`
2274
2275A required argument of a Node.js API was not passed. This is only used for
2276strict compliance with the API specification (which in some cases may accept
2277`func(undefined)` but not `func()`). In most native Node.js APIs,
2278`func(undefined)` and `func()` are treated identically, and the
2279[`ERR_INVALID_ARG_TYPE`][] error code may be used instead.
2280
2281<a id="ERR_MISSING_OPTION"></a>
2282
2283### `ERR_MISSING_OPTION`
2284
2285For APIs that accept options objects, some options might be mandatory. This code
2286is thrown if a required option is missing.
2287
2288<a id="ERR_MISSING_PASSPHRASE"></a>
2289
2290### `ERR_MISSING_PASSPHRASE`
2291
2292An attempt was made to read an encrypted key without specifying a passphrase.
2293
2294<a id="ERR_MISSING_PLATFORM_FOR_WORKER"></a>
2295
2296### `ERR_MISSING_PLATFORM_FOR_WORKER`
2297
2298The V8 platform used by this instance of Node.js does not support creating
2299Workers. This is caused by lack of embedder support for Workers. In particular,
2300this error will not occur with standard builds of Node.js.
2301
2302<a id="ERR_MISSING_TRANSFERABLE_IN_TRANSFER_LIST"></a>
2303
2304### `ERR_MISSING_TRANSFERABLE_IN_TRANSFER_LIST`
2305
2306<!-- YAML
2307added: v15.0.0
2308-->
2309
2310An object that needs to be explicitly listed in the `transferList` argument
2311is in the object passed to a [`postMessage()`][] call, but is not provided
2312in the `transferList` for that call. Usually, this is a `MessagePort`.
2313
2314In Node.js versions prior to v15.0.0, the error code being used here was
2315[`ERR_MISSING_MESSAGE_PORT_IN_TRANSFER_LIST`][]. However, the set of
2316transferable object types has been expanded to cover more types than
2317`MessagePort`.
2318
2319<a id="ERR_MODULE_NOT_FOUND"></a>
2320
2321### `ERR_MODULE_NOT_FOUND`
2322
2323A module file could not be resolved by the ECMAScript modules loader while
2324attempting an `import` operation or when loading the program entry point.
2325
2326<a id="ERR_MULTIPLE_CALLBACK"></a>
2327
2328### `ERR_MULTIPLE_CALLBACK`
2329
2330A callback was called more than once.
2331
2332A callback is almost always meant to only be called once as the query
2333can either be fulfilled or rejected but not both at the same time. The latter
2334would be possible by calling a callback more than once.
2335
2336<a id="ERR_NAPI_CONS_FUNCTION"></a>
2337
2338### `ERR_NAPI_CONS_FUNCTION`
2339
2340While using `Node-API`, a constructor passed was not a function.
2341
2342<a id="ERR_NAPI_INVALID_DATAVIEW_ARGS"></a>
2343
2344### `ERR_NAPI_INVALID_DATAVIEW_ARGS`
2345
2346While calling `napi_create_dataview()`, a given `offset` was outside the bounds
2347of the dataview or `offset + length` was larger than a length of given `buffer`.
2348
2349<a id="ERR_NAPI_INVALID_TYPEDARRAY_ALIGNMENT"></a>
2350
2351### `ERR_NAPI_INVALID_TYPEDARRAY_ALIGNMENT`
2352
2353While calling `napi_create_typedarray()`, the provided `offset` was not a
2354multiple of the element size.
2355
2356<a id="ERR_NAPI_INVALID_TYPEDARRAY_LENGTH"></a>
2357
2358### `ERR_NAPI_INVALID_TYPEDARRAY_LENGTH`
2359
2360While calling `napi_create_typedarray()`, `(length * size_of_element) +
2361byte_offset` was larger than the length of given `buffer`.
2362
2363<a id="ERR_NAPI_TSFN_CALL_JS"></a>
2364
2365### `ERR_NAPI_TSFN_CALL_JS`
2366
2367An error occurred while invoking the JavaScript portion of the thread-safe
2368function.
2369
2370<a id="ERR_NAPI_TSFN_GET_UNDEFINED"></a>
2371
2372### `ERR_NAPI_TSFN_GET_UNDEFINED`
2373
2374An error occurred while attempting to retrieve the JavaScript `undefined`
2375value.
2376
2377<a id="ERR_NAPI_TSFN_START_IDLE_LOOP"></a>
2378
2379### `ERR_NAPI_TSFN_START_IDLE_LOOP`
2380
2381On the main thread, values are removed from the queue associated with the
2382thread-safe function in an idle loop. This error indicates that an error
2383has occurred when attempting to start the loop.
2384
2385<a id="ERR_NAPI_TSFN_STOP_IDLE_LOOP"></a>
2386
2387### `ERR_NAPI_TSFN_STOP_IDLE_LOOP`
2388
2389Once no more items are left in the queue, the idle loop must be suspended. This
2390error indicates that the idle loop has failed to stop.
2391
2392<a id="ERR_NOT_BUILDING_SNAPSHOT"></a>
2393
2394### `ERR_NOT_BUILDING_SNAPSHOT`
2395
2396An attempt was made to use operations that can only be used when building
2397V8 startup snapshot even though Node.js isn't building one.
2398
2399<a id="ERR_NO_CRYPTO"></a>
2400
2401### `ERR_NO_CRYPTO`
2402
2403An attempt was made to use crypto features while Node.js was not compiled with
2404OpenSSL crypto support.
2405
2406<a id="ERR_NO_ICU"></a>
2407
2408### `ERR_NO_ICU`
2409
2410An attempt was made to use features that require [ICU][], but Node.js was not
2411compiled with ICU support.
2412
2413<a id="ERR_NON_CONTEXT_AWARE_DISABLED"></a>
2414
2415### `ERR_NON_CONTEXT_AWARE_DISABLED`
2416
2417A non-context-aware native addon was loaded in a process that disallows them.
2418
2419<a id="ERR_OUT_OF_RANGE"></a>
2420
2421### `ERR_OUT_OF_RANGE`
2422
2423A given value is out of the accepted range.
2424
2425<a id="ERR_PACKAGE_IMPORT_NOT_DEFINED"></a>
2426
2427### `ERR_PACKAGE_IMPORT_NOT_DEFINED`
2428
2429The `package.json` [`"imports"`][] field does not define the given internal
2430package specifier mapping.
2431
2432<a id="ERR_PACKAGE_PATH_NOT_EXPORTED"></a>
2433
2434### `ERR_PACKAGE_PATH_NOT_EXPORTED`
2435
2436The `package.json` [`"exports"`][] field does not export the requested subpath.
2437Because exports are encapsulated, private internal modules that are not exported
2438cannot be imported through the package resolution, unless using an absolute URL.
2439
2440<a id="ERR_PARSE_ARGS_INVALID_OPTION_VALUE"></a>
2441
2442### `ERR_PARSE_ARGS_INVALID_OPTION_VALUE`
2443
2444<!-- YAML
2445added: v18.3.0
2446-->
2447
2448When `strict` set to `true`, thrown by [`util.parseArgs()`][] if a {boolean}
2449value is provided for an option of type {string}, or if a {string}
2450value is provided for an option of type {boolean}.
2451
2452<a id="ERR_PARSE_ARGS_UNEXPECTED_POSITIONAL"></a>
2453
2454### `ERR_PARSE_ARGS_UNEXPECTED_POSITIONAL`
2455
2456<!-- YAML
2457added: v18.3.0
2458-->
2459
2460Thrown by [`util.parseArgs()`][], when a positional argument is provided and
2461`allowPositionals` is set to `false`.
2462
2463<a id="ERR_PARSE_ARGS_UNKNOWN_OPTION"></a>
2464
2465### `ERR_PARSE_ARGS_UNKNOWN_OPTION`
2466
2467<!-- YAML
2468added: v18.3.0
2469-->
2470
2471When `strict` set to `true`, thrown by [`util.parseArgs()`][] if an argument
2472is not configured in `options`.
2473
2474<a id="ERR_PERFORMANCE_INVALID_TIMESTAMP"></a>
2475
2476### `ERR_PERFORMANCE_INVALID_TIMESTAMP`
2477
2478An invalid timestamp value was provided for a performance mark or measure.
2479
2480<a id="ERR_PERFORMANCE_MEASURE_INVALID_OPTIONS"></a>
2481
2482### `ERR_PERFORMANCE_MEASURE_INVALID_OPTIONS`
2483
2484Invalid options were provided for a performance measure.
2485
2486<a id="ERR_PROTO_ACCESS"></a>
2487
2488### `ERR_PROTO_ACCESS`
2489
2490Accessing `Object.prototype.__proto__` has been forbidden using
2491[`--disable-proto=throw`][]. [`Object.getPrototypeOf`][] and
2492[`Object.setPrototypeOf`][] should be used to get and set the prototype of an
2493object.
2494
2495<a id="ERR_REQUIRE_ESM"></a>
2496
2497### `ERR_REQUIRE_ESM`
2498
2499> Stability: 1 - Experimental
2500
2501An attempt was made to `require()` an [ES Module][].
2502
2503<a id="ERR_SCRIPT_EXECUTION_INTERRUPTED"></a>
2504
2505### `ERR_SCRIPT_EXECUTION_INTERRUPTED`
2506
2507Script execution was interrupted by `SIGINT` (For
2508example, <kbd>Ctrl</kbd>+<kbd>C</kbd> was pressed.)
2509
2510<a id="ERR_SCRIPT_EXECUTION_TIMEOUT"></a>
2511
2512### `ERR_SCRIPT_EXECUTION_TIMEOUT`
2513
2514Script execution timed out, possibly due to bugs in the script being executed.
2515
2516<a id="ERR_SERVER_ALREADY_LISTEN"></a>
2517
2518### `ERR_SERVER_ALREADY_LISTEN`
2519
2520The [`server.listen()`][] method was called while a `net.Server` was already
2521listening. This applies to all instances of `net.Server`, including HTTP, HTTPS,
2522and HTTP/2 `Server` instances.
2523
2524<a id="ERR_SERVER_NOT_RUNNING"></a>
2525
2526### `ERR_SERVER_NOT_RUNNING`
2527
2528The [`server.close()`][] method was called when a `net.Server` was not
2529running. This applies to all instances of `net.Server`, including HTTP, HTTPS,
2530and HTTP/2 `Server` instances.
2531
2532<a id="ERR_SOCKET_ALREADY_BOUND"></a>
2533
2534### `ERR_SOCKET_ALREADY_BOUND`
2535
2536An attempt was made to bind a socket that has already been bound.
2537
2538<a id="ERR_SOCKET_BAD_BUFFER_SIZE"></a>
2539
2540### `ERR_SOCKET_BAD_BUFFER_SIZE`
2541
2542An invalid (negative) size was passed for either the `recvBufferSize` or
2543`sendBufferSize` options in [`dgram.createSocket()`][].
2544
2545<a id="ERR_SOCKET_BAD_PORT"></a>
2546
2547### `ERR_SOCKET_BAD_PORT`
2548
2549An API function expecting a port >= 0 and < 65536 received an invalid value.
2550
2551<a id="ERR_SOCKET_BAD_TYPE"></a>
2552
2553### `ERR_SOCKET_BAD_TYPE`
2554
2555An API function expecting a socket type (`udp4` or `udp6`) received an invalid
2556value.
2557
2558<a id="ERR_SOCKET_BUFFER_SIZE"></a>
2559
2560### `ERR_SOCKET_BUFFER_SIZE`
2561
2562While using [`dgram.createSocket()`][], the size of the receive or send `Buffer`
2563could not be determined.
2564
2565<a id="ERR_SOCKET_CLOSED"></a>
2566
2567### `ERR_SOCKET_CLOSED`
2568
2569An attempt was made to operate on an already closed socket.
2570
2571<a id="ERR_SOCKET_CLOSED_BEFORE_CONNECTION"></a>
2572
2573### `ERR_SOCKET_CLOSED_BEFORE_CONNECTION`
2574
2575When calling [`net.Socket.write()`][] on a connecting socket and the socket was
2576closed before the connection was established.
2577
2578<a id="ERR_SOCKET_DGRAM_IS_CONNECTED"></a>
2579
2580### `ERR_SOCKET_DGRAM_IS_CONNECTED`
2581
2582A [`dgram.connect()`][] call was made on an already connected socket.
2583
2584<a id="ERR_SOCKET_DGRAM_NOT_CONNECTED"></a>
2585
2586### `ERR_SOCKET_DGRAM_NOT_CONNECTED`
2587
2588A [`dgram.disconnect()`][] or [`dgram.remoteAddress()`][] call was made on a
2589disconnected socket.
2590
2591<a id="ERR_SOCKET_DGRAM_NOT_RUNNING"></a>
2592
2593### `ERR_SOCKET_DGRAM_NOT_RUNNING`
2594
2595A call was made and the UDP subsystem was not running.
2596
2597<a id="ERR_SRI_PARSE"></a>
2598
2599### `ERR_SRI_PARSE`
2600
2601A string was provided for a Subresource Integrity check, but was unable to be
2602parsed. Check the format of integrity attributes by looking at the
2603[Subresource Integrity specification][].
2604
2605<a id="ERR_STREAM_ALREADY_FINISHED"></a>
2606
2607### `ERR_STREAM_ALREADY_FINISHED`
2608
2609A stream method was called that cannot complete because the stream was
2610finished.
2611
2612<a id="ERR_STREAM_CANNOT_PIPE"></a>
2613
2614### `ERR_STREAM_CANNOT_PIPE`
2615
2616An attempt was made to call [`stream.pipe()`][] on a [`Writable`][] stream.
2617
2618<a id="ERR_STREAM_DESTROYED"></a>
2619
2620### `ERR_STREAM_DESTROYED`
2621
2622A stream method was called that cannot complete because the stream was
2623destroyed using `stream.destroy()`.
2624
2625<a id="ERR_STREAM_NULL_VALUES"></a>
2626
2627### `ERR_STREAM_NULL_VALUES`
2628
2629An attempt was made to call [`stream.write()`][] with a `null` chunk.
2630
2631<a id="ERR_STREAM_PREMATURE_CLOSE"></a>
2632
2633### `ERR_STREAM_PREMATURE_CLOSE`
2634
2635An error returned by `stream.finished()` and `stream.pipeline()`, when a stream
2636or a pipeline ends non gracefully with no explicit error.
2637
2638<a id="ERR_STREAM_PUSH_AFTER_EOF"></a>
2639
2640### `ERR_STREAM_PUSH_AFTER_EOF`
2641
2642An attempt was made to call [`stream.push()`][] after a `null`(EOF) had been
2643pushed to the stream.
2644
2645<a id="ERR_STREAM_UNSHIFT_AFTER_END_EVENT"></a>
2646
2647### `ERR_STREAM_UNSHIFT_AFTER_END_EVENT`
2648
2649An attempt was made to call [`stream.unshift()`][] after the `'end'` event was
2650emitted.
2651
2652<a id="ERR_STREAM_WRAP"></a>
2653
2654### `ERR_STREAM_WRAP`
2655
2656Prevents an abort if a string decoder was set on the Socket or if the decoder
2657is in `objectMode`.
2658
2659```js
2660const Socket = require('node:net').Socket;
2661const instance = new Socket();
2662
2663instance.setEncoding('utf8');
2664```
2665
2666<a id="ERR_STREAM_WRITE_AFTER_END"></a>
2667
2668### `ERR_STREAM_WRITE_AFTER_END`
2669
2670An attempt was made to call [`stream.write()`][] after `stream.end()` has been
2671called.
2672
2673<a id="ERR_STRING_TOO_LONG"></a>
2674
2675### `ERR_STRING_TOO_LONG`
2676
2677An attempt has been made to create a string longer than the maximum allowed
2678length.
2679
2680<a id="ERR_SYNTHETIC"></a>
2681
2682### `ERR_SYNTHETIC`
2683
2684An artificial error object used to capture the call stack for diagnostic
2685reports.
2686
2687<a id="ERR_SYSTEM_ERROR"></a>
2688
2689### `ERR_SYSTEM_ERROR`
2690
2691An unspecified or non-specific system error has occurred within the Node.js
2692process. The error object will have an `err.info` object property with
2693additional details.
2694
2695<a id="ERR_TAP_LEXER_ERROR"></a>
2696
2697### `ERR_TAP_LEXER_ERROR`
2698
2699An error representing a failing lexer state.
2700
2701<a id="ERR_TAP_PARSER_ERROR"></a>
2702
2703### `ERR_TAP_PARSER_ERROR`
2704
2705An error representing a failing parser state. Additional information about
2706the token causing the error is available via the `cause` property.
2707
2708<a id="ERR_TAP_VALIDATION_ERROR"></a>
2709
2710### `ERR_TAP_VALIDATION_ERROR`
2711
2712This error represents a failed TAP validation.
2713
2714<a id="ERR_TEST_FAILURE"></a>
2715
2716### `ERR_TEST_FAILURE`
2717
2718This error represents a failed test. Additional information about the failure
2719is available via the `cause` property. The `failureType` property specifies
2720what the test was doing when the failure occurred.
2721
2722<a id="ERR_TLS_ALPN_CALLBACK_INVALID_RESULT"></a>
2723
2724### `ERR_TLS_ALPN_CALLBACK_INVALID_RESULT`
2725
2726This error is thrown when an `ALPNCallback` returns a value that is not in the
2727list of ALPN protocols offered by the client.
2728
2729<a id="ERR_TLS_ALPN_CALLBACK_WITH_PROTOCOLS"></a>
2730
2731### `ERR_TLS_ALPN_CALLBACK_WITH_PROTOCOLS`
2732
2733This error is thrown when creating a `TLSServer` if the TLS options include
2734both `ALPNProtocols` and `ALPNCallback`. These options are mutually exclusive.
2735
2736<a id="ERR_TLS_CERT_ALTNAME_FORMAT"></a>
2737
2738### `ERR_TLS_CERT_ALTNAME_FORMAT`
2739
2740This error is thrown by `checkServerIdentity` if a user-supplied
2741`subjectaltname` property violates encoding rules. Certificate objects produced
2742by Node.js itself always comply with encoding rules and will never cause
2743this error.
2744
2745<a id="ERR_TLS_CERT_ALTNAME_INVALID"></a>
2746
2747### `ERR_TLS_CERT_ALTNAME_INVALID`
2748
2749While using TLS, the host name/IP of the peer did not match any of the
2750`subjectAltNames` in its certificate.
2751
2752<a id="ERR_TLS_DH_PARAM_SIZE"></a>
2753
2754### `ERR_TLS_DH_PARAM_SIZE`
2755
2756While using TLS, the parameter offered for the Diffie-Hellman (`DH`)
2757key-agreement protocol is too small. By default, the key length must be greater
2758than or equal to 1024 bits to avoid vulnerabilities, even though it is strongly
2759recommended to use 2048 bits or larger for stronger security.
2760
2761<a id="ERR_TLS_HANDSHAKE_TIMEOUT"></a>
2762
2763### `ERR_TLS_HANDSHAKE_TIMEOUT`
2764
2765A TLS/SSL handshake timed out. In this case, the server must also abort the
2766connection.
2767
2768<a id="ERR_TLS_INVALID_CONTEXT"></a>
2769
2770### `ERR_TLS_INVALID_CONTEXT`
2771
2772<!-- YAML
2773added: v13.3.0
2774-->
2775
2776The context must be a `SecureContext`.
2777
2778<a id="ERR_TLS_INVALID_PROTOCOL_METHOD"></a>
2779
2780### `ERR_TLS_INVALID_PROTOCOL_METHOD`
2781
2782The specified  `secureProtocol` method is invalid. It is  either unknown, or
2783disabled because it is insecure.
2784
2785<a id="ERR_TLS_INVALID_PROTOCOL_VERSION"></a>
2786
2787### `ERR_TLS_INVALID_PROTOCOL_VERSION`
2788
2789Valid TLS protocol versions are `'TLSv1'`, `'TLSv1.1'`, or `'TLSv1.2'`.
2790
2791<a id="ERR_TLS_INVALID_STATE"></a>
2792
2793### `ERR_TLS_INVALID_STATE`
2794
2795<!-- YAML
2796added:
2797 - v13.10.0
2798 - v12.17.0
2799-->
2800
2801The TLS socket must be connected and securely established. Ensure the 'secure'
2802event is emitted before continuing.
2803
2804<a id="ERR_TLS_PROTOCOL_VERSION_CONFLICT"></a>
2805
2806### `ERR_TLS_PROTOCOL_VERSION_CONFLICT`
2807
2808Attempting to set a TLS protocol `minVersion` or `maxVersion` conflicts with an
2809attempt to set the `secureProtocol` explicitly. Use one mechanism or the other.
2810
2811<a id="ERR_TLS_PSK_SET_IDENTIY_HINT_FAILED"></a>
2812
2813### `ERR_TLS_PSK_SET_IDENTIY_HINT_FAILED`
2814
2815Failed to set PSK identity hint. Hint may be too long.
2816
2817<a id="ERR_TLS_RENEGOTIATION_DISABLED"></a>
2818
2819### `ERR_TLS_RENEGOTIATION_DISABLED`
2820
2821An attempt was made to renegotiate TLS on a socket instance with renegotiation
2822disabled.
2823
2824<a id="ERR_TLS_REQUIRED_SERVER_NAME"></a>
2825
2826### `ERR_TLS_REQUIRED_SERVER_NAME`
2827
2828While using TLS, the `server.addContext()` method was called without providing
2829a host name in the first parameter.
2830
2831<a id="ERR_TLS_SESSION_ATTACK"></a>
2832
2833### `ERR_TLS_SESSION_ATTACK`
2834
2835An excessive amount of TLS renegotiations is detected, which is a potential
2836vector for denial-of-service attacks.
2837
2838<a id="ERR_TLS_SNI_FROM_SERVER"></a>
2839
2840### `ERR_TLS_SNI_FROM_SERVER`
2841
2842An attempt was made to issue Server Name Indication from a TLS server-side
2843socket, which is only valid from a client.
2844
2845<a id="ERR_TRACE_EVENTS_CATEGORY_REQUIRED"></a>
2846
2847### `ERR_TRACE_EVENTS_CATEGORY_REQUIRED`
2848
2849The `trace_events.createTracing()` method requires at least one trace event
2850category.
2851
2852<a id="ERR_TRACE_EVENTS_UNAVAILABLE"></a>
2853
2854### `ERR_TRACE_EVENTS_UNAVAILABLE`
2855
2856The `node:trace_events` module could not be loaded because Node.js was compiled
2857with the `--without-v8-platform` flag.
2858
2859<a id="ERR_TRANSFORM_ALREADY_TRANSFORMING"></a>
2860
2861### `ERR_TRANSFORM_ALREADY_TRANSFORMING`
2862
2863A `Transform` stream finished while it was still transforming.
2864
2865<a id="ERR_TRANSFORM_WITH_LENGTH_0"></a>
2866
2867### `ERR_TRANSFORM_WITH_LENGTH_0`
2868
2869A `Transform` stream finished with data still in the write buffer.
2870
2871<a id="ERR_TTY_INIT_FAILED"></a>
2872
2873### `ERR_TTY_INIT_FAILED`
2874
2875The initialization of a TTY failed due to a system error.
2876
2877<a id="ERR_UNAVAILABLE_DURING_EXIT"></a>
2878
2879### `ERR_UNAVAILABLE_DURING_EXIT`
2880
2881Function was called within a [`process.on('exit')`][] handler that shouldn't be
2882called within [`process.on('exit')`][] handler.
2883
2884<a id="ERR_UNCAUGHT_EXCEPTION_CAPTURE_ALREADY_SET"></a>
2885
2886### `ERR_UNCAUGHT_EXCEPTION_CAPTURE_ALREADY_SET`
2887
2888[`process.setUncaughtExceptionCaptureCallback()`][] was called twice,
2889without first resetting the callback to `null`.
2890
2891This error is designed to prevent accidentally overwriting a callback registered
2892from another module.
2893
2894<a id="ERR_UNESCAPED_CHARACTERS"></a>
2895
2896### `ERR_UNESCAPED_CHARACTERS`
2897
2898A string that contained unescaped characters was received.
2899
2900<a id="ERR_UNHANDLED_ERROR"></a>
2901
2902### `ERR_UNHANDLED_ERROR`
2903
2904An unhandled error occurred (for instance, when an `'error'` event is emitted
2905by an [`EventEmitter`][] but an `'error'` handler is not registered).
2906
2907<a id="ERR_UNKNOWN_BUILTIN_MODULE"></a>
2908
2909### `ERR_UNKNOWN_BUILTIN_MODULE`
2910
2911Used to identify a specific kind of internal Node.js error that should not
2912typically be triggered by user code. Instances of this error point to an
2913internal bug within the Node.js binary itself.
2914
2915<a id="ERR_UNKNOWN_CREDENTIAL"></a>
2916
2917### `ERR_UNKNOWN_CREDENTIAL`
2918
2919A Unix group or user identifier that does not exist was passed.
2920
2921<a id="ERR_UNKNOWN_ENCODING"></a>
2922
2923### `ERR_UNKNOWN_ENCODING`
2924
2925An invalid or unknown encoding option was passed to an API.
2926
2927<a id="ERR_UNKNOWN_FILE_EXTENSION"></a>
2928
2929### `ERR_UNKNOWN_FILE_EXTENSION`
2930
2931> Stability: 1 - Experimental
2932
2933An attempt was made to load a module with an unknown or unsupported file
2934extension.
2935
2936<a id="ERR_UNKNOWN_MODULE_FORMAT"></a>
2937
2938### `ERR_UNKNOWN_MODULE_FORMAT`
2939
2940> Stability: 1 - Experimental
2941
2942An attempt was made to load a module with an unknown or unsupported format.
2943
2944<a id="ERR_UNKNOWN_SIGNAL"></a>
2945
2946### `ERR_UNKNOWN_SIGNAL`
2947
2948An invalid or unknown process signal was passed to an API expecting a valid
2949signal (such as [`subprocess.kill()`][]).
2950
2951<a id="ERR_UNSUPPORTED_DIR_IMPORT"></a>
2952
2953### `ERR_UNSUPPORTED_DIR_IMPORT`
2954
2955`import` a directory URL is unsupported. Instead,
2956[self-reference a package using its name][] and [define a custom subpath][] in
2957the [`"exports"`][] field of the [`package.json`][] file.
2958
2959<!-- eslint-skip -->
2960
2961```js
2962import './'; // unsupported
2963import './index.js'; // supported
2964import 'package-name'; // supported
2965```
2966
2967<a id="ERR_UNSUPPORTED_ESM_URL_SCHEME"></a>
2968
2969### `ERR_UNSUPPORTED_ESM_URL_SCHEME`
2970
2971`import` with URL schemes other than `file` and `data` is unsupported.
2972
2973<a id="ERR_USE_AFTER_CLOSE"></a>
2974
2975### `ERR_USE_AFTER_CLOSE`
2976
2977> Stability: 1 - Experimental
2978
2979An attempt was made to use something that was already closed.
2980
2981<a id="ERR_VALID_PERFORMANCE_ENTRY_TYPE"></a>
2982
2983### `ERR_VALID_PERFORMANCE_ENTRY_TYPE`
2984
2985While using the Performance Timing API (`perf_hooks`), no valid performance
2986entry types are found.
2987
2988<a id="ERR_VM_DYNAMIC_IMPORT_CALLBACK_MISSING_FLAG"></a>
2989
2990### `ERR_VM_DYNAMIC_IMPORT_CALLBACK_MISSING_FLAG`
2991
2992A dynamic import callback was invoked without `--experimental-vm-modules`.
2993
2994<a id="ERR_VM_DYNAMIC_IMPORT_CALLBACK_MISSING"></a>
2995
2996### `ERR_VM_DYNAMIC_IMPORT_CALLBACK_MISSING`
2997
2998A dynamic import callback was not specified.
2999
3000<a id="ERR_VM_MODULE_ALREADY_LINKED"></a>
3001
3002### `ERR_VM_MODULE_ALREADY_LINKED`
3003
3004The module attempted to be linked is not eligible for linking, because of one of
3005the following reasons:
3006
3007* It has already been linked (`linkingStatus` is `'linked'`)
3008* It is being linked (`linkingStatus` is `'linking'`)
3009* Linking has failed for this module (`linkingStatus` is `'errored'`)
3010
3011<a id="ERR_VM_MODULE_CACHED_DATA_REJECTED"></a>
3012
3013### `ERR_VM_MODULE_CACHED_DATA_REJECTED`
3014
3015The `cachedData` option passed to a module constructor is invalid.
3016
3017<a id="ERR_VM_MODULE_CANNOT_CREATE_CACHED_DATA"></a>
3018
3019### `ERR_VM_MODULE_CANNOT_CREATE_CACHED_DATA`
3020
3021Cached data cannot be created for modules which have already been evaluated.
3022
3023<a id="ERR_VM_MODULE_DIFFERENT_CONTEXT"></a>
3024
3025### `ERR_VM_MODULE_DIFFERENT_CONTEXT`
3026
3027The module being returned from the linker function is from a different context
3028than the parent module. Linked modules must share the same context.
3029
3030<a id="ERR_VM_MODULE_LINK_FAILURE"></a>
3031
3032### `ERR_VM_MODULE_LINK_FAILURE`
3033
3034The module was unable to be linked due to a failure.
3035
3036<a id="ERR_VM_MODULE_NOT_MODULE"></a>
3037
3038### `ERR_VM_MODULE_NOT_MODULE`
3039
3040The fulfilled value of a linking promise is not a `vm.Module` object.
3041
3042<a id="ERR_VM_MODULE_STATUS"></a>
3043
3044### `ERR_VM_MODULE_STATUS`
3045
3046The current module's status does not allow for this operation. The specific
3047meaning of the error depends on the specific function.
3048
3049<a id="ERR_WASI_ALREADY_STARTED"></a>
3050
3051### `ERR_WASI_ALREADY_STARTED`
3052
3053The WASI instance has already started.
3054
3055<a id="ERR_WASI_NOT_STARTED"></a>
3056
3057### `ERR_WASI_NOT_STARTED`
3058
3059The WASI instance has not been started.
3060
3061<a id="ERR_WEBASSEMBLY_RESPONSE"></a>
3062
3063### `ERR_WEBASSEMBLY_RESPONSE`
3064
3065<!-- YAML
3066added: v18.1.0
3067-->
3068
3069The `Response` that has been passed to `WebAssembly.compileStreaming` or to
3070`WebAssembly.instantiateStreaming` is not a valid WebAssembly response.
3071
3072<a id="ERR_WORKER_INIT_FAILED"></a>
3073
3074### `ERR_WORKER_INIT_FAILED`
3075
3076The `Worker` initialization failed.
3077
3078<a id="ERR_WORKER_INVALID_EXEC_ARGV"></a>
3079
3080### `ERR_WORKER_INVALID_EXEC_ARGV`
3081
3082The `execArgv` option passed to the `Worker` constructor contains
3083invalid flags.
3084
3085<a id="ERR_WORKER_NOT_RUNNING"></a>
3086
3087### `ERR_WORKER_NOT_RUNNING`
3088
3089An operation failed because the `Worker` instance is not currently running.
3090
3091<a id="ERR_WORKER_OUT_OF_MEMORY"></a>
3092
3093### `ERR_WORKER_OUT_OF_MEMORY`
3094
3095The `Worker` instance terminated because it reached its memory limit.
3096
3097<a id="ERR_WORKER_PATH"></a>
3098
3099### `ERR_WORKER_PATH`
3100
3101The path for the main script of a worker is neither an absolute path
3102nor a relative path starting with `./` or `../`.
3103
3104<a id="ERR_WORKER_UNSERIALIZABLE_ERROR"></a>
3105
3106### `ERR_WORKER_UNSERIALIZABLE_ERROR`
3107
3108All attempts at serializing an uncaught exception from a worker thread failed.
3109
3110<a id="ERR_WORKER_UNSUPPORTED_OPERATION"></a>
3111
3112### `ERR_WORKER_UNSUPPORTED_OPERATION`
3113
3114The requested functionality is not supported in worker threads.
3115
3116<a id="ERR_ZLIB_INITIALIZATION_FAILED"></a>
3117
3118### `ERR_ZLIB_INITIALIZATION_FAILED`
3119
3120Creation of a [`zlib`][] object failed due to incorrect configuration.
3121
3122<a id="HPE_HEADER_OVERFLOW"></a>
3123
3124### `HPE_HEADER_OVERFLOW`
3125
3126<!-- YAML
3127changes:
3128  - version:
3129     - v11.4.0
3130     - v10.15.0
3131    commit: 186035243fad247e3955f
3132    pr-url: https://github.com/nodejs-private/node-private/pull/143
3133    description: Max header size in `http_parser` was set to 8 KiB.
3134-->
3135
3136Too much HTTP header data was received. In order to protect against malicious or
3137malconfigured clients, if more than 8 KiB of HTTP header data is received then
3138HTTP parsing will abort without a request or response object being created, and
3139an `Error` with this code will be emitted.
3140
3141<a id="HPE_CHUNK_EXTENSIONS_OVERFLOW"></a>
3142
3143### `HPE_CHUNK_EXTENSIONS_OVERFLOW`
3144
3145<!-- YAML
3146added: v18.19.1
3147-->
3148
3149Too much data was received for a chunk extensions. In order to protect against
3150malicious or malconfigured clients, if more than 16 KiB of data is received
3151then an `Error` with this code will be emitted.
3152
3153<a id="HPE_UNEXPECTED_CONTENT_LENGTH"></a>
3154
3155### `HPE_UNEXPECTED_CONTENT_LENGTH`
3156
3157Server is sending both a `Content-Length` header and `Transfer-Encoding: chunked`.
3158
3159`Transfer-Encoding: chunked` allows the server to maintain an HTTP persistent
3160connection for dynamically generated content.
3161In this case, the `Content-Length` HTTP header cannot be used.
3162
3163Use `Content-Length` or `Transfer-Encoding: chunked`.
3164
3165<a id="MODULE_NOT_FOUND"></a>
3166
3167### `MODULE_NOT_FOUND`
3168
3169<!-- YAML
3170changes:
3171  - version: v12.0.0
3172    pr-url: https://github.com/nodejs/node/pull/25690
3173    description: Added `requireStack` property.
3174-->
3175
3176A module file could not be resolved by the CommonJS modules loader while
3177attempting a [`require()`][] operation or when loading the program entry point.
3178
3179## Legacy Node.js error codes
3180
3181> Stability: 0 - Deprecated. These error codes are either inconsistent, or have
3182> been removed.
3183
3184<a id="ERR_CANNOT_TRANSFER_OBJECT"></a>
3185
3186### `ERR_CANNOT_TRANSFER_OBJECT`
3187
3188<!--
3189added: v10.5.0
3190removed: v12.5.0
3191-->
3192
3193The value passed to `postMessage()` contained an object that is not supported
3194for transferring.
3195
3196<a id="ERR_CRYPTO_HASH_DIGEST_NO_UTF16"></a>
3197
3198### `ERR_CRYPTO_HASH_DIGEST_NO_UTF16`
3199
3200<!-- YAML
3201added: v9.0.0
3202removed: v12.12.0
3203-->
3204
3205The UTF-16 encoding was used with [`hash.digest()`][]. While the
3206`hash.digest()` method does allow an `encoding` argument to be passed in,
3207causing the method to return a string rather than a `Buffer`, the UTF-16
3208encoding (e.g. `ucs` or `utf16le`) is not supported.
3209
3210<a id="ERR_HTTP2_FRAME_ERROR"></a>
3211
3212### `ERR_HTTP2_FRAME_ERROR`
3213
3214<!-- YAML
3215added: v9.0.0
3216removed: v10.0.0
3217-->
3218
3219Used when a failure occurs sending an individual frame on the HTTP/2
3220session.
3221
3222<a id="ERR_HTTP2_HEADERS_OBJECT"></a>
3223
3224### `ERR_HTTP2_HEADERS_OBJECT`
3225
3226<!-- YAML
3227added: v9.0.0
3228removed: v10.0.0
3229-->
3230
3231Used when an HTTP/2 Headers Object is expected.
3232
3233<a id="ERR_HTTP2_HEADER_REQUIRED"></a>
3234
3235### `ERR_HTTP2_HEADER_REQUIRED`
3236
3237<!-- YAML
3238added: v9.0.0
3239removed: v10.0.0
3240-->
3241
3242Used when a required header is missing in an HTTP/2 message.
3243
3244<a id="ERR_HTTP2_INFO_HEADERS_AFTER_RESPOND"></a>
3245
3246### `ERR_HTTP2_INFO_HEADERS_AFTER_RESPOND`
3247
3248<!-- YAML
3249added: v9.0.0
3250removed: v10.0.0
3251-->
3252
3253HTTP/2 informational headers must only be sent _prior_ to calling the
3254`Http2Stream.prototype.respond()` method.
3255
3256<a id="ERR_HTTP2_STREAM_CLOSED"></a>
3257
3258### `ERR_HTTP2_STREAM_CLOSED`
3259
3260<!-- YAML
3261added: v9.0.0
3262removed: v10.0.0
3263-->
3264
3265Used when an action has been performed on an HTTP/2 Stream that has already
3266been closed.
3267
3268<a id="ERR_HTTP_INVALID_CHAR"></a>
3269
3270### `ERR_HTTP_INVALID_CHAR`
3271
3272<!-- YAML
3273added: v9.0.0
3274removed: v10.0.0
3275-->
3276
3277Used when an invalid character is found in an HTTP response status message
3278(reason phrase).
3279
3280<a id="ERR_INDEX_OUT_OF_RANGE"></a>
3281
3282### `ERR_INDEX_OUT_OF_RANGE`
3283
3284<!-- YAML
3285  added: v10.0.0
3286  removed: v11.0.0
3287-->
3288
3289A given index was out of the accepted range (e.g. negative offsets).
3290
3291<a id="ERR_INVALID_OPT_VALUE"></a>
3292
3293### `ERR_INVALID_OPT_VALUE`
3294
3295<!-- YAML
3296added: v8.0.0
3297removed: v15.0.0
3298-->
3299
3300An invalid or unexpected value was passed in an options object.
3301
3302<a id="ERR_INVALID_OPT_VALUE_ENCODING"></a>
3303
3304### `ERR_INVALID_OPT_VALUE_ENCODING`
3305
3306<!-- YAML
3307added: v9.0.0
3308removed: v15.0.0
3309-->
3310
3311An invalid or unknown file encoding was passed.
3312
3313<a id="ERR_MISSING_MESSAGE_PORT_IN_TRANSFER_LIST"></a>
3314
3315### `ERR_MISSING_MESSAGE_PORT_IN_TRANSFER_LIST`
3316
3317<!-- YAML
3318removed: v15.0.0
3319-->
3320
3321This error code was replaced by [`ERR_MISSING_TRANSFERABLE_IN_TRANSFER_LIST`][]
3322in Node.js v15.0.0, because it is no longer accurate as other types of
3323transferable objects also exist now.
3324
3325<a id="ERR_NAPI_CONS_PROTOTYPE_OBJECT"></a>
3326
3327### `ERR_NAPI_CONS_PROTOTYPE_OBJECT`
3328
3329<!-- YAML
3330added: v9.0.0
3331removed: v10.0.0
3332-->
3333
3334Used by the `Node-API` when `Constructor.prototype` is not an object.
3335
3336<a id="ERR_NETWORK_IMPORT_BAD_RESPONSE"></a>
3337
3338### `ERR_NETWORK_IMPORT_BAD_RESPONSE`
3339
3340> Stability: 1 - Experimental
3341
3342Response was received but was invalid when importing a module over the network.
3343
3344<a id="ERR_NETWORK_IMPORT_DISALLOWED"></a>
3345
3346### `ERR_NETWORK_IMPORT_DISALLOWED`
3347
3348> Stability: 1 - Experimental
3349
3350A network module attempted to load another module that it is not allowed to
3351load. Likely this restriction is for security reasons.
3352
3353<a id="ERR_NO_LONGER_SUPPORTED"></a>
3354
3355### `ERR_NO_LONGER_SUPPORTED`
3356
3357A Node.js API was called in an unsupported manner, such as
3358`Buffer.write(string, encoding, offset[, length])`.
3359
3360<a id="ERR_OPERATION_FAILED"></a>
3361
3362### `ERR_OPERATION_FAILED`
3363
3364<!-- YAML
3365added: v15.0.0
3366-->
3367
3368An operation failed. This is typically used to signal the general failure
3369of an asynchronous operation.
3370
3371<a id="ERR_OUTOFMEMORY"></a>
3372
3373### `ERR_OUTOFMEMORY`
3374
3375<!-- YAML
3376added: v9.0.0
3377removed: v10.0.0
3378-->
3379
3380Used generically to identify that an operation caused an out of memory
3381condition.
3382
3383<a id="ERR_PARSE_HISTORY_DATA"></a>
3384
3385### `ERR_PARSE_HISTORY_DATA`
3386
3387<!-- YAML
3388added: v9.0.0
3389removed: v10.0.0
3390-->
3391
3392The `node:repl` module was unable to parse data from the REPL history file.
3393
3394<a id="ERR_SOCKET_CANNOT_SEND"></a>
3395
3396### `ERR_SOCKET_CANNOT_SEND`
3397
3398<!-- YAML
3399added: v9.0.0
3400removed: v14.0.0
3401-->
3402
3403Data could not be sent on a socket.
3404
3405<a id="ERR_STDERR_CLOSE"></a>
3406
3407### `ERR_STDERR_CLOSE`
3408
3409<!-- YAML
3410removed: v10.12.0
3411changes:
3412  - version: v10.12.0
3413    pr-url: https://github.com/nodejs/node/pull/23053
3414    description: Rather than emitting an error, `process.stderr.end()` now
3415                 only closes the stream side but not the underlying resource,
3416                 making this error obsolete.
3417-->
3418
3419An attempt was made to close the `process.stderr` stream. By design, Node.js
3420does not allow `stdout` or `stderr` streams to be closed by user code.
3421
3422<a id="ERR_STDOUT_CLOSE"></a>
3423
3424### `ERR_STDOUT_CLOSE`
3425
3426<!-- YAML
3427removed: v10.12.0
3428changes:
3429  - version: v10.12.0
3430    pr-url: https://github.com/nodejs/node/pull/23053
3431    description: Rather than emitting an error, `process.stderr.end()` now
3432                 only closes the stream side but not the underlying resource,
3433                 making this error obsolete.
3434-->
3435
3436An attempt was made to close the `process.stdout` stream. By design, Node.js
3437does not allow `stdout` or `stderr` streams to be closed by user code.
3438
3439<a id="ERR_STREAM_READ_NOT_IMPLEMENTED"></a>
3440
3441### `ERR_STREAM_READ_NOT_IMPLEMENTED`
3442
3443<!-- YAML
3444added: v9.0.0
3445removed: v10.0.0
3446-->
3447
3448Used when an attempt is made to use a readable stream that has not implemented
3449[`readable._read()`][].
3450
3451<a id="ERR_TLS_RENEGOTIATION_FAILED"></a>
3452
3453### `ERR_TLS_RENEGOTIATION_FAILED`
3454
3455<!-- YAML
3456added: v9.0.0
3457removed: v10.0.0
3458-->
3459
3460Used when a TLS renegotiation request has failed in a non-specific way.
3461
3462<a id="ERR_TRANSFERRING_EXTERNALIZED_SHAREDARRAYBUFFER"></a>
3463
3464### `ERR_TRANSFERRING_EXTERNALIZED_SHAREDARRAYBUFFER`
3465
3466<!-- YAML
3467added: v10.5.0
3468removed: v14.0.0
3469-->
3470
3471A `SharedArrayBuffer` whose memory is not managed by the JavaScript engine
3472or by Node.js was encountered during serialization. Such a `SharedArrayBuffer`
3473cannot be serialized.
3474
3475This can only happen when native addons create `SharedArrayBuffer`s in
3476"externalized" mode, or put existing `SharedArrayBuffer` into externalized mode.
3477
3478<a id="ERR_UNKNOWN_STDIN_TYPE"></a>
3479
3480### `ERR_UNKNOWN_STDIN_TYPE`
3481
3482<!-- YAML
3483added: v8.0.0
3484removed: v11.7.0
3485-->
3486
3487An attempt was made to launch a Node.js process with an unknown `stdin` file
3488type. This error is usually an indication of a bug within Node.js itself,
3489although it is possible for user code to trigger it.
3490
3491<a id="ERR_UNKNOWN_STREAM_TYPE"></a>
3492
3493### `ERR_UNKNOWN_STREAM_TYPE`
3494
3495<!-- YAML
3496added: v8.0.0
3497removed: v11.7.0
3498-->
3499
3500An attempt was made to launch a Node.js process with an unknown `stdout` or
3501`stderr` file type. This error is usually an indication of a bug within Node.js
3502itself, although it is possible for user code to trigger it.
3503
3504<a id="ERR_V8BREAKITERATOR"></a>
3505
3506### `ERR_V8BREAKITERATOR`
3507
3508The V8 `BreakIterator` API was used but the full ICU data set is not installed.
3509
3510<a id="ERR_VALUE_OUT_OF_RANGE"></a>
3511
3512### `ERR_VALUE_OUT_OF_RANGE`
3513
3514<!-- YAML
3515added: v9.0.0
3516removed: v10.0.0
3517-->
3518
3519Used when a given value is out of the accepted range.
3520
3521<a id="ERR_VM_MODULE_NOT_LINKED"></a>
3522
3523### `ERR_VM_MODULE_NOT_LINKED`
3524
3525The module must be successfully linked before instantiation.
3526
3527<a id="ERR_VM_MODULE_LINKING_ERRORED"></a>
3528
3529### `ERR_VM_MODULE_LINKING_ERRORED`
3530
3531<!-- YAML
3532added: v10.0.0
3533removed: v18.1.0
3534-->
3535
3536The linker function returned a module for which linking has failed.
3537
3538<a id="ERR_WORKER_UNSUPPORTED_EXTENSION"></a>
3539
3540### `ERR_WORKER_UNSUPPORTED_EXTENSION`
3541
3542<!-- YAML
3543added: v11.0.0
3544removed: v16.9.0
3545-->
3546
3547The pathname used for the main script of a worker has an
3548unknown file extension.
3549
3550<a id="ERR_ZLIB_BINDING_CLOSED"></a>
3551
3552### `ERR_ZLIB_BINDING_CLOSED`
3553
3554<!-- YAML
3555added: v9.0.0
3556removed: v10.0.0
3557-->
3558
3559Used when an attempt is made to use a `zlib` object after it has already been
3560closed.
3561
3562<a id="ERR_CPU_USAGE"></a>
3563
3564### `ERR_CPU_USAGE`
3565
3566<!-- YAML
3567removed: v15.0.0
3568-->
3569
3570The native call from `process.cpuUsage` could not be processed.
3571
3572[ES Module]: esm.md
3573[ICU]: intl.md#internationalization-support
3574[JSON Web Key Elliptic Curve Registry]: https://www.iana.org/assignments/jose/jose.xhtml#web-key-elliptic-curve
3575[JSON Web Key Types Registry]: https://www.iana.org/assignments/jose/jose.xhtml#web-key-types
3576[Node.js error codes]: #nodejs-error-codes
3577[RFC 7230 Section 3]: https://tools.ietf.org/html/rfc7230#section-3
3578[Subresource Integrity specification]: https://www.w3.org/TR/SRI/#the-integrity-attribute
3579[V8's stack trace API]: https://v8.dev/docs/stack-trace-api
3580[WHATWG Supported Encodings]: util.md#whatwg-supported-encodings
3581[WHATWG URL API]: url.md#the-whatwg-url-api
3582[`"exports"`]: packages.md#exports
3583[`"imports"`]: packages.md#imports
3584[`'uncaughtException'`]: process.md#event-uncaughtexception
3585[`--disable-proto=throw`]: cli.md#--disable-protomode
3586[`--force-fips`]: cli.md#--force-fips
3587[`--no-addons`]: cli.md#--no-addons
3588[`--unhandled-rejections`]: cli.md#--unhandled-rejectionsmode
3589[`Class: assert.AssertionError`]: assert.md#class-assertassertionerror
3590[`ERR_INVALID_ARG_TYPE`]: #err_invalid_arg_type
3591[`ERR_MISSING_MESSAGE_PORT_IN_TRANSFER_LIST`]: #err_missing_message_port_in_transfer_list
3592[`ERR_MISSING_TRANSFERABLE_IN_TRANSFER_LIST`]: #err_missing_transferable_in_transfer_list
3593[`EventEmitter`]: events.md#class-eventemitter
3594[`MessagePort`]: worker_threads.md#class-messageport
3595[`Object.getPrototypeOf`]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/getPrototypeOf
3596[`Object.setPrototypeOf`]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/setPrototypeOf
3597[`REPL`]: repl.md
3598[`ServerResponse`]: http.md#class-httpserverresponse
3599[`Writable`]: stream.md#class-streamwritable
3600[`child_process`]: child_process.md
3601[`cipher.getAuthTag()`]: crypto.md#ciphergetauthtag
3602[`crypto.getDiffieHellman()`]: crypto.md#cryptogetdiffiehellmangroupname
3603[`crypto.scrypt()`]: crypto.md#cryptoscryptpassword-salt-keylen-options-callback
3604[`crypto.scryptSync()`]: crypto.md#cryptoscryptsyncpassword-salt-keylen-options
3605[`crypto.timingSafeEqual()`]: crypto.md#cryptotimingsafeequala-b
3606[`dgram.connect()`]: dgram.md#socketconnectport-address-callback
3607[`dgram.createSocket()`]: dgram.md#dgramcreatesocketoptions-callback
3608[`dgram.disconnect()`]: dgram.md#socketdisconnect
3609[`dgram.remoteAddress()`]: dgram.md#socketremoteaddress
3610[`errno`(3) man page]: https://man7.org/linux/man-pages/man3/errno.3.html
3611[`fs.Dir`]: fs.md#class-fsdir
3612[`fs.cp()`]: fs.md#fscpsrc-dest-options-callback
3613[`fs.readFileSync`]: fs.md#fsreadfilesyncpath-options
3614[`fs.readdir`]: fs.md#fsreaddirpath-options-callback
3615[`fs.symlink()`]: fs.md#fssymlinktarget-path-type-callback
3616[`fs.symlinkSync()`]: fs.md#fssymlinksynctarget-path-type
3617[`fs.unlink`]: fs.md#fsunlinkpath-callback
3618[`fs`]: fs.md
3619[`hash.digest()`]: crypto.md#hashdigestencoding
3620[`hash.update()`]: crypto.md#hashupdatedata-inputencoding
3621[`http`]: http.md
3622[`https`]: https.md
3623[`libuv Error handling`]: https://docs.libuv.org/en/v1.x/errors.html
3624[`net.Socket.write()`]: net.md#socketwritedata-encoding-callback
3625[`net`]: net.md
3626[`new URL(input)`]: url.md#new-urlinput-base
3627[`new URLSearchParams(iterable)`]: url.md#new-urlsearchparamsiterable
3628[`package.json`]: packages.md#nodejs-packagejson-field-definitions
3629[`postMessage()`]: worker_threads.md#portpostmessagevalue-transferlist
3630[`process.on('exit')`]: process.md#event-exit
3631[`process.send()`]: process.md#processsendmessage-sendhandle-options-callback
3632[`process.setUncaughtExceptionCaptureCallback()`]: process.md#processsetuncaughtexceptioncapturecallbackfn
3633[`readable._read()`]: stream.md#readable_readsize
3634[`require('node:crypto').setEngine()`]: crypto.md#cryptosetengineengine-flags
3635[`require()`]: modules.md#requireid
3636[`server.close()`]: net.md#serverclosecallback
3637[`server.listen()`]: net.md#serverlisten
3638[`sign.sign()`]: crypto.md#signsignprivatekey-outputencoding
3639[`stream.pipe()`]: stream.md#readablepipedestination-options
3640[`stream.push()`]: stream.md#readablepushchunk-encoding
3641[`stream.unshift()`]: stream.md#readableunshiftchunk-encoding
3642[`stream.write()`]: stream.md#writablewritechunk-encoding-callback
3643[`subprocess.kill()`]: child_process.md#subprocesskillsignal
3644[`subprocess.send()`]: child_process.md#subprocesssendmessage-sendhandle-options-callback
3645[`url.parse()`]: url.md#urlparseurlstring-parsequerystring-slashesdenotehost
3646[`util.getSystemErrorName(error.errno)`]: util.md#utilgetsystemerrornameerr
3647[`util.inspect()`]: util.md#utilinspectobject-options
3648[`util.parseArgs()`]: util.md#utilparseargsconfig
3649[`v8.startupSnapshot.setDeserializeMainFunction()`]: v8.md#v8startupsnapshotsetdeserializemainfunctioncallback-data
3650[`zlib`]: zlib.md
3651[crypto digest algorithm]: crypto.md#cryptogethashes
3652[debugger]: debugger.md
3653[define a custom subpath]: packages.md#subpath-exports
3654[domains]: domain.md
3655[event emitter-based]: events.md#class-eventemitter
3656[file descriptors]: https://en.wikipedia.org/wiki/File_descriptor
3657[policy]: permissions.md#policies
3658[self-reference a package using its name]: packages.md#self-referencing-a-package-using-its-name
3659[stream-based]: stream.md
3660[syscall]: https://man7.org/linux/man-pages/man2/syscalls.2.html
3661[try-catch]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/try...catch
3662[vm]: vm.md
3663