Skip to content

v6.14.2 proposal#19996

Merged
MylesBorins merged 227 commits into
v6.xfrom
v6.14.2-proposal
Apr 30, 2018
Merged

v6.14.2 proposal#19996
MylesBorins merged 227 commits into
v6.xfrom
v6.14.2-proposal

Conversation

@MylesBorins
Copy link
Copy Markdown
Contributor

@MylesBorins MylesBorins commented Apr 13, 2018 β€’

2018-04-30, Version 6.14.2 'Boron' (LTS), @MylesBorins

Notable Changes

Coming Soon

Commits

  • [6ba38e8c2b] - N-API: Reuse ObjectTemplate instances (Gabriel Schulhof) #13999
  • [49d8c2e8ae] - build: refine static and shared lib build (Yihong Wang) #17604
  • [cc7469eec8] - build: allow x86_64 as a dest_cpu alias for x64 (Rod Vagg) #18052
  • [969398d08e] - crypto: reuse variable instead of reevaluation (Tobias Nießen) #17735
  • [71acb5205a] - doc: Add a missing comma (jiangq) #19555
  • [b9b752ef07] - doc: fix typos on n-api (Kyle Robinson Young) #19385
  • [10fe65a0d5] - doc: fix n-api asynchronous threading docs (Eric Bickle) #19073
  • [8826f185b0] - doc: mark NAPI_AUTO_LENGTH as code (Tobias Nießen) #18697
  • [e9e5d56121] - doc: fix exporting a function example (Aonghus O Nia) #18661
  • [9719b831a3] - doc: fix typo in n-api.md (Vse Mozhet Byt) #18590
  • [fdd50fb35f] - doc: small typo in n-api.md (iskore) #18555
  • [24a2791173] - doc: remove usage of you in n-api doc (Michael Dawson) #18528
  • [74086e19f2] - doc: remove uannecessary Require (Michael Dawson) #18184
  • [fed2136857] - doc: napi: make header style consistent (Ali Ijaz Sheikh) #18122
  • [e04386a363] - doc: napi: fix unbalanced emphasis (Ali Ijaz Sheikh) #18122
  • [3d8e1aaf48] - doc: updates examples to use NULL (Michael Dawson) #18008
  • [173f29763e] - doc: update example in module registration (Franziska Hinkelmann) #17424
  • [c6852126fd] - doc: use "JavaScript" instead of "Javascript" (Rich Trott) #17163
  • [35dc8bab9e] - doc: document common pattern for instanceof checks (Michael Dawson) #16699
  • [22490dcb91] - doc: fix typos in N-API (Swathi Kalahastri) #16911
  • [55fabd7337] - doc: fix a typo in n-api documentation (Vipin Menon) #16879
  • [0c67f21bcf] - doc: update to use NAPI_AUTO_LENGTH (Michael Dawson) #16187
  • [5c2bba0931] - doc: fix some links (Vse Mozhet Byt) #16202
  • [e9a6dffc65] - doc: fix outdated code sample in n-api.md (rebornix) #15581
  • [ca69f1dfe7] - doc: fix new nits in links (Vse Mozhet Byt) #15449
  • [a766802bee] - doc: fix doc for napi_get_value_string_utf8 (Daniel Taveras) #14529
  • [b0f09a2ee6] - doc: added napi_get_value_string_latin1 (Kyle Farnung) #14678
  • [fbcc962727] - doc: delint (Refael Ackermann) #14707
  • [831de617b0] - doc: document napi_finalize() signature (cjihrig) #14230
  • [4b9773effa] - doc: fix some links (Vse Mozhet Byt) #14400
  • [36185b343b] - doc: doc lifetime of n-api last error info (Michael Dawson) #13939
  • [cc3a4af7c8] - doc: fix a few n-api doc issues (Michael Dawson) #13650
  • [1e91d5804d] - doc: fix out of date napi_callback doc (XadillaX) #13570
  • [c5ae39e401] - doc: fix napi_create_*_error signatures in n-api (Jamen Marzonie) #13544
  • [35a3cbb5dd] - doc: fix out of date sections in n-api doc (Michael Dawson) #13508
  • [a06cc4684f] - doc: fix typo "ndapi" in n-api.md (Jamen Marz) #13484
  • [82f31ff4af] - doc: add ref to option to enable n-api (Michael Dawson) #13406
  • [17fe21e83d] - doc: fix typo in n-api.md (JongChan Choi) #13323
  • [2e2905266e] - doc: fix title/function name mismatch (Michael Dawson) #13123
  • [75e91fe5c8] - doc: add reference to node_api.h in docs (Michael Dawson) #13084
  • [0f74ee5cbf] - doc: clarify operation of napi_cancel_async_work (Michael Dawson) #12974
  • [5b045374ed] - doc: clarify node.js addons are c++ (Beth Griggs) #12898
  • [6bcd6d49d5] - doc: fix broken links in n-api doc (Michael Dawson) #12889
  • [3e388cf819] - doc: Add initial documentation for N-API (Michael Dawson) #12549
  • [4d67369c1b] - doc: fix various nits (Vse Mozhet Byt) #19743
  • [057c80b088] - doc: move Fedor to TSC Emeritus (Myles Borins) #18752
  • [bf72ee667e] - doc: add mmarchini to collaborators (Matheus Marchini) #18740
  • [280af052d8] - doc: add history for url.parse (Steven) #18685
  • [29b0d3b104] - doc: add devsnek to collaborators (Gus Caplan) #18679
  • [dc6dc8232f] - doc: add section for strategic initiatives (Michael Dawson) #17104
  • [6b348d4483] - doc: modify the return value of request.write() (ι™ˆεˆš) #18526
  • [dd4d075e51] - doc: be more explicit in the sypnosis (Tim O. Peters) #17977
  • [0067bccf6f] - doc: fix description of createDecipheriv (Tobias Nießen) #18651
  • [bc2f0a5120] - doc: linkify missing types (Vse Mozhet Byt) #18444
  • [32089bcbc1] - doc: streamline README intro (Rich Trott) #18483
  • [43839f1601] - doc: move Brian White to TSC Emeriti list (Rich Trott) #18482
  • [27d3c1a0f4] - doc: add Gibson Fahnestock to TSC (Rich Trott) #18481
  • [67fd520539] - doc: reorder section on updating PR branch (Ali Ijaz Sheikh) #18355
  • [f81a69aefe] - fs: fix createReadStream(…, {end: n}) for non-seekable fds (Anna Henningsen) #19329
  • [18acad349c] - http: make socketPath work with no agent (Luigi Pinca) #19425
  • [1edadebaa0] - http: allow _httpMessage to be GC'ed (Luigi Pinca) #18865
  • [dbe70b744c] - http: free the parser before emitting 'upgrade' (Luigi Pinca) #18209
  • [77a405b92f] - lib: set process.execPath on OpenBSD (Aaron Bieber) #18543
  • [3aa5b7d939] - n-api: add more int64\_t tests (Kyle Farnung) #19402
  • [abd9fd6797] - n-api: back up env before finalize (Gabriel Schulhof) #19718
  • [e6ccdfbde3] - n-api: ensure in-module exceptions are propagated (Gabriel Schulhof) #19537
  • [c6d0a66ef2] - (SEMVER-MINOR) n-api: bump version of n-api supported (Michael Dawson) #19497
  • [c16a705416] - n-api: re-write test_make_callback (Gabriel Schulhof) #19448
  • [49cd4fad89] - (SEMVER-MINOR) n-api: add napi_fatal_exception (Mathias Buus) #19337
  • [eb29266878] - n-api: add missing exception checking (Michael Dawson) #19362
  • [2c1190a93d] - (SEMVER-MINOR) n-api: take n-api out of experimental (Michael Dawson) #19262
  • [ce1447920e] - n-api: resolve promise in test (Gabriel Schulhof) #19245
  • [a8237efaf1] - n-api: update documentation (Gabriel Schulhof) #19078
  • [af62c8fff7] - n-api: update reference test (Gabriel Schulhof) #19086
  • [d2463745a7] - n-api: fix object test (Gabriel Schulhof) #19039
  • [516c287f8e] - n-api: remove extra reference from test (Gabriel Schulhof) #18542
  • [a8dec487f7] - (SEMVER-MINOR) n-api: add methods to open/close callback scope (Michael Dawson) #18089
  • [c09a7134e7] - n-api: wrap control flow macro in do/while (Ben Noordhuis) #18532
  • [b565ba2d82] - n-api: implement wrapping using private properties (Gabriel Schulhof) #18311
  • [d9df8cfe77] - n-api: change assert ok check to notStrictEqual. (Aaron Kau) #18414
  • [2e24a0bfe7] - n-api: throw RangeError napi_create_typedarray() (Jinho Bang) #18037
  • [62427bbed9] - (SEMVER-MINOR) n-api: expose n-api version in process.versions (Michael Dawson) #18067
  • [bb99f31f30] - n-api: throw RangeError in napi_create_dataview() with invalid range (Jinho Bang) #17869
  • [65ea7abd55] - n-api: fix memory leak in napi_async_destroy() (alnyan) #17714
  • [d4284a464b] - n-api: use nullptr instead of NULL in node_api.cc (Daniel Bevenius) #17276
  • [f4391b95ee] - (SEMVER-MINOR) n-api: add helper for addons to get the event loop (Anna Henningsen) #17109
  • [3c84db624a] - n-api: unexpose symbols and remove EXTERNAL_NAPI (Gabriel Schulhof) #16234
  • [55aab6bf01] - n-api: check against invalid handle scope usage (Anna Henningsen) #16201
  • [169b53e788] - n-api: use module name macro (Michael Dawson) #16185
  • [32412a8ded] - n-api: make changes for source compatibility (Gabriel Schulhof) #16102
  • [00d094f9c3] - n-api: add check for large strings (Michael Dawson) #15611
  • [2bc8a59915] - n-api: fix warning about size_t compare with int (Sampson Gao) #15508
  • [5e29823d1d] - n-api: remove n-api module loading flag (Gabriel Schulhof) #14902
  • [f31b50cfc7] - n-api: add optional string length parameters (Sampson Gao) #15343
  • [fe87a5944b] - n-api: napi_is_construct_call->napi_get_new_target (Sampson Gao) #14698
  • [5eadd6249d] - n-api: Context for custom async operations (Jason Ginchereau) #15189
  • [50cb48b55c] - n-api: refactor napi_addon_register_func (Taylor Woll) #15088
  • [156a8b6069] - (SEMVER-MINOR) n-api: change async resource name to napi_value (Jason Ginchereau) #14697
  • [7588eead2a] - (SEMVER-MINOR) n-api: use AsyncResource for Work tracking (Anna Henningsen) #14697
  • [676cff48bd] - n-api: stop creating references to primitives (Gabriel Schulhof) #15289
  • [3b4708b025] - n-api: implement napi_run_script (Gabriel Schulhof) #15216
  • [ac5b904808] - n-api: adds function to adjust external memory (Chris Young) #14310
  • [278a2d069f] - (SEMVER-MINOR) n-api: implement promise (Gabriel Schulhof) #14365
  • [73cc251f50] - (SEMVER-MINOR) n-api: add ability to remove a wrapping (Gabriel Schulhof) #14658
  • [951adbef3d] - (SEMVER-MINOR) n-api: add napi_get_node_version (Anna Henningsen) #14696
  • [b29eb693a0] - (SEMVER-MINOR) n-api: optimize number API performance (Jason Ginchereau) #14573
  • [bd032a158a] - (SEMVER-MINOR) n-api: add support for DataView (Shivanth MP) #14382
  • [86b101cb60] - n-api: re-use napi_env between modules (Gabriel Schulhof) #14217
  • [1acab66df4] - n-api: directly create Local from Persistent (Kyle Farnung) #14211
  • [f4d1cae634] - n-api: add fast paths for integer getters (Anna Henningsen) #14393
  • [aad36b2cd4] - n-api: add napi_fatal_error API (Kyle Farnung) #13971
  • [57be12ed97] - (SEMVER-MINOR) n-api: add code parameter to error helpers (Michael Dawson) #13988
  • [cd3015408e] - n-api: wrap test macros in do/while (Kyle Farnung) #14095
  • [7973bd3e63] - n-api: Implement stricter wrapping (Gabriel Schulhof) #13872
  • [5b0c57cfeb] - n-api: fix warning in test_general (Daniel Bevenius) #14104
  • [a5517d80bb] - n-api: add napi_has_own_property() (cjihrig) #14063
  • [8e2a26d3d0] - n-api: fix -Wmaybe-uninitialized compiler warning (Ben Noordhuis) #14053
  • [33821c3087] - n-api: use Maybe version of Object::SetPrototype() (Ben Noordhuis) #14053
  • [80cf25a8a5] - n-api: add napi_delete_property() (cjihrig) #13934
  • [cadec3b37e] - n-api: add napi_delete_element() (cjihrig) #13949
  • [97b628ba8e] - n-api: fix section title typo (Kyle Farnung) #13972
  • [c3eb187bd9] - n-api: avoid crash in napi_escape_scope() (Michael Dawson) #13651
  • [919556f27a] - n-api: enable napi_wrap() to work with any object (Jason Ginchereau) #13250
  • [86c0ebf4e2] - (SEMVER-MINOR) n-api: add napi_get_version (Michael Dawson) #13207
  • [70281ba1be] - n-api: Retain last code when getting error info (Jason Ginchereau) #13087
  • [8d3162d9e6] - n-api: remove compiler warning (Anna Henningsen) #13014
  • [a128219a48] - n-api: Handle fatal exception in async callback (Jason Ginchereau) #12838
  • [2e36365d56] - n-api: napi_get_cb_info should fill array (Jason Ginchereau) #12863
  • [7507d1e0e6] - n-api: remove unnecessary try-catch bracket from certain APIs (Gabriel Schulhof) #12705
  • [49d74c648d] - n-api: Sync with back-compat changes (Jason Ginchereau) #12674
  • [bc252509ca] - n-api: Reference and external tests (Jason Ginchereau) #12551
  • [c560db9ece] - n-api: Enable scope and ref APIs during exception (Jason Ginchereau) #12524
  • [8287e7671a] - n-api: tighten null-checking and clean up last error (Gabriel Schulhof) #12539
  • [f5cfa09ca4] - n-api: remove napi_get_value_string_length() (Jason Ginchereau) #12496
  • [c44f6ffc3c] - n-api: fix coverity scan report (Michael Dawson) #12365
  • [9bf8e9d48c] - n-api: add string api for latin1 encoding (Sampson Gao) #12368
  • [eb51d42d2b] - n-api: fix -Wmismatched-tags compiler warning (Ben Noordhuis) #12333
  • [d82fd2a9a0] - n-api: implement async helper methods (taylor.woll) #12250
  • [c127b71526] - n-api: change napi_callback to return napi_value (Taylor Woll) #12248
  • [2a726223ea] - n-api: cache Symbol.hasInstance (Gabriel Schulhof) #12246
  • [db36ca5f91] - n-api: Update property attrs enum to match JS spec (Jason Ginchereau) #12240
  • [1e6d3bb841] - n-api: create napi_env as a real structure (Gabriel Schulhof) #12195
  • [f1bdbd17d0] - n-api: break dep between v8 and napi attributes (Michael Dawson) #12191
  • [a9562fe30c] - (SEMVER-MINOR) n-api: add support for abi stable module API (Jason Ginchereau) #11975
  • [aa0fb7761e] - n-api,test: add int64 bounds tests (Kyle Farnung) #19309
  • [3f6d80e25c] - n-api,test: add a new.target test to addons-napi (Taylor Woll) #19236
  • [011b53e28f] - n-api,test: use module name macro (Gabriel Schulhof) #16146
  • [a6af97f76c] - napi: initialize and check status properly (Gabriel Schulhof) #12283
  • [9b36811d8e] - napi: supress invalid coverity leak message (Michael Dawson) #12192
  • [269c2f3ad9] - net: remove redundant code from _writeGeneric() (Luigi Pinca) #18429
  • [988cca841e] - process: fix reading zero-length env vars on win32 (Anna Henningsen) #18463
  • [72a5710b71] - readline: update references to archived repository (Tobias Nießen) #17924
  • [b20c278a7c] - src: add napi_handle_scope_mismatch to msg list (neta) #17161
  • [0ef0b342e9] - src: replace assert with CHECK_LE in node_api.cc (Ben Noordhuis) #14514
  • [a8c73748db] - src: correct endif comment SRC_NODE_API_H__ (Daniel Bevenius) #13190
  • [0ca2dad3a6] - src: free memory before re-setting URLHost value (Ivan Filenko) #18357
  • [e54b8e8184] - stream: cleanup() when unpiping all streams. (ι™ˆεˆš) #18266
  • [8ab8d6afd6] - stream: fix y.pipe(x)+y.pipe(x)+y.unpipe(x) (Anna Henningsen) #12746
  • [8f830ca896] - stream: remove unreachable code (Luigi Pinca) #18239
  • [64c83d7da9] - stream: simplify src.\_readableState to state (ι™ˆεˆš) #18264
  • [7c58045470] - test: remove unnecessary timer (cjihrig) #18719
  • [c90b77ed5d] - test: convert new tests to use error types (Jack Horton) #18581
  • [7f37dc9c48] - test: improve error message output (Bhavani Shankar) #18498
  • [59249a1768] - test: show pending exception error in napi tests (Ben Wilcox) #18413
  • [eceb70b584] - test: refactor addons-napi/test_exception/test.js (Rich Trott) #18340
  • [b3806ecd39] - test: fixed typos in napi test (furstenheim) #18148
  • [a6c277e2eb] - test: remove ambiguous error messages from test_error (Nicholas Drane) #17812
  • [412cc17748] - test: remove literals that obscure assert messages (Rich Trott) #17642
  • [86ddd03608] - test: add unhandled rejection guard (babygoat) #17275
  • [e54b58c024] - test: replace assert.throws with common.expectsError (Leko) #17445
  • [976f32d189] - test: refactor addons-napi/test_promise/test.js (ka3e) #16814
  • [2476ab9619] - test: improve error emssage reporting in testNapiRun.js (Paul Ashfield) #16821
  • [d4c04e05f7] - test: improve assert messages in napi exception test (Paul Blanche) #16820
  • [c14207c77b] - test: add detailed message for assertion failure (Attila Gonda) #16812
  • [d31792fcbe] - test: use default assertion messages (John Byrne) #16808
  • [087d213f67] - test: include actual value in assertion message (Matthew Cantelon) #15935
  • [9cc435dc85] - test: improve message for assert.strictEqual() (Jayson D. Henkel) #16013
  • [ebbd07dd27] - test: remove redundant error messages (Christina Chan) #16043
  • [5bba809e01] - test: cleaned up assert messages (mrgorbo) #16032
  • [53bd313739] - test: fix race condition in addon test (Kinnan Kwok) #16037
  • [37acd806be] - test: remove template literal (Emily Ford) #15953
  • [31c97178c1] - test: remove unused parameters (Daniil Shakir) #14968
  • [b59eddd082] - test: use regular expressions in throw assertions (Vincent Xue) #14318
  • [06b1273464] - test: changed error message validator (Pratik Jain) #14443
  • [3f3eaf9961] - test: replace string concat with template literal (Song, Bintao Garfield) #14269
  • [48274213b1] - test: handle missing V8 tests in n-api test (cjihrig) #14123
  • [7f126c2069] - test: add coverage for napi_typeof (Michael Dawson) #13990
  • [a0cf9b7a73] - test: verify napi_get_property() walks prototype (cjihrig) #13961
  • [1e25062fa1] - test: add coverage for napi_property_descriptor (Michael Dawson) #13510
  • [eb422796cd] - test: fix build warning in addons-napi/test_object (Jason Ginchereau) #13412
  • [9d70b43bdc] - test: consolidate n-api test addons - part2 (Michael Dawson) #13380
  • [06cf9480d3] - test: consolidate n-api test addons (Michael Dawson) #13317
  • [652d3218fe] - test: Make N-API weak-ref GC tests asynchronous (Jason Ginchereau) #13121
  • [0dac33d4f2] - test: improve n-api coverage for typed arrays (Michael Dawson) #13244
  • [1829d25907] - test: add coverage for napi_has_named_property (Michael Dawson) #13178
  • [d89afe8685] - test: increase n-api constructor coverage (Michael Dawson) #13124
  • [71aa251671] - test: Improve N-API test coverage (Michael Dawson) #13044
  • [314f22dcf4] - test: improve N-API test coverage (Michael Dawson) #13006
  • [263a633d5e] - test: add common.mustCall() to NAPI exception test (Rich Trott) #12959
  • [5936f7c9bb] - test: improve n-api array func coverage (Michael Dawson) #12890
  • [ce03977f30] - test: fix napi test_reference for recent V8 (MichaΓ«l Zasso) #12864
  • [dd7665a68e] - test: port test for make_callback to n-api (Hitesh Kanwathirtha) #12409
  • [f09677fdba] - test: add coverage for error apis (Michael Dawson) #12729
  • [1785f3cf44] - test: fix warning in n-api reference test (Michael Dawson) #12730
  • [5d2afb2174] - test: replace indexOf with includes (gwer) #12604
  • [fcb019f6ea] - test: add coverage for napi_cancel_async_work (Michael Dawson) #12575
  • [72c5d976f1] - test: test doc'd napi_get_value_int32 behaviour (Michael Dawson) #12633
  • [d9f3e0dd83] - Revert "test: port test for make_callback to n-api" (James M Snell) #12475
  • [a003777d96] - test: port test for make_callback to n-api (Hitesh Kanwathirtha) #12409
  • [577f327d2c] - test: fix compiler warning in n-api test (Anna Henningsen) #12318
  • [f8c2585fe0] - test: add second argument to assert.throws (MichaΓ«l Zasso) #12270
  • [6bf3d04d6c] - test: improve test coverage for n-api (Michael Dawson) #12327
  • [d799b1cb61] - test: update a few tests to work on OpenBSD (Aaron Bieber) #18543
  • [bc883fb136] - test: refactor test-http-abort-before-end (cjihrig) #18508
  • [44ab85018c] - test: fix flaky timers-block-eventloop test (Anatoli Papirovski) #18567
  • [5bcf668f42] - test: use correct size in test-stream-buffer-list (Luigi Pinca) #18239
  • [f3c6febedf] - test: update references to archived repository (Tobias Nießen) #17924
  • [b2a2a55271] - test: verify the shell option works properly on execFile (jvelezpo) #18384
  • [fd7d1990db] - test: remove orphaned entries from status (Kyle Farnung) #19042
  • [5ca8dee8cb] - test: remove n-api intermediate files (Gabriel Schulhof) #19375
  • [46aed5800f] - test: make common.mustNotCall show file:linenumber (Lance Ball) #17257
  • [4d2efa2415] - test: remove mark flaky for moved test (Beth Griggs) #19069
  • [502781c1d7] - test: fix spelling in test case comments (Tobias Nießen) #18018
  • [b2bf6c873f] - test,lib,doc: use function declarations (Rich Trott) #12711
  • [a91b1b928c] - win, build: fix intl-none option (Birunthan Mohanathas) #18292
  • [6ff763bd66] - win, build: fix without-intl option (Bartosz Sosnowski) #17614

