Giovanny Andres Gongora Granada (Gioyik)
4e084addcd
errors: fix ERR_SOCKET_BAD_PORT message
...
The current message says 'Port should be > 0' meaning '0' is an
invalid value. You can pass '0' to get a random port from the system.
The correct message for this error is 'Port should be >= 0'.
PR-URL: https://github.com/nodejs/node/pull/23015
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Rod Vagg <rod@vagg.org >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-09-25 19:33:14 +03:00
Anna Henningsen
0227635315
cli: normalize _ → - when parsing options
...
This allows for option syntax similar to V8’s one, e.g.
`--no_warnings` has the same effect as `--no-warnings`.
PR-URL: https://github.com/nodejs/node/pull/23020
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Gus Caplan <me@gus.host >
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-09-25 13:32:30 +02:00
Ruben Bridgewater
5605cec0db
process: add multipleResolves event
...
This adds the `multipleResolves` event to track promises that resolve
more than once or that reject after resolving.
It is important to expose this to the user to make sure the
application runs as expected. Without such warnings it would be very
hard to debug these situations.
PR-URL: https://github.com/nodejs/node/pull/22218
Fixes: https://github.com/nodejs/promises-debugging/issues/8
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com >
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com >
2018-09-25 10:04:09 +02:00
Lars-Magnus Skog
357aeaad62
doc: fix optional parameters in n-api.md
...
The thread_finalize_data and thread_finalize_cb parameters in
napi_create_threadsafe_function are optional.
PR-URL: https://github.com/nodejs/node/pull/22998
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2018-09-24 23:10:18 +02:00
Denis Fäcke
ab6ddc0634
doc: add callback parameters of worker.terminate()
...
PR-URL: https://github.com/nodejs/node/pull/23002
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2018-09-24 23:15:54 +03:00
Anna Henningsen
a5b92a7bb4
doc: remove outdated notes on stdio in workers
...
Workers support `stdio` streams since the initial PR landed. These
lines are editing leftovers from before that and should be removed.
PR-URL: https://github.com/nodejs/node/pull/23054
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-09-24 18:42:00 +02:00
Tobias Nießen
4da11f2dc5
tls: fix DEP0083 after upgrading to OpenSSL 1.1.0
...
Setting ecdhCurve to false is already unsupported, so the deprecation
should already be EOL. The test was skipped ever since we upgraded to
OpenSSL 1.1.0.
PR-URL: https://github.com/nodejs/node/pull/22953
Refs: https://github.com/nodejs/node/pull/16130
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2018-09-24 07:26:08 +02:00
Andreas Haas
7dde560beb
src: replace deprecated uses of FunctionTemplate::GetFunction
...
PR-URL: https://github.com/nodejs/node/pull/22993
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Eugene Ostroukhov <eostroukhov@google.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-09-24 05:44:28 +02:00
James M Snell
a0c1326257
http2: add ping event
...
Add a `Http2Session` event whenever a non-ack `PING` is received.
Fixes: https://github.com/nodejs/node/issues/18514
PR-URL: https://github.com/nodejs/node/pull/23009
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com >
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com >
Reviewed-By: Denys Otrishko <shishugi@gmail.com >
2018-09-23 16:36:24 -07:00
Gus Caplan
de0441f6f6
lib: implement queueMicrotask
...
PR-URL: https://github.com/nodejs/node/pull/22951
Refs: https://html.spec.whatwg.org/multipage/timers-and-user-prompts.html#dom-queuemicrotask
Reviewed-By: Bradley Farias <bradley.meck@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2018-09-23 15:57:19 -05:00
Michaël Zasso
e758d4ab0a
doc,test: fix inspect's sorted compare function
...
In V8 7.0, the array sorting algorithm was changed to Timsort, which
is stable. A compare function returning only `true` or `false`
(converted to 0 and 1) cannot work properly.
PR-URL: https://github.com/nodejs/node/pull/22992
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Kyle Farnung <kfarnung@microsoft.com >
2018-09-22 14:29:37 +02:00
Alexander Mills
1f4d4c0da8
tty: make readStream.setRawMode() return this
...
PR-URL: https://github.com/nodejs/node/pull/22950
Fixes: https://github.com/nodejs/node/issues/22916
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Denys Otrishko <shishugi@gmail.com >
2018-09-22 11:19:26 +03:00
Mohammed Essehemy
5942a3447a
doc: match program and console output in synopsis.md
...
PR-URL: https://github.com/nodejs/node/pull/23006
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-09-22 00:49:25 +03:00
Rich Trott
363570c07d
doc: add links for repl.ReplServer
...
Add links to the class definition for repl.ReplServer in places where it
would be helpful.
PR-URL: https://github.com/nodejs/node/pull/23005
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-09-21 14:14:31 -07:00
James M Snell
b92ce5165f
http2: add origin frame support
...
PR-URL: https://github.com/nodejs/node/pull/22956
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2018-09-21 13:23:08 -07:00
Tobias Nießen
058c5b81cd
crypto: do not allow multiple calls to setAuthTag
...
Calling setAuthTag multiple times can result in hard to detect bugs
since to the user, it is unclear which invocation actually affected
OpenSSL.
PR-URL: https://github.com/nodejs/node/pull/22931
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com >
2018-09-21 11:40:35 +02:00
Daniel Bevenius
56493bf1eb
tools: add bash completion for node
...
This commit adds a --completion-bash option to node which can be
sourced to provide bash code completion for node options.
Usage:
$ node --completion-bash > node_bash_completion
$ source node_bash_completion
$ node --[tab]
PR-URL: https://github.com/nodejs/node/pull/20713
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Denys Otrishko <shishugi@gmail.com >
2018-09-21 07:18:24 +02:00
Tobias Nießen
085dcf0e59
crypto: allow promisifying generateKeyPair
...
PR-URL: https://github.com/nodejs/node/pull/22660
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
2018-09-20 14:31:18 +02:00
Tobias Nießen
8c502f54ce
crypto: add API for key pair generation
...
This adds support for RSA, DSA and EC key pair generation with a
variety of possible output formats etc.
PR-URL: https://github.com/nodejs/node/pull/22660
Fixes: https://github.com/nodejs/node/issues/15116
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
2018-09-20 14:31:14 +02:00
Michaël Zasso
df9abb638d
2018-09-20, Version 10.11.0 (Current)
...
Notable changes:
* fs
* Fixed fsPromises.readdir `withFileTypes`.
https://github.com/nodejs/node/pull/22832
* http2
* Added `http2stream.endAfterHeaders` property.
https://github.com/nodejs/node/pull/22843
* util
* Added `util.types.isBoxedPrimitive(value)`.
https://github.com/nodejs/node/pull/22620
* Added new collaborators:
* boneskull (https://github.com/boneskull ) - Christopher Hiller
* The Technical Steering Committee has new members:
* apapirovski (https://github.com/apapirovski ) - Anatoli Papirovski
* gabrielschulhof (https://github.com/gabrielschulhof ) - Gabriel Schulhof
PR-URL: https://github.com/nodejs/node/pull/22932
2018-09-20 13:32:38 +02:00
Tobias Nießen
fadafef4f4
doc: improve metadata for http.request
...
PR-URL: https://github.com/nodejs/node/pull/22949
Refs: https://github.com/nodejs/node/pull/21616
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-09-19 21:12:45 +02:00
Tobias Nießen
77152739fd
doc: add missing metadata for recursive mkdir
...
PR-URL: https://github.com/nodejs/node/pull/22949
Refs: https://github.com/nodejs/node/pull/21875
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-09-19 21:12:28 +02:00
Tobias Nießen
a02b98b0b5
doc: add missing metadata for dns.lookup
...
PR-URL: https://github.com/nodejs/node/pull/22949
Refs: https://github.com/nodejs/node/pull/14731
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-09-19 21:11:51 +02:00
Tobias Nießen
19ad6b8f72
crypto: deprecate digest == null in PBKDF2
...
I assume that permitting digest === null was unintentional when
digest === undefined was deprecated since their behavior was
equivalent. The sha1 default for digest === null has somehow made it
through refactoring of the PBKDF2 module multiple times, even though
digest === undefined has been EOL for some time now.
This change deprecates setting digest to null so we can fix the
behavior in Node.js 12 or so.
PR-URL: https://github.com/nodejs/node/pull/22861
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-09-19 18:31:28 +02:00
Ruben Bridgewater
b95b0d87c3
util: add order option to .inspect()
...
The order option can be used to sort the inspected values in case
they do not rely on their order as arrays. That way the output is
stable no matter of the object property inspection order.
PR-URL: https://github.com/nodejs/node/pull/22788
Refs: https://github.com/nodejs/node/issues/22763
Reviewed-By: John-David Dalton <john.david.dalton@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-09-19 13:22:32 +02:00
Bartosz Sosnowski
6e746f1a55
doc, win: improve os.setPriority documentation
...
PR-URL: https://github.com/nodejs/node/pull/22817
Fixes: https://github.com/nodejs/node/issues/22799
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2018-09-19 08:02:18 +02:00
isurusiri
a1381fab8a
doc: explain how to invoke gc
...
Currently the documentation for Wrapping C++ Objects doesn't explain
how to destruct an object by explicitly invoking the garbage collector.
This commit includes a modification to docs that explains how to force
the garbage collector to clear objects using V8's command line flags.
Fixes: https://github.com/nodejs/node/issues/19876
PR-URL: https://github.com/nodejs/node/pull/20431
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Yang Guo <yangguo@chromium.org >
2018-09-18 22:58:01 -07:00
MaleDong
ba0b4e43e4
lib,doc: remove unused parameter, improve docs
...
1) Remove 'callback' in 'check' function, because we don't check or use
that directly.
2) Make 'digest' clearer in the documentation.
PR-URL: https://github.com/nodejs/node/pull/22858
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-09-18 16:06:32 +02:00
Anna Henningsen
8989c76c6e
Revert "src: implement query callbacks for vm"
...
This reverts commit 85c356c10e
from PR https://github.com/nodejs/node/pull/22390 .
See the discussion in the (proposed) fix at
https://github.com/nodejs/node/pull/22836 .
Refs: https://github.com/nodejs/node/pull/22836
Refs: https://github.com/nodejs/node/pull/22390
Fixes: https://github.com/nodejs/node/issues/22723
PR-URL: https://github.com/nodejs/node/pull/22911
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Gus Caplan <me@gus.host >
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com >
Reviewed-By: John-David Dalton <john.david.dalton@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2018-09-18 15:48:02 +02:00
Benjamin Chen
e2325bcc04
string_decoder: support typed array or data view
...
Refs: https://github.com/nodejs/node/issues/1826
PR-URL: https://github.com/nodejs/node/pull/22562
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-09-17 17:48:44 +02:00
Anna Henningsen
c33e27dc3c
doc: improve asymmetric crypto docs
...
Refs: https://github.com/nodejs/node/issues/22792
PR-URL: https://github.com/nodejs/node/pull/22820
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Minwoo Jung <minwoo@nodesource.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-09-17 17:15:14 +02:00
James M Snell
932be0164f
util: make TextEncoder/TextDecoder global
...
Fixes: https://github.com/nodejs/node/issues/20365
PR-URL: https://github.com/nodejs/node/pull/22281
Reviewed-By: Gus Caplan <me@gus.host >
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com >
2018-09-17 17:09:25 +02:00
James M Snell
efe0bbcd2f
http2: add http2stream.endAfterHeaders property
...
Indicates is the END_STREAM flag was set on the received HEADERS frame
PR-URL: https://github.com/nodejs/node/pull/22843
Fixes: https://github.com/nodejs/node/issues/22497
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2018-09-17 16:57:23 +02:00
Mohit kumar Bajoria
cb3d6d5113
doc: add missing options for crypto sign.sign()
...
Fixes: https://github.com/nodejs/node/issues/22813
PR-URL: https://github.com/nodejs/node/pull/22824
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
2018-09-17 14:49:20 +02:00
chocolateboy
dadd6e1688
util: use a shared symbol for util.inspect.custom
...
Define `util.inspect.custom` as
`Symbol.for("nodejs.util.inspect.custom")` rather than
`Symbol("util.inspect.custom")`. This allows `inspect` hooks to
easily/safely be defined in non-Node.js environments.
Fixes: https://github.com/nodejs/node/issues/20821
Refs: https://github.com/nodejs/node/pull/22684
PR-URL: https://github.com/nodejs/node/pull/20857
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com >
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: John-David Dalton <john.david.dalton@gmail.com >
2018-09-15 13:15:15 +02:00
Bryan English
de37ba34c5
doc: add withFileTypes option to fsPromises.readdir
...
PR-URL: https://github.com/nodejs/node/pull/22833
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-09-14 21:12:17 -07:00
Mohammed Essehemy
70c2ebc1a1
doc: fix typo in dns docs
...
PR-URL: https://github.com/nodejs/node/pull/22866
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
2018-09-14 20:52:36 +02:00
Gus Caplan
246f6332e5
module: add createRequireFunction method
...
PR-URL: https://github.com/nodejs/node/pull/19360
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Jan Krems <jan.krems@gmail.com >
Reviewed-By: Bradley Farias <bradley.meck@gmail.com >
Reviewed-By: John-David Dalton <john.david.dalton@gmail.com >
2018-09-14 11:34:17 -05:00
Sagi Tsofan
19c0620dd6
doc: document http2 timeouts
...
New default timeout values of "2 minutes" were added into documentation
inside 2 classes under "Event: 'timeout'":
1) Class: Http2SecureServer
2) Class: Http2Server
New sections for `.setTimeout()` method were added inside
`Http2SecureServer` & `Http2Server` docs.
PR-URL: https://github.com/nodejs/node/pull/22798
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-09-13 18:39:55 +03:00
Ruben Bridgewater
eb61127c48
util: limit inspection output size to 128 MB
...
The maximum hard limit that `util.inspect()` could theoretically handle
is the maximum string size. That is ~2 ** 28 on 32 bit systems and
~2 ** 30 on 64 bit systems.
Due to the recursive algorithm a complex object could easily exceed
that limit without throwing an error right away and therefore
crashing the application by exceeding the heap limit.
`util.inspect()` is fast enough to compute 128 MB of data below one
second on an Intel(R) Core(TM) i7-5600U CPU. This hard limit allows
to inspect arbitrary big objects from now on without crashing the
application or blocking the event loop significantly.
PR-URL: https://github.com/nodejs/node/pull/22756
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: John-David Dalton <john.david.dalton@gmail.com >
2018-09-13 10:49:04 +02:00
Gabriel Schulhof
cf0e881b33
n-api: add generic finalizer callback
...
Add `napi_add_finalizer()`, which provides the ability to attach data
to an arbitrary object and be notified when that object is garbage-
collected so as to have an opportunity to delete the data previously
attached.
This differs from `napi_wrap()` in that it does not use up the private
slot on the object, and is therefore neither removable, nor retrievable
after the call to `napi_add_finalizer()`. It is assumed that the data
is accessible by other means, yet it must be tied to the lifetime of
the object. This is the case for data passed to a dynamically created
function which is itself heap-allocated and must therefore be freed
along with the function.
Fixes: https://github.com/nodejs/abi-stable-node/issues/313
PR-URL: https://github.com/nodejs/node/pull/22244
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
2018-09-12 22:37:42 -04:00
Tobias Nießen
360465dfe2
crypto: assign missing deprecation code
...
PR-URL: https://github.com/nodejs/node/pull/22827
Refs: https://github.com/nodejs/node/pull/22747
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-09-13 01:08:59 +02:00
Tobias Nießen
0ade10df79
crypto: hide native handles from JS modules
...
PR-URL: https://github.com/nodejs/node/pull/22747
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Vladimir de Turckheim <vlad2t@hotmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2018-09-12 22:20:27 +02:00
Tien Do
2c43da8347
doc: add history for withFileTypes in fs.readdir[Sync]()
...
PR-URL: https://github.com/nodejs/node/pull/22794
Fixes: https://github.com/nodejs/node/issues/22777
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2018-09-12 22:14:49 +03:00
Anna Henningsen
93925353f8
doc: node debug → node inspect in CLI docs
...
PR-URL: https://github.com/nodejs/node/pull/22774
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: Matheus Marchini <mat@mmarchini.me >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Jan Krems <jan.krems@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: George Adams <george.adams@uk.ibm.com >
2018-09-12 13:08:46 +02:00
Tobias Nießen
ed130d2e2c
doc: add full deprecation history
...
I tried to manually reconstruct the history of deprecations and to
track them down to their origins. Having these documented publicly
makes it much easier to find out when deprecations were introduced
or changed.
PR-URL: https://github.com/nodejs/node/pull/22766
Reviewed-By: Gus Caplan <me@gus.host >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-09-12 11:47:12 +02:00
Tobias Nießen
67ba8ff31a
doc: fix type of DEP0116
...
PR-URL: https://github.com/nodejs/node/pull/22765
Refs: https://github.com/nodejs/node/pull/22715
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2018-09-08 21:30:20 -07:00
Tobias Nießen
9f06a05795
doc: fix description of DEP0024
...
PR-URL: https://github.com/nodejs/node/pull/22755
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-09-08 16:29:21 +02:00
James M Snell
922a1b03b6
url: docs deprecate legacy url API
...
PR-URL: https://github.com/nodejs/node/pull/22715
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Gus Caplan <me@gus.host >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2018-09-07 16:55:44 -07:00
Ruben Bridgewater
c1483bac94
doc: improve assert documentation
...
This fixes the officially accepted message types for `assert.throws()`,
`assert.rejects()`, `assert.doesNotThrow()` and
`assert.doesNotReject()`. It also renames the `block` argument in
those functions to `fn` and `promiseFn` for further clarity.
PR-URL: https://github.com/nodejs/node/pull/22692
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: George Adams <george.adams@uk.ibm.com >
2018-09-07 22:42:08 +01:00