Take into account ac_name to calculate total txs
This commit is contained in:
@@ -33,6 +33,8 @@ if ($acname) {
|
|||||||
$cli .= " -ac_name=$acname";
|
$cli .= " -ac_name=$acname";
|
||||||
# TODO: assumes all HSC's will have a blocktime of 60s
|
# TODO: assumes all HSC's will have a blocktime of 60s
|
||||||
$perday = 1440;
|
$perday = 1440;
|
||||||
|
} else {
|
||||||
|
$acname = 'HUSH3';
|
||||||
}
|
}
|
||||||
|
|
||||||
my $gethash = "$cli getblockhash";
|
my $gethash = "$cli getblockhash";
|
||||||
@@ -64,8 +66,8 @@ while (1) {
|
|||||||
my $time = qx{$cli getblock $last |grep time|cut -d: -f2| sed 's/,//g'};
|
my $time = qx{$cli getblock $last |grep time|cut -d: -f2| sed 's/,//g'};
|
||||||
chomp($time);
|
chomp($time);
|
||||||
# TODO: This is Linux-only and assumes new (not legacy) dir
|
# TODO: This is Linux-only and assumes new (not legacy) dir
|
||||||
my $line1 = qx{grep --text height=$prev ~/.hush/HUSH3/debug.log};
|
my $line1 = qx{grep --text height=$prev ~/.hush/$acname/debug.log};
|
||||||
my $line2 = qx{grep --text height=$blocks ~/.hush/HUSH3/debug.log};
|
my $line2 = qx{grep --text height=$blocks ~/.hush/$acname/debug.log};
|
||||||
my $txs_per_day = 2 * $perday; # default estimate is 2 txs per block, on average
|
my $txs_per_day = 2 * $perday; # default estimate is 2 txs per block, on average
|
||||||
my $total_txs = 0;
|
my $total_txs = 0;
|
||||||
#print "line1: $line1\n";
|
#print "line1: $line1\n";
|
||||||
|
|||||||
Reference in New Issue
Block a user