Was not logging invalid found blocks correctly

This commit is contained in:
Matt 2014-02-26 22:57:22 -07:00
parent 4b9154fd9f
commit 08fe9ab18d
2 changed files with 11 additions and 14 deletions

View File

@ -8,31 +8,28 @@
"stratumPort": 3334,
"difficulty": 8,
"blockRefreshInterval": 1000,
"daemon": [
{ //first daemon instance
{
"host": "localhost",
"port": 19332,
"user": "litecoinrpc",
"password": "testnet"
},
{ //backup daemon instance
{
"host": "localhost",
"port": 19344,
"user": "litecoinrpc",
"password": "testnet"
}
],
"varDiff": {
"enabled": true, //set to false to disable vardiff functionality
"minDifficulty": 8, //minimum difficulty. below 16 will cause problems
"maxDifficulty": 1000, //network difficulty will be used if it is lower than this
"targetTime": 60, //target time per share (i.e. try to get 1 share per this many seconds)
"retargetTime": 10, //check to see if we should retarget every this many seconds
"variancePercent": 10 //allow average time to very this % from target without retarget
"enabled": true,
"minDifficulty": 16,
"maxDifficulty": 1000,
"targetTime": 30,
"retargetTime": 120,
"variancePercent": 20
},
"p2p": {
"enabled": true,
"host": "localhost",

View File

@ -55,12 +55,12 @@ fs.readdirSync('coins').forEach(function(file){
var shareData = JSON.stringify(data);
if (isValidBlock)
if (data.solution && !isValidBlock)
logDebug(coinOptions.name, 'client', 'We thought a block solution was found but it was rejected by the daemon, share data: ' + shareData);
else if (isValidBlock)
logDebug(coinOptions.name, 'client', 'Block found, share data: ' + shareData);
else if (isValidShare)
logDebug(coinOptions.name, 'client', 'Valid share submitted, share data: ' + shareData);
else if (data.solution)
logDebug(coinOptions.name, 'client', 'We thought a block solution was found but it was rejected by the daemon, share data: ' + shareData);
else
logDebug(coinOptions.name, 'client', 'Invalid share submitted, share data: ' + shareData)