0
0
mirror of https://github.com/nodejs/node.git synced 2024-12-01 16:10:02 +01:00
Commit Graph

20537 Commits

Author SHA1 Message Date
Gibson Fahnestock
ecf6e79362
doc: remove x86 from os.arch() options
It is not possible for `process.arch` (which comes from V8's
`target_arch`) to be `x86`.

Also updates `process.arch` to have the same information.

PR-URL: https://github.com/nodejs/node/pull/17899
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
2018-01-03 23:31:34 +00:00
James M Snell
2f6d1001c8 doc: add docs for common/http2.js utility
PR-URL: https://github.com/nodejs/node/pull/17942
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2018-01-03 14:46:03 -08:00
James M Snell
651ce28be9 http2: properly handle already closed stream error
PR-URL: https://github.com/nodejs/node/pull/17942
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2018-01-03 14:45:57 -08:00
James M Snell
efdadcc193 http2: add aligned padding strategy
Add a padding strategy option that makes a best attempt to ensure
that total frame length for DATA and HEADERS frames are aligned
on multiples of 8-bytes.

PR-URL: https://github.com/nodejs/node/pull/17938
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2018-01-03 12:57:18 -08:00
James M Snell
060babd665 http2: add initial support for originSet
Add new properties to `Http2Session` to identify alpnProtocol,
and indicator about whether the session is TLS or not, and
initial support for origin set (preparinng for `ORIGIN` frame
support and the client-side `Pool` implementation.

The `originSet` is the set of origins for which an `Http2Session`
may be considered authoritative. Per the `ORIGIN` frame spec,
the originSet is only valid on TLS connections, so this is only
exposed when using a `TLSSocket`.

PR-URL: https://github.com/nodejs/node/pull/17935
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Sebastiaan Deckers <sebdeckers83@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
2018-01-03 11:29:43 -08:00
James M Snell
b25b1efa0a tls: set servername on client side too
PR-URL: https://github.com/nodejs/node/pull/17935
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Sebastiaan Deckers <sebdeckers83@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
2018-01-03 11:29:39 -08:00
Benjamin Zaslavsky
30892c8fb4
test: fix require-deps-deprecation for installed deps
Test test-require-deps-deprecation.js was failing when user already had
node installed with acorn in require.resolve range.

Modified test to acknowledge the possibility and throw only if acorn is
found in the deps directory.

PR-URL: https://github.com/nodejs/node/pull/17848
Fixes: https://github.com/nodejs/node/issues/17148
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-01-03 13:59:52 -05:00
Rich Trott
e6a401e0ae
doc: improve PR-review paragraph in CONTRIBUTING.md
* Remove redundant "blocking it or stopping it" as blocking and stopping
  are the same thing in this case.
* Make another sentence less wordy. Fix incorrect verb conjugation.
  Break into two clear sentences.

PR-URL: https://github.com/nodejs/node/pull/17931
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
2018-01-03 13:47:58 -05:00
Rich Trott
5bda05548b
doc: fix typos in CONTRIBUTING.md
Remove incorrect usage of "in which". The sentence is better and shorter
without it anyway. Replace incorrect "with" with "in".

PR-URL: https://github.com/nodejs/node/pull/17930
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Weijia Wang <starkwang@126.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Yuta Hiroto <hello@about-hiroppy.com>
2018-01-03 13:46:20 -05:00
Tobias Nießen
3b1e263b7b
readline: update references to archived repository
PR-URL: https://github.com/nodejs/node/pull/17924
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-01-03 18:22:52 +01:00
Tobias Nießen
8951fcff2b
test: update references to archived repository
PR-URL: https://github.com/nodejs/node/pull/17924
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-01-03 18:22:48 +01:00
James M Snell
ce22d6f917 http2: add altsvc support
Add support for sending and receiving ALTSVC frames.

PR-URL: https://github.com/nodejs/node/pull/17917
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2018-01-03 08:45:58 -08:00
Rich Trott
f51067a85d doc: remove non-style information from style guide
While tools should be used insofar as possible, that information
does not belong in the style guide. Move to onboarding doc.

PR-URL: https://github.com/nodejs/node/pull/17866
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Khaidi Chu <i@2333.moe>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-01-02 21:33:32 -08:00
Rich Trott
f05fb0104a build: remove duplicate async-hooks and known_issues test runs
The `default` test suite in `test.py` includes `async-hooks` and
`known_issues`. Our current setup results in those test suites being run
twice during each CI run. Remove the duplication.

PR-URL: https://github.com/nodejs/node/pull/17912
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-01-02 20:50:14 -08:00
Gibson Fahnestock
ec9fb6dd53
2018-01-02 Node.js v8.9.4 'Carbon' (LTS) Release
PR-URL: https://github.com/nodejs/node/pull/17774

Notable Changes:

* deps:
  * upgrade npm to 5.6.0 (Kat Marchán) [#17535](https://github.com/nodejs/node/pull/17535)
* build:
  * configure can now be run from any directory (Gibson Fahnestock) [#17321](https://github.com/nodejs/node/pull/17321)
2018-01-03 04:19:17 +00:00
Rich Trott
5dbd77eb83 doc: copy-edit COLLABORATOR_GUIDE.md
Apply various style and punctuation fixes.

PR-URL: https://github.com/nodejs/node/pull/17922
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-01-02 18:14:48 -05:00
Rich Trott
525b6dd0be doc: improve alt text
Current alt text results in "GitHub badge badge". Change to intended use
of alt text so that it reads "GitHub First-time contributor badge". (The
alt text is supposed to replace the image in the event that the image
cannot be rendered.)

PR-URL: https://github.com/nodejs/node/pull/17922
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-01-02 18:14:42 -05:00
Rich Trott
dd7c2b77a3 doc: fix spelling of contributors
Change instances of "contributiors" to "contributors".

PR-URL: https://github.com/nodejs/node/pull/17922
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-01-02 18:14:34 -05:00
James M Snell
653e894883 http2: strictly limit number on concurrent streams
Strictly limit the number of concurrent streams based on the
current setting of the MAX_CONCURRENT_STREAMS setting

PR-URL: https://github.com/nodejs/node/pull/16766
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Sebastiaan Deckers <sebdeckers83@gmail.com>
2018-01-02 14:56:30 -08:00
Salame William
d179ccac92 doc: add references to PR communication articles
Added some references to PR communication articles in
Helpful Ressources inside COLLABORATOR_GUIDE.md

PR-URL: https://github.com/nodejs/node/pull/17902
Fixes: https://github.com/nodejs/node/issues/16359
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Weijia Wang <starkwang@126.com>
2018-01-03 00:31:17 +02:00
Myles Borins
02e4c8d981
2018-01-02, Version 6.12.3 'Boron' (LTS)
Notable Changes:

* build:
  - configure can now be run from any directory (Gibson Fahnestock)
    https://github.com/nodejs/node/pull/17321

PR-URL: https://github.com/nodejs/node/pull/17776
2018-01-02 14:09:57 -05:00
James M Snell
231b1166cf http2: perf_hooks integration
Collect and report basic timing information about `Http2Session`
and `Http2Stream` instances.

PR-URL: https://github.com/nodejs/node/pull/17906
Refs: https://github.com/nodejs/node/issues/17746
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2018-01-02 08:56:30 -08:00
Anatoli Papirovski
54062d30cf
timers: refactor setImmediate error handling
If an error is encountered during the processing of Immediates, schedule
the remaining queue to finish after all error handling code runs (if the
process is still alive to do so). The new changes make the Immediates
error handling behaviour entirely deterministic and predictable, as the
full queue will be flushed on each Immediates cycle, regardless of
whether an error is encountered or not.

Currently this processing is scheduled for nextTick which can yield
unpredictable results as the nextTick might happen as early as close
callbacks phase or as late as after the next event loop turns Immediates
all fully processed. The latter can result in two full cycles of
Immediates processing during one even loop turn.

The current implementation also doesn't differentiate between Immediates
scheduled for the current queue run or the next one, so Immediates that
were scheduled for the next turn of the event loop, will process
alongside the ones that were scheduled for the current turn.

PR-URL: https://github.com/nodejs/node/pull/17879
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-01-02 11:16:33 -05:00
Vse Mozhet Byt
11a1bc1136 doc: replace wrong U+00A0 by common spaces
PR-URL: https://github.com/nodejs/node/pull/17940
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
2018-01-02 01:58:15 +02:00
Tobias Nießen
47ee340a9e
http2: remove duplicate words in comments
PR-URL: https://github.com/nodejs/node/pull/17939
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-01-02 00:32:58 +01:00
Tobias Nießen
93acfe55db
src: remove duplicate words in comments
PR-URL: https://github.com/nodejs/node/pull/17939
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-01-02 00:31:03 +01:00
Tobias Nießen
d74a1ed7d9
doc: remove duplicate words in API docs
PR-URL: https://github.com/nodejs/node/pull/17937
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
2018-01-02 00:13:02 +01:00
Tobias Nießen
d67e71e4f7
test: improve readability of some crypto tests
PR-URL: https://github.com/nodejs/node/pull/17904
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Weijia Wang <starkwang@126.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
2018-01-01 18:19:12 +01:00
sreepurnajasti
b21e3f0711
doc: fix duplicate words & spellings in docs
PR-URL: https://github.com/nodejs/node/pull/17923
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
2017-12-31 18:14:25 +01:00
Tobias Nießen
1fa4f5df3a
gitignore: ignore *.VC.db files
PR-URL: https://github.com/nodejs/node/pull/17898
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Bartosz Sosnowski <bartosz@janeasystems.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2017-12-31 14:07:08 +01:00
Anatoli Papirovski
5846786424
src: use AliasedBuffer for TickInfo
PR-URL: https://github.com/nodejs/node/pull/17881
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Khaidi Chu <i@2333.moe>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2017-12-30 19:05:58 -05:00
Anatoli Papirovski
2c94424a0d
timers: remove domain enter and exit
With domains implemented over AsyncHooks, it's no longer
necessary to explicitly enter and exit the domain.

PR-URL: https://github.com/nodejs/node/pull/17880
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Andreas Madsen <amwebdk@gmail.com>
2017-12-30 18:58:43 -05:00
James M Snell
cfca536d8f deps: update nghttp2 to 1.29.0
PR-URL: https://github.com/nodejs/node/pull/17908
Refs: https://github.com/nodejs/node/issues/17746
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2017-12-30 10:02:40 -08:00
sreepurnajasti
27470e4ec7
doc: correct spelling
PR-URL: https://github.com/nodejs/node/pull/17911
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Weijia Wang <starkwang@126.com>
2017-12-30 17:59:05 +01:00
sreepurnajasti
166a2ceeb7 test: use countdown in test file
Fixes: https://github.com/nodejs/node/issues/17169

PR-URL: https://github.com/nodejs/node/pull/17874
Fixes: https://github.com/nodejs/node/issues/17169
Reviewed-By: Weijia Wang <starkwang@126.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2017-12-30 18:31:56 +08:00
Tobias Nießen
a82b1b7b30
errors: remove ERR_OUTOFMEMORY
PR-URL: https://github.com/nodejs/node/pull/17877
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>
2017-12-29 21:16:14 +01:00
Daniel Bevenius
4117e22cf3 test: fix repl-tab-complete --without-ssl
Currently, when configured --without-ssl test-repl-tab-complete fails
with the following error:

assert.js:43
  throw new errors.AssertionError(obj);
  ^

AssertionError [ERR_ASSERTION]: [ [], 'lexicalL' ] deepStrictEqual []
    at testRepl.complete.common.mustCall
      (node/test/parallel/test-repl-tab-complete.js:549:14)
    at /node/test/common/index.js:530:15
    at completionGroupsLoaded (repl.js:1204:5)
    at REPLServer.complete (repl.js:1090:11)
    at REPLServer.completer (repl.js:450:14)
    at REPLServer.complete (repl.js:919:18)
    at __dirname.forEach (parallel/test-repl-tab-complete.js:548:14)
    at Array.forEach (<anonymous>)
    at Object.<anonymous> (parallel/test-repl-tab-complete.js:545:29)
    at Module._compile (module.js:660:30)

This commit attempts to fix this test but I'm not sure if this is a
proper fix as I'm not familiar with the repl code base yet.

PR-URL: https://github.com/nodejs/node/pull/17867
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2017-12-29 06:09:57 +01:00
Daniel Bevenius
6fc9c331c6 test: add hasCrypto when using binding('crypto')
Currently, when configured --without-ssl tests that use
process.binding('crypto') fail with the following error:

=== release test-accessor-properties ===
Path: parallel/test-accessor-properties
node/test/parallel/test-accessor-properties.js:16
const crypto = process.binding('crypto');
                       ^

Error: No such module: crypto
    at Object.<anonymous> (test-accessor-properties.js:16:24)
    at Module._compile (module.js:660:30)
    at Object.Module._extensions..js (module.js:671:10)
    at Module.load (module.js:577:32)
    at tryModuleLoad (module.js:517:12)
    at Function.Module._load (module.js:509:3)
    at Function.Module.runMain (module.js:701:10)
    at startup (bootstrap_node.js:194:16)
    at bootstrap_node.js:645:3

This commit adds a hasCrypto check.

PR-URL: https://github.com/nodejs/node/pull/17867
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2017-12-29 06:09:57 +01:00
Daniel Bevenius
acbe00792d tools: add check for using process.binding crypto
Currently, when configuring --without-ssl any tests that use
process.binding('crypto') will not report a lint warning. This is
because the eslint check only generates a warning when using require.

This commit adds a check for using binding in addition to require.

PR-URL: https://github.com/nodejs/node/pull/17867
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2017-12-29 06:08:16 +01:00
Weijia Wang
c64ca56def util: improve error message of _errnoException
The usage of ERR_INVALID_ARG_TYPE in _errnoException
is a little inappropriate. This change is to improve it.

PR-URL: https://github.com/nodejs/node/pull/17626
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2017-12-29 12:33:34 +08:00
Jeremiah Senkpiel
f94eec0218
http: convert utcDate to use setTimeout
A sort-of follow-up to https://github.com/nodejs/node/pull/17704, this
removes the last internal use of enroll().

PR-URL: https://github.com/nodejs/node/pull/17800
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: Minwoo Jung <minwoo@nodesource.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2017-12-29 00:08:54 +01:00
Ruben Bridgewater
8578fe22a9
assert: fix strict regression
Using `assert()` or `assert.ok()` resulted in a error since a
refactoring.

Refs: https://github.com/nodejs/node/pull/17582

PR-URL: https://github.com/nodejs/node/pull/17903
Refs: https://github.com/nodejs/node/pull/17582
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2017-12-29 00:04:40 +01:00
sreepurnajasti
968e20c7e5
test: improve to use template string
PR-URL: https://github.com/nodejs/node/pull/17895
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2017-12-29 00:02:09 +01:00
Ben Noordhuis
507aab58ca repl: fix coloring of process.versions
Remove the custom formatter that was added in commit 4fb27d4 ("intl: Add
more versions from ICU").  It's not necessary anymore (and may not have
been necessary at all) and prevents proper coloring in the REPL.

PR-URL: https://github.com/nodejs/node/pull/17861
Fixes: https://github.com/nodejs/node/issues/17086
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Khaidi Chu <i@2333.moe>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2017-12-28 10:16:26 -08:00
Tyson Andre
214bbb5228 doc: doc imitating the old behavior of http.Server.keepAliveTimeout
Documenting the best way to imitate the old behavior saves time for people
migrating from older versions. (E.g. for unexpected ECONNRESET)

It isn't immediately obvious if earlier nodejs versions behaved the same
way as nodejs 8 does with keepAliveTimeout = 0.
From 0aa7ef5950, it seems like they behave
the same way.

Related to issues such as #13391 that show up when migrating to node 8

PR-URL: https://github.com/nodejs/node/pull/17660
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
2017-12-28 10:10:26 -08:00
Kelvin Jin
120ea9b5c4 http2: implement ref() and unref() on client sessions
PR-URL: https://github.com/nodejs/node/pull/17620
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2017-12-28 09:32:54 -08:00
Rich Trott
a3535f3f6f tools: enable array-callback-return ESLint rule
For array methods that depend on a callback (such as `.filter()` or
`.map()`), require a return value from the callback.

PR-URL: https://github.com/nodejs/node/pull/17858
Reviewed-By: Weijia Wang <starkwang@126.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Khaidi Chu <i@2333.moe>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2017-12-28 09:05:44 -08:00
Rich Trott
fe8a5aa0b2 test: replace map() with forEach() where appropriate
Two tests were using Array.prototype.map() without returning values in
the callback. In other words, they were using it where a `.forEach()`
was called for. Change to `.forEach()`.

PR-URL: https://github.com/nodejs/node/pull/17858
Reviewed-By: Weijia Wang <starkwang@126.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Khaidi Chu <i@2333.moe>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2017-12-28 09:05:37 -08:00
Rich Trott
5c7af90cbf readline: refactor filter() callback
Use construct that always returns a boolean for `filter()` callback.

PR-URL: https://github.com/nodejs/node/pull/17858
Reviewed-By: Weijia Wang <starkwang@126.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Khaidi Chu <i@2333.moe>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2017-12-28 09:05:30 -08:00
James M Snell
286a5d0e74 doc: fs doc improvements
PR-URL: https://github.com/nodejs/node/pull/17831
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2017-12-28 08:50:29 -08:00