tniessen and others added 30 commits March 29, 2018 23:25
PR-URL: #18018
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Weijia Wang <starkwang@126.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Yuta Hiroto <hello@about-hiroppy.com>
82bdf8f fixed an issue by silently modifying the `start`
option for the case when only `end` is passed, in order to perform
reads from a specified range in the file.

However, that approach does not work for non-seekable files, since
a numeric `start` option means that positioned reads will be used
to read data from the file.

This patch fixes that, and instead ends reading after a specified
size by adjusting the read buffer size.

This way we avoid re-introducing the bug that 82bdf8f fixed,
and align behaviour with the native file stream mechanism
introduced in #18936 as well.

Backport-PR-URL: #19411
PR-URL: #19329
Fixes: #19240
Refs: #18121
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Chen Gang <gangc.cxy@foxmail.com>
Remove 'flaky' in parallel.status for test-debug-signal-cluster as the
test was moved to sequential.

Refs: #13592
PR-URL: #19069
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Backport-PR-URL: #19115
PR-URL: #17735
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
When a test fails via `common.mustNotCall` it is sometimes hard to
determine exactly what was called. This modification stores the
caller's file and line number by using the V8 Error API to capture
a stack at the time `common.mustNotCall()` is called. In the event
of failure, this information is printed.

This change also exposes a new function in test/common, `getCallSite()`
which accepts a `function` and returns a `String` with the file name and
line number for the function.

