| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
|
I am working on adding napi_get_date_value to call the underlying V8 ValueOf() to get the value back out of the Date object. |
Sorry, something went wrong.
There was a problem hiding this comment.
@nodejs/n-api
Sorry, something went wrong.
There was a problem hiding this comment.
I’m not sure if we follow a convention for these names in the N-API tests, but elsewhere in the code this would be either create_date or CreateDate :)
Sorry, something went wrong.
There was a problem hiding this comment.
I was torn on this one as I saw a mix of case usage for the function names in the tests.
static napi_value createError(napi_env env, napi_callback_info info) {
static napi_value createPromise(napi_env env, napi_callback_info info) {
static napi_value CreateTypedArray(napi_env env, napi_callback_info info) {
static napi_value CreateDataView(napi_env env, napi_callback_info info) {
Sorry, something went wrong.
There was a problem hiding this comment.
I don't think we have any different convention for N-API.
Sorry, something went wrong.
There was a problem hiding this comment.
Yeah, it’s not like it matters much – the latter style would be more consistent with the rest of core, that’s all.
Sorry, something went wrong.
Sorry, something went wrong.
There was a problem hiding this comment.
@jarrodconnolly thanks for the PR. Left a couple of small comments.
Sorry, something went wrong.
There was a problem hiding this comment.
LGTM
Sorry, something went wrong.
Sorry, something went wrong.
There was a problem hiding this comment.
LGTM with a few tiny nits.
Sorry, something went wrong.
Implements `napi_create_date()` as well as `napi_is_date()` to allow working with JavaScript Date objects.
Add the `napi_get_date_value` method to get the original time value from the Date object.
|
All changes are complete for this PR including requested changes from the reviews. I may try a PR at a later date to address the function naming convention across the n-api tests to see if there is interest in standardizing those with the rest of the coding standards. |
Sorry, something went wrong.
|
@addaleax Can I get a CI run on this now that the changes are all complete and maybe an author ready label if the run is smooth? Let me know if there is anything else I need to do, thanks again for the help on this pr. |
Sorry, something went wrong.
Sorry, something went wrong.
|
Thanks for the CI run @vsemozhetbyt looks like it might be an unrelated failure. The smartos17-64 tests timed out after an exception. 18:28:34 ok 1853 parallel/test-tls-sni-server-client 18:28:34 --- 18:28:34 duration_ms: 1.155 18:28:34 severity: ok 18:28:34 stack: |- 18:28:34 Exception in thread Thread-1: 18:28:34 Traceback (most recent call last): 18:28:34 File "/opt/local/lib/python2.7/threading.py", line 801, in __bootstrap_inner 18:28:34 self.run() 18:28:34 File "/opt/local/lib/python2.7/threading.py", line 754, in run 18:28:34 self.__target(*self.__args, **self.__kwargs) 18:28:34 File "tools/test.py", line 192, in RunSingle 18:28:34 self.HasRun(output) 18:28:34 File "tools/test.py", line 361, in HasRun 18:28:34 self._printDiagnostic() 18:28:34 File "tools/test.py", line 289, in _printDiagnostic 18:28:34 for l in self.traceback.splitlines(): 18:28:34 AttributeError: 'list' object has no attribute 'splitlines' 18:28:34 18:43:34 Build timed out (after 15 minutes). Marking the build as failed. |
Sorry, something went wrong.
Sorry, something went wrong.
|
Should this be land in a single commit or in two? |
Sorry, something went wrong.
|
I believe it should be a single commit. I am guessing you are referring to the second commit which adds the napi_get_date_value. This was just something I thought to add after the original commit to round out the implementation. Those are just my thoughts, others may have opinions on the regular procedure though. |
Sorry, something went wrong.
|
Just pinging to see if it would be possible to land this PR. My first and I am looking to complete the cycle once before moving on to future PRs. |
Sorry, something went wrong.
|
@jarrodconnolly at this point the CI is locked down due to the security release. If we don't land in the next few days after that release goes out please remind us and I'll try to get it landed. |
Sorry, something went wrong.
|
FWIW, the last CI run was green, so this should be able to land anytime. |
Sorry, something went wrong.
|
Lite CI since its low overhead just to double check nothing changed since the last CI https://ci.nodejs.org/job/node-test-pull-request-lite-pipeline/2720/ |
Sorry, something went wrong.
|
Lite CI good Landed in 13b1aaf |
Sorry, something went wrong.
Implements `napi_create_date()` as well as `napi_is_date()` to allow working with JavaScript Date objects. PR-URL: #25917 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Implements `napi_create_date()` as well as `napi_is_date()` to allow working with JavaScript Date objects. PR-URL: #25917 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Notable Changes
* n-api:
* Implement date object (Jarrod Connolly)
#25917
* util:
* Add compact depth mode for `util.inspect()` (Ruben Bridgewater)
#26269
* worker:
* Improve integration with native addons (Anna Henningsen)
#26175
* MessagePort.prototype.onmessage takes arguments closer to the Web
specification now (Anna Henningsen)
#26082
Notable Changes
* n-api:
* Implement date object (Jarrod Connolly)
nodejs#25917
* util:
* Add compact depth mode for `util.inspect()` (Ruben Bridgewater)
nodejs#26269
* worker:
* Improve integration with native addons (Anna Henningsen)
nodejs#26175
* MessagePort.prototype.onmessage takes arguments closer to the Web
specification now (Anna Henningsen)
nodejs#26082
Implements `napi_create_date()` as well as `napi_is_date()` to allow working with JavaScript Date objects. PR-URL: nodejs#25917 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Implements `napi_create_date()` as well as `napi_is_date()` to allow working with JavaScript Date objects. PR-URL: nodejs#25917 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Implements `napi_create_date()` as well as `napi_is_date()` to allow working with JavaScript Date objects. Backport-PR-URL: #28298 PR-URL: #25917 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Notable changes:
* crypto:
* add support for chacha20-poly1305 for AEAD (chux0519)
#24081
* increase maxmem range from 32 to 53 bits (Tobias Nießen)
#28799
* deps:
* update npm to 6.11.3 (claudiahdz)
#29430
* upgrade openssl sources to 1.1.1d (Sam Roberts)
#29921
* dns:
* remove dns.promises experimental warning (cjihrig)
#26592
* fs:
* remove experimental warning for fs.promises (Anna Henningsen)
#26581
* http:
* makes response.writeHead return the response (Mark S. Everitt)
#25974
* http2:
* makes response.writeHead return the response (Mark S. Everitt)
#25974
* n-api:
* make func argument of napi\_create\_threadsafe\_function optional
(legendecas)
#27791
* mark version 5 N-APIs as stable (Gabriel Schulhof)
#29401
* implement date object (Jarrod Connolly)
#25917
* process:
* add --unhandled-rejections flag (Ruben Bridgewater)
#26599
* stream:
* implement Readable.from async iterator utility (Guy Bedford)
#27660
* make Symbol.asyncIterator support stable (Matteo Collina)
#26989
PR-URL: #29875
Notable changes:
* crypto:
* add support for chacha20-poly1305 for AEAD (chux0519)
#24081
* increase maxmem range from 32 to 53 bits (Tobias Nießen)
#28799
* deps:
* update npm to 6.11.3 (claudiahdz)
#29430
* upgrade openssl sources to 1.1.1d (Sam Roberts)
#29921
* dns:
* remove dns.promises experimental warning (cjihrig)
#26592
* fs:
* remove experimental warning for fs.promises (Anna Henningsen)
#26581
* http:
* makes response.writeHead return the response (Mark S. Everitt)
#25974
* http2:
* makes response.writeHead return the response (Mark S. Everitt)
#25974
* n-api:
* make func argument of napi\_create\_threadsafe\_function optional
(legendecas)
#27791
* mark version 5 N-APIs as stable (Gabriel Schulhof)
#29401
* implement date object (Jarrod Connolly)
#25917
* process:
* add --unhandled-rejections flag (Ruben Bridgewater)
#26599
* stream:
* implement Readable.from async iterator utility (Guy Bedford)
#27660
* make Symbol.asyncIterator support stable (Matteo Collina)
#26989
PR-URL: #29875
| Back | FazBrowse Home | New Git URL |
Implements napi_create_date() as well as napi_is_date() to
allow working with JavaScript Date objects.
Checklist