@chainsafe/lodestar-utils
Advanced tools
Comparing version 0.24.0 to 0.24.1-next.1a9e6e66a6bbdc31d7ac682396ecd0b5c78ccb5a.0
@@ -158,3 +158,4 @@ "use strict"; | ||
const row = [factor === undefined ? "" : `x${factor.toFixed(2)}`.padStart(6), `${opsPerSec.toPrecision(precision).padStart(13)} ops/s`, `${averageNs.toPrecision(precision).padStart(13)} ns/op`, `${String(runsDone).padStart(6)} runs`].join(" "); | ||
const [averageTime, timeUnit] = prettyTime(averageNs); | ||
const row = [factor === undefined ? "" : `x${factor.toFixed(2)}`.padStart(6), `${opsPerSec.toPrecision(precision).padStart(13)} ops/s`, `${averageTime.toPrecision(precision).padStart(13)} ${timeUnit}/op`, `${String(runsDone).padStart(6)} runs`].join(" "); | ||
return id.slice(0, idLen).padEnd(idLen) + " " + row; | ||
@@ -183,2 +184,9 @@ } | ||
} | ||
function prettyTime(nanoSec) { | ||
if (nanoSec > 1e9) return [nanoSec / 1e9, " s"]; | ||
if (nanoSec > 1e6) return [nanoSec / 1e6, "ms"]; | ||
if (nanoSec > 1e3) return [nanoSec / 1e3, "us"]; | ||
return [nanoSec, "ns"]; | ||
} | ||
//# sourceMappingURL=runner.js.map |
@@ -14,3 +14,3 @@ { | ||
}, | ||
"version": "0.24.0", | ||
"version": "0.24.1-next.1a9e6e66a6bbdc31d7ac682396ecd0b5c78ccb5a.0+1a9e6e6", | ||
"main": "lib/index.js", | ||
@@ -60,3 +60,3 @@ "files": [ | ||
], | ||
"gitHead": "8e5c09c2ed432186d238c4c50a5aac7da07e0257" | ||
"gitHead": "1a9e6e66a6bbdc31d7ac682396ecd0b5c78ccb5a" | ||
} |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
152934
1778
1