Backport-PR-URL: #19355
PR-URL: #17257
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: MichaΓ«l Zasso <targos@protonmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Khaidi Chu <i@2333.moe>
PR-URL: #19375
Reviewed-By: Myles Borins <myles.borins@gmail.com>
PR-URL: #19042
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Ensure that the parser is freed before emitting the 'connect' or
'upgrade' event.

PR-URL: #18209
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Fedor Indutny <fedor.indutny@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
PR-URL: #18264
Reviewed-By: Weijia Wang <starkwang@126.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: MichaΓ«l Zasso <targos@protonmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
It makes more sense to provide instructions on how to update the PR
branch before instructions on pushing the commit.

PR-URL: #18355
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: MichaΓ«l Zasso <targos@protonmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.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: Jon Moss <me@jonathanmoss.me>
Welcome Gibson to the TSC!

PR-URL: #18481
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: MichaΓ«l Zasso <targos@protonmail.com>
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: Π‘ΠΊΠΎΠ²ΠΎΡ€ΠΎΠ΄Π° Никита АндрССвич <chalkerx@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
PR-URL: #18482
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: MichaΓ«l Zasso <targos@protonmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Shorten text that is duplicated from website and supply link.

PR-URL: #18483
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Π‘ΠΊΠΎΠ²ΠΎΡ€ΠΎΠ΄Π° Никита АндрССвич <chalkerx@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Useful for executing in a shell because it accepts arguments as
an array instead of a string as exec does.
Depending on the circumstances,
that can prove to be useful if the arguments are already prepared.

