GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||
GeezerVison is showing github.com — console: implement timeLog method by targos · Pull Request #21312 · nodejs/node Conversation
|
|
@targos build started: https://ci.nodejs.org/blue/organizations/jenkins/node-test-pull-request-lite-pipeline/detail/node-test-pull-request-lite-pipeline/50/pipeline |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Other than the function name printed in the process warning, couldn't Console.prototype.timeEnd() be updated to call this?
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Barring spec changes, this looks great.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Extra parenthesis in [`console.time()`)][].
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Maybe add a comment that value is 42 here? Otherwise, it is a bit unexpected below.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Seems a bit confusing. Maybe something like // Prints "process: 365.227ms 42".?
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
|
Should we document the separator that joins several |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
It seems this should go after ### console.timeEnd(label) section ABC-wise.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
No strong opinion but this document doesn't seem to follow the ABC rule and I went for the spec order. It's also the order in which you call the methods
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
All console. methods seem to be in ABC order according to the TOC.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Right. I didn't see that inspector methods were in another section
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
@cjihrig I refactored the common code in a separate function. PTAL.
I don't know. It's just using |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
@targos Then we can land as is and if anybody is sure how to document this (if needed), this can be done in another PR) |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
This will print a warning about no process label, right?
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
It's not supposed to. timeLog shouldn't clear the timer.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Nit: I personally would prefer to just check if data is undefined by adding a if / else but as the function is not hot, that is just a non-blocking recommendation.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
I can do that 👍
Sorry, something went wrong.
There was an error while loading. Please reload this page.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Looks like this failed across the board. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Upstream PR landed: https://console.spec.whatwg.org/#timelog |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
CI before landing: https://ci.nodejs.org/job/node-test-pull-request/15728/ |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Landed in b016745 |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
Refs: whatwg/console#138 PR-URL: #21312 Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Gus Caplan <[email protected]> Reviewed-By: Anatoli Papirovski <[email protected]> Reviewed-By: Weijia Wang <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: James M Snell <[email protected]>
Refs: whatwg/console#138 PR-URL: #21312 Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Gus Caplan <[email protected]> Reviewed-By: Anatoli Papirovski <[email protected]> Reviewed-By: Weijia Wang <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: James M Snell <[email protected]>
Notable changes: * console: * The `console.timeLog()` method has been implemented. (#21312) * deps: * Upgrade to libuv 1.22.0. (#21731) * Upgrade to ICU 62.1 (Unicode 11, CLDR 33.1). (#21728) * http: * Added support for passing both `timeout` and `agent` options to `http.request`. (#21204) * napi: * Added experimental support for functions dealing with bigint numbers. (#21226) * process: * The `process.hrtime.bigint()` method has been implemented. (#21256) * Added the `--title` command line argument to set the process title on startup. (#21477) * trace_events: * Added process_name metadata. (#21477)
Notable changes: * console: * The `console.timeLog()` method has been implemented. (#21312) * deps: * Upgrade to libuv 1.22.0. (#21731) * Upgrade to ICU 62.1 (Unicode 11, CLDR 33.1). (#21728) * http: * Added support for passing both `timeout` and `agent` options to `http.request`. (#21204) * napi: * Added experimental support for functions dealing with bigint numbers. (#21226) * process: * The `process.hrtime.bigint()` method has been implemented. (#21256) * Added the `--title` command line argument to set the process title on startup. (#21477) * trace_events: * Added process_name metadata. (#21477) * Added new collaborators * codebytere - Shelley Vohr PR-URL: #21851
Notable changes:
* console:
* The `console.timeLog()` method has been implemented.
(#21312)
* deps:
* Upgrade to libuv 1.22.0. (#21731)
* Upgrade to ICU 62.1 (Unicode 11, CLDR 33.1).
(#21728)
* http:
* Added support for passing both `timeout` and `agent` options to
`http.request`. (#21204)
* inspector:
* Expose the original console API in `require('inspector').console`.
(#21659)
* napi:
* Added experimental support for functions dealing with bigint numbers.
(#21226)
* process:
* The `process.hrtime.bigint()` method has been implemented.
(#21256)
* Added the `--title` command line argument to set the process title on
startup. (#21477)
* trace_events:
* Added process_name metadata.
(#21477)
* Added new collaborators
* codebytere - Shelley Vohr
PR-URL: #21851
Notable changes:
* console:
* The `console.timeLog()` method has been implemented.
(#21312)
* deps:
* Upgrade to libuv 1.22.0. (#21731)
* Upgrade to ICU 62.1 (Unicode 11, CLDR 33.1).
(#21728)
* http:
* Added support for passing both `timeout` and `agent` options to
`http.request`. (#21204)
* inspector:
* Expose the original console API in `require('inspector').console`.
(#21659)
* napi:
* Added experimental support for functions dealing with bigint numbers.
(#21226)
* process:
* The `process.hrtime.bigint()` method has been implemented.
(#21256)
* Added the `--title` command line argument to set the process title on
startup. (#21477)
* trace_events:
* Added process_name metadata.
(#21477)
* Added new collaborators
* codebytere - Shelley Vohr
PR-URL: #21851
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.