apow-cli 0.10.0 → 0.10.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/miner.js +5 -5
- package/package.json +1 -1
package/dist/miner.js
CHANGED
|
@@ -464,19 +464,19 @@ async function startMining(tokenId) {
|
|
|
464
464
|
return new Promise(() => { });
|
|
465
465
|
}));
|
|
466
466
|
}
|
|
467
|
-
// JS grinder
|
|
468
|
-
//
|
|
469
|
-
if (!useNative
|
|
467
|
+
// JS grinder runs unless local native grinders are active.
|
|
468
|
+
// Local CPU-C needs those cores, but x402 is remote — no conflict.
|
|
469
|
+
if (!useNative) {
|
|
470
470
|
grinders.push((0, grinder_1.grindNonceParallel)({
|
|
471
471
|
challengeNumber,
|
|
472
472
|
target,
|
|
473
473
|
minerAddress: account.address,
|
|
474
474
|
threads: config_1.config.minerThreads,
|
|
475
475
|
signal: abortController.signal,
|
|
476
|
-
onProgress: (attempts, hashrate) => {
|
|
476
|
+
onProgress: !useHttpGrind ? (attempts, hashrate) => {
|
|
477
477
|
const khs = (hashrate / 1000).toFixed(0);
|
|
478
478
|
nonceSpinner.update(`Grinding nonce (JS)... ${khs}k H/s (${attempts.toLocaleString()} attempts)`);
|
|
479
|
-
},
|
|
479
|
+
} : undefined,
|
|
480
480
|
}));
|
|
481
481
|
}
|
|
482
482
|
grind = await Promise.race(grinders);
|