Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DEBUG_USE_MICROSECONDS=Y DEBUG=* node ./examples/node/useMicroseconds.js #594

Closed
wants to merge 1 commit into from

Conversation

amissine
Copy link

Add an option to use microseconds in timestamps. Tested on macOS 10.12.6 and Ubuntu 16.04 LTS. Sample output:

alec@alec-MS-7596 ~/process/debug (master) $ DEBUG_USE_MICROSECONDS=Y DEBUG=* node ./examples/node/useMicroseconds.js 
  use:µs the ∆ is +0µs
  use:µs the ∆ is +1366µs
  use:µs the ∆ is +110µs
  use:µs the ∆ is +31µs
  use:µs the ∆ is +36µs
  use:µs the ∆ is +24µs
  use:µs the ∆ is +23µs
  use:µs the ∆ is +23µs
(node:5403) Warning: N-API is an experimental feature and could change at any time.
  use:µs the ∆ is +11s
alec@alec-MS-7596 ~/process/debug (master) $ DEBUG=* node ./examples/node/useMicroseconds.js 
  use:µs the ∆ is +0ms
  use:µs the ∆ is +2ms
  use:µs the ∆ is +0ms
  use:µs the ∆ is +0ms
  use:µs the ∆ is +0ms
  use:µs the ∆ is +0ms
  use:µs the ∆ is +0ms
  use:µs the ∆ is +0ms
  use:µs the ∆ is +11s
alec@alec-MS-7596 ~/process/debug (master) $ npm test

> debug@3.1.0 test /home/alec/process/debug
> ./node_modules/mocha/bin/_mocha



  debug
    ✓ passes a basic sanity check
    ✓ allows namespaces to be a non-string value
    with log function
      ✓ uses it
    custom functions
      with log function
        ✓ uses it


  4 passing (9ms)

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.5%) to 73.256% when pulling 81c1c9e on amissine:master into 207a6a2 on visionmedia:master.

@Qix-
Copy link
Member

Qix- commented Aug 16, 2018

👎 Please see #582. There are already too many environment variables.

@Qix- Qix- added feature This proposes or provides a feature or enhancement change-minor This proposes or provides a change that requires a minor release awaiting-response This issue or pull request is awaiting a user's response labels Aug 16, 2018
@Qix-
Copy link
Member

Qix- commented Dec 13, 2018

Closing this in favor of #582.

@Qix- Qix- closed this Dec 13, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting-response This issue or pull request is awaiting a user's response change-minor This proposes or provides a change that requires a minor release feature This proposes or provides a feature or enhancement
Development

Successfully merging this pull request may close these issues.

None yet

3 participants