PR-URL: #18384
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
x86_64 is a standard arch descriptor on Linux, allow it as an alias for
our preferred descriptor: x64

PR-URL: #18052
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
The encoding is already handled by `Writable.prototype.write()`.

PR-URL: #18429
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: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Backport-PR-URL: #19120
PR-URL: #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>
Backport-PR-URL: #19120
PR-URL: #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>
Refine the static and shared lib build process in order
to integrate static and shared lib verfication into CI.
When building both static and shared lib, we still build
node executable now and it uses the shared and static lib.

Signed-off-by: Yihong Wang <yh.wang@ibm.com>

Refs: #14158
Backport-PR-URL: #19050
PR-URL: #17604
Reviewed-By: Bartosz Sosnowski <bartosz@janeasystems.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
To avoid a function call `BufferList.prototype.concat()` is not called
when there is only a buffer in the list. That buffer is instead
accessed directly.

Backport-PR-URL: #19483
PR-URL: #18239
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
The `n` argument of `BufferList.prototype.concat()` is not the number
of `Buffer` instances in the list, but their total length when
concatenated.

Backport-PR-URL: #19483
PR-URL: #18239
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Also, alphabetize all types in type-parser.js
and fix some nits in type formats.

Backport-PR-URL: #19500
PR-URL: #18444
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Fixes --with-intl option passed to configure script when without-intl
is used

Backport-PR-URL: #19485
PR-URL: #17614
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Like #17614, but for the `intl-none` option.

Backport-PR-URL: #19485
Refs: #17614
PR-URL: #18292
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Bartosz Sosnowski <bartosz@janeasystems.com>
Up until now, Node did not clear the current error code
attempting to read environment variables on Windows.
Since checking the error code is the way we distinguish between
missing and zero-length environment variables, this could lead to a
false positive when the error code was still tainted.

In the simplest case, accessing a missing variable and then a
zero-length one would lead Node to believe that both calls yielded
an error.

Before:

    > process.env.I=''; process.env.Q; process.env.I
    undefined
    > process.env.I=''; /*process.env.Q;*/ process.env.I
    ''

After:

    > process.env.I=''; process.env.Q; process.env.I
    ''
    > process.env.I=''; /*process.env.Q;*/ process.env.I
    ''

This only affects Node 8 and above, since before
1aa595e we always constructed a
`v8::String::Value` instance for passing the lookup key to the OS,
which in in turn always made a heap allocation and therefore
reset the error code.

Backport-PR-URL: #19484
PR-URL: #18463
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Fedor Indutny <fedor.indutny@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: MichaΓ«l Zasso <targos@protonmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
PR-URL: #18651
Refs: #12223
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Due to extensive reliance on timings and the fs module, this test
is currently inherently flaky. Refactor it to simply use setImmediate
and only one busy loop.

PR-URL: #18567
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
This test was added over six years ago, and the behavior
seems to have changed since then. When the test was originally
written, common.mustCall() did not exist. The only assertion
in this test was not actually executing. Instead of an 'error'
event being emitted as expected, an 'abort' event was emitted.

PR-URL: #18508
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Assuming less knowledge on the part of the reader, making it easier
to get start using Node.js.

PR-URL: #17977
Fixes: #17970,
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
PR-URL: #18526
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
cjihrig and others added 18 commits April 16, 2018 17:46
The timer in NAPI's test_callback_scope/test-resolve-async.js
can be removed. If the test fails, it will timeout on its own.
The extra timer increases the chances of the test being
flaky.

Backport-PR-URL: #19447
PR-URL: #18719
Fixes: #18702
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Passing a pointer to a static integer is sufficient for the test.

Backport-PR-URL: #19447
PR-URL: #19039
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Hitesh Kanwathirtha <hiteshk@microsoft.com>
Documentation for N-API Custom Asynchronous Operations incorrectly
stated that async execution happens on the main event loop.
Added details to napi_create_async_work about which threads are
used to invoke the execute and complete callbacks.

Changed 'async' to 'asynchronous' in the documentation for Custom
Asynchronous Operations. Changed "executes in parallel" to "can
execute in parallel" for the documentation of napi_create_async_work
execute parameter.

Backport-PR-URL: #19447
PR-URL: #19073
Fixes: #19071
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Remove the necessity for allocating on the heap, and assert that the
correct pointer gets passed to the finalizer.

Backport-PR-URL: #19447
PR-URL: #19086
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Document which APIs work while an exception is pending. This is the
list of all APIs which do not start with `NAPI_PREAMBLE(env)`.

Fixes: nodejs/abi-stable-node#257
Backport-PR-URL: #19447
PR-URL: #19078
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
The last promise created by the test for the purposes of making sure
that its type is indeed a promise needs to be resolved so as to avoid
having it left in the pending state at the end of the test.

Backport-PR-URL: #19447
PR-URL: #19245
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Added a N-API test to verify new.target behavior.

Backport-PR-URL: #19447
PR-URL: #19236
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Take n-api out of experimental as per:
nodejs/TSC#501

Backport-PR-URL: #19447
PR-URL: #19262
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: MichaΓ«l Zasso <targos@protonmail.com>
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
Added some simple tests to verify that the int64 API is correctly
handling numbers greater than 32-bits. This is a basic test, but
verifies that an implementer hasn't truncated back to 32-bits.

Refs: nodejs/node-chakracore#496

Backport-PR-URL: #19447
PR-URL: #19309
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Backport-PR-URL: #19447
PR-URL: #19385
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
Reviewed-By: MichaΓ«l Zasso <targos@protonmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Add checks for a pending exception in napi_make_callback
after the callback has been invoked.  If there is a pending
exception then we need to avoid checking the result as that
will not be able to complete properly.

Add additional checks to the unit test for napi_make_callback
to catch this case.

Backport-PR-URL: #19447
PR-URL: #19362
Fixes: nodejs/node-addon-api#235
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Add function to trigger and uncaught exception.
Useful if an async callback throws an exception with
no way to recover.

Backport-PR-URL: #19447
PR-URL: #19337
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
This re-writes the test in C by dropping std::vector<napi_value> in
favour of a C99 variable length array, and by dropping the anonymous
namespace in favour of static function declarations.

Backport-PR-URL: #19447
PR-URL: #19448
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Backport-PR-URL: #19447
PR-URL: #19555
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Bump the version due to additions to the api.

Backport-PR-URL: #19447
PR-URL: #19497
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Whenever we call into an addon, whether it is for a callback, for
module init, or for async work-related reasons, we should make sure
that

* the last error is cleared,
* the scopes before the call are the same as after, and
* if an exception was thrown and captured inside the module, then it is
  re-thrown after the call.

Therefore we should call into the module in a unified fashion. This
change introduces the macro NAPI_CALL_INTO_MODULE() which should be
used whenever invoking a callback provided by the module.

Fixes: #19437
Backport-PR-URL: #19447
PR-URL: #19537
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Heed the comment to not use fields of a Reference after calling its
finalize callback, because such a call may destroy the Reference.

Fixes: #19673
Backport-PR-URL: #19447
PR-URL: #19718
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
* Updated tests for `Number` and `int32_t`
* Added new tests for `int64_t`
* Updated N-API `int64_t` behavior to return zero for all non-finite
  numbers
* Clarified the documentation for these calls.

Backport-PR-URL: #19447
PR-URL: #19402
Refs: nodejs/node-chakracore#500
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
@MylesBorins
Copy link
Copy Markdown
Contributor Author

MylesBorins commented Apr 16, 2018 β€’

nit: I have to go through the changelog and remove all the semver minor references that have to do with n-api. It is landing as experimental.

CI: https://ci.nodejs.org/job/node-test-pull-request/14339/
CITGM: https://ci.nodejs.org/view/Node.js-citgm/job/citgm-smoker/1367/
v6.14.1 CITGM: https://ci.nodejs.org/view/Node.js-citgm/job/citgm-smoker-nobuild/278/
rc.1: https://nodejs.org/download/rc/v6.14.2-rc.1/

@MylesBorins MylesBorins force-pushed the v6.14.2-proposal branch 2 times, most recently from e7e1642 to 1ee8f94 Compare April 30, 2018 15:05
@MylesBorins
Copy link
Copy Markdown
Contributor Author

Notable Change:

* n-api:
  - n-api has been backported to v6.x. It is being landed as an experimental interface,
    and as such is landing in a Semver-Patch release. (Gabriel Schulhof)
    #19447

PR-URL: #19996
@MylesBorins MylesBorins merged commit 79592b1 into v6.x Apr 30, 2018
MylesBorins added a commit that referenced this pull request Apr 30, 2018
MylesBorins added a commit that referenced this pull request Apr 30, 2018
Notable Change:

* n-api:
  - n-api has been backported to v6.x. It is being landed as an experimental interface,
    and as such is landing in a Semver-Patch release. (Gabriel Schulhof)
    #19447

PR-URL: #19996
@gibfahn gibfahn deleted the v6.14.2-proposal branch May 1, 2018 14:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

build Issues and PRs related to build files or the CI. doc Issues and PRs related to the documentations. meta Issues and PRs related to the general management of the project.

Projects

None yet

Development

Successfully merging this pull request may close these issues.