Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
2630 commits
Select commit Hold shift + click to select a range
9007785
Disabled TRTL
MoneroOcean Mar 15, 2023
1d29469
Improved thottling
MoneroOcean Mar 16, 2023
9a61997
Reduced pool stats updates
MoneroOcean Mar 23, 2023
c3bd351
Clean old altblocks
MoneroOcean Mar 23, 2023
713a37a
Clean old altblocks
MoneroOcean Mar 23, 2023
efe3c18
Clean old altblocks
MoneroOcean Mar 23, 2023
78abe60
Clean old altblocks
MoneroOcean Mar 23, 2023
9273be3
Clean old altblocks
MoneroOcean Mar 23, 2023
17cc995
Clean old altblocks
MoneroOcean Mar 23, 2023
84e5591
Clean old altblocks
MoneroOcean Mar 23, 2023
9d35ff7
Clean old altblocks
MoneroOcean Mar 23, 2023
3338d79
Clean old altblocks
MoneroOcean Mar 23, 2023
0f707b4
Clean old altblocks
MoneroOcean Mar 23, 2023
a7d6753
Allow unlock many blocks at once
MoneroOcean May 30, 2023
2661438
Disabled tube
MoneroOcean May 30, 2023
d4c96a0
Revert "Disabled tube"
MoneroOcean Jun 18, 2023
5b0dd89
Added new module
MoneroOcean Jun 24, 2023
4e3fe0c
ZEPH support
MoneroOcean Jun 24, 2023
f85be9b
ZEPH support
MoneroOcean Jun 25, 2023
6e68a12
ZEPH support
MoneroOcean Jun 25, 2023
2497cbd
ZEPH support
MoneroOcean Jun 25, 2023
9de0fa1
Improved rx seed switch
MoneroOcean Jun 25, 2023
9eeb66c
Better ZEPH support
MoneroOcean Jun 25, 2023
7a723cd
Script for mass manual block payments
MoneroOcean Jun 26, 2023
a5c7e4a
Count changed blocks
MoneroOcean Jun 27, 2023
2d855de
Count changed blocks
MoneroOcean Jun 27, 2023
25b7e59
Delay non emergency coin switch for 60 secs
MoneroOcean Jun 28, 2023
74674b6
Reduced memory usage
MoneroOcean Jul 5, 2023
6f79a8a
Added BTRM
MoneroOcean Jul 16, 2023
493d84b
Added XNA
MoneroOcean Aug 26, 2023
7514adf
Added XNA
MoneroOcean Aug 26, 2023
87093a0
Added XNA
MoneroOcean Aug 26, 2023
3316292
Added XNA
MoneroOcean Aug 26, 2023
2a7003b
Added XNA
MoneroOcean Aug 27, 2023
9c6b574
Added XNA
MoneroOcean Aug 27, 2023
621fd7c
Added XNA
MoneroOcean Aug 27, 2023
1944eae
Updated coin utils
MoneroOcean Aug 28, 2023
7f110a4
Fixed BTRM reward
MoneroOcean Sep 1, 2023
bf445ea
Fixed BTRM reward
MoneroOcean Sep 1, 2023
07c4b84
Workaround for grft
MoneroOcean Sep 4, 2023
8e70bbd
Removed graft
MoneroOcean Sep 4, 2023
94396ff
Added CLORE support
MoneroOcean Sep 5, 2023
b742db4
Added CLORE support
MoneroOcean Sep 6, 2023
132232c
Fixed CLORE reward
MoneroOcean Sep 6, 2023
10cbff9
Fixed CLORE reward
MoneroOcean Sep 6, 2023
92b548b
XLA fork support
MoneroOcean Sep 26, 2023
b795a1f
Added ZEPH fork support
MoneroOcean Oct 1, 2023
8ed8430
Fixed rewards for RVN
MoneroOcean Nov 8, 2023
9fb58e0
Debug RTM reward
MoneroOcean Nov 8, 2023
68b8c80
Debug RTM reward
MoneroOcean Nov 8, 2023
423b4bc
Debug RTM reward
MoneroOcean Nov 8, 2023
d9a05ad
Debug RTM reward
MoneroOcean Nov 8, 2023
1b24002
Debug RTM reward
MoneroOcean Nov 8, 2023
14c9b23
Debug RTM reward
MoneroOcean Nov 8, 2023
aa62fba
Debug RTM reward
MoneroOcean Nov 8, 2023
f927028
Updated xmr daemon
MoneroOcean Dec 17, 2023
5bf17b6
Invalidate too high share throttle
MoneroOcean Dec 31, 2023
fd5e21c
Invalidate too high share throttle
MoneroOcean Dec 31, 2023
fe88188
Invalidate too high share throttle
MoneroOcean Dec 31, 2023
804311e
Invalidate too high share throttle
MoneroOcean Dec 31, 2023
1347ead
kawpow4 algo support for GPU with 4GB RAM
MoneroOcean Jan 19, 2024
147c674
Updated hashing utils
MoneroOcean Mar 4, 2024
8279300
Reduced monmero usage by excluding not supported coins
MoneroOcean Mar 11, 2024
0c70097
Updated software
MoneroOcean May 2, 2024
cca7ab5
Updated for Ubuntu 24.04
MoneroOcean May 3, 2024
11f5ef2
Updated for Ubuntu 24.04
MoneroOcean May 3, 2024
76c08d9
Updated tools
MoneroOcean May 3, 2024
cb97146
Better handle new pools
MoneroOcean May 3, 2024
5904439
Updated for Ubuntu 24.04
MoneroOcean May 5, 2024
d1ec2b8
Removed old buffer usage
MoneroOcean May 5, 2024
3e6b3a9
Close connections by default
MoneroOcean May 7, 2024
ada0bc4
Updated for Ubuntu 24.04
MoneroOcean May 8, 2024
a4ca55e
Updated for Ubuntu 24.04
MoneroOcean May 8, 2024
15a4927
Catch fs exception
MoneroOcean May 8, 2024
41211e2
Catch fs exception
MoneroOcean May 8, 2024
1a824bd
Added KCN coin support
MoneroOcean May 27, 2024
a43fd9e
Added KCN coin support
MoneroOcean May 27, 2024
ed8268c
Added KCN coin support
MoneroOcean May 27, 2024
9cd23f7
Added KCN coin support
MoneroOcean May 27, 2024
aa4b3fb
Improved Flex algo speed
MoneroOcean May 29, 2024
44d2378
XEQ algo update
MoneroOcean May 29, 2024
8bb9c3d
Fix for XEQ
MoneroOcean May 29, 2024
abce81a
Adds kcn dev reward to bt
MoneroOcean May 31, 2024
ee0b1df
Adds kcn dev reward to bt
MoneroOcean May 31, 2024
3e67dcc
Adds kcn dev reward to bt
MoneroOcean May 31, 2024
f8c28db
KCN fix
MoneroOcean May 31, 2024
e3e2751
KCN fix
MoneroOcean May 31, 2024
7b5874c
KCN fix
MoneroOcean May 31, 2024
ac2fecd
KCN fix
MoneroOcean Jun 1, 2024
2076c47
KCN fix
MoneroOcean Jun 1, 2024
70df0f6
RTM fix
MoneroOcean Jun 1, 2024
89a513d
Adjusted KCN reward
MoneroOcean Jun 1, 2024
5678268
Fixed KCN reward
MoneroOcean Jun 1, 2024
6265b14
Fixed KCN blob contruction in all cases
MoneroOcean Jun 1, 2024
fdeb0e1
Added 1 job daemon build in case of out of memory fail
MoneroOcean Jun 1, 2024
18ef685
Fixed KCN blob contruction in all cases
MoneroOcean Jun 1, 2024
16a1a48
Fixed KCN blob contruction in all cases
MoneroOcean Jun 2, 2024
ca51c40
Fixed KCN blob contruction in all cases
MoneroOcean Jun 2, 2024
b84c4cc
Fixed KCN blob contruction in all cases
MoneroOcean Jun 2, 2024
2198c76
Fixed KCN blob contruction in all cases
MoneroOcean Jun 2, 2024
94139d2
Fixed RTM blob contruction
MoneroOcean Jun 2, 2024
c664b00
More strict block checks
MoneroOcean Jun 4, 2024
bfc1cae
Updated RTM utils
MoneroOcean Jun 4, 2024
8e0df18
Add "perf" option to set starting diff based on algo-perf
Spudz76 Jun 5, 2024
27d1d15
Merge pull request #126 from Spudz76/pr-add-perf-diff
MoneroOcean Jun 7, 2024
e62c973
Adjusted PR
MoneroOcean Jun 7, 2024
797c6c4
Fixed /usr/bin/node link
MoneroOcean Jun 7, 2024
985b816
Added ZEPH update support
MoneroOcean Jul 13, 2024
5160177
Added SAL support
MoneroOcean Jul 19, 2024
fa8d6d6
Added SAL support
MoneroOcean Jul 19, 2024
9deacd9
Added SAL support
MoneroOcean Jul 19, 2024
281bb22
Added SAL support
MoneroOcean Jul 19, 2024
ac10e1a
Added SAL support
MoneroOcean Jul 19, 2024
6bd58b5
Added SAL support
MoneroOcean Jul 19, 2024
0bd00c8
Added SAL support
MoneroOcean Jul 19, 2024
e1d8e2b
Added SAL support
MoneroOcean Jul 19, 2024
8ff2616
Added SAL support
MoneroOcean Jul 19, 2024
0f75cf0
Added SAL support
MoneroOcean Jul 19, 2024
5a61e5b
Added SAL support
MoneroOcean Jul 20, 2024
249842c
Added SAL support
MoneroOcean Jul 20, 2024
1b1736d
Added SAL support
MoneroOcean Jul 20, 2024
b36ff7d
Added SAL support
MoneroOcean Jul 20, 2024
e39a919
Added SAL support
MoneroOcean Jul 20, 2024
6b9f84f
Updated email client code
MoneroOcean Jul 21, 2024
778f1be
Added whitelist support
MoneroOcean Jul 26, 2024
52486c9
Updated utils
MoneroOcean Aug 11, 2024
789cfb5
Updated utils
MoneroOcean Aug 11, 2024
9a9d48f
Updated utils
MoneroOcean Aug 11, 2024
5925dba
Disable local share reverify in case there is external verifier
MoneroOcean Sep 24, 2024
3924fe8
ZEPH 2.0 support
MoneroOcean Oct 7, 2024
bbbce82
Updated to monero 18.3.4
MoneroOcean Oct 21, 2024
f71d1a4
Fixed SAL parse after fork
MoneroOcean Nov 5, 2024
c3b24a5
Fixed missing ufw package
MoneroOcean Dec 2, 2024
b29b893
Added vim
MoneroOcean Dec 2, 2024
821afb3
Fixed buffer overflow
MoneroOcean Dec 6, 2024
518327d
SAL v0.7 support and removed RingCT XHV support
MoneroOcean Dec 19, 2024
2fff2ef
Added helper to delete blocks
MoneroOcean May 5, 2025
810183e
TARI support
MoneroOcean May 5, 2025
8c18b54
Fixed error with null being object
MoneroOcean May 5, 2025
e5ad630
Improved error reporting for block submit
MoneroOcean May 5, 2025
54ab253
Improved error reporting for block submit
MoneroOcean May 5, 2025
5318d3c
Fixed TXM block id
MoneroOcean May 6, 2025
5c8e0d1
Improved main block submit
MoneroOcean May 7, 2025
be07e2d
New helper function
MoneroOcean May 7, 2025
0207b65
Fixed XMR block diff reporting
MoneroOcean May 7, 2025
ab4bcf1
New helper
MoneroOcean May 8, 2025
b9648e4
TXM support
MoneroOcean May 8, 2025
3089d8d
Fixed error
MoneroOcean May 8, 2025
e977e8c
Submit TXM blocks
MoneroOcean May 8, 2025
5238cfc
Fixed TXM mining
MoneroOcean May 8, 2025
1198002
Currect TXM height reporting
MoneroOcean May 9, 2025
1aedef6
Currect TXM height reporting
MoneroOcean May 9, 2025
67cb0e5
Updated monero version
MoneroOcean May 9, 2025
5cb77b0
Fixed reward for TXN
MoneroOcean May 9, 2025
8430717
Minor fixes
MoneroOcean May 9, 2025
3c2967a
Improved TXM reporting
MoneroOcean May 10, 2025
406b19c
Compute TXM diff
MoneroOcean May 10, 2025
3e7663d
Fix height for TXM
MoneroOcean May 10, 2025
c1ddb47
Add TXM diff
MoneroOcean May 10, 2025
d77618c
Updated TXM to XTM
MoneroOcean May 11, 2025
a50bda6
Updated TXM to XTM
MoneroOcean May 11, 2025
320b8d4
Added rewards to XTM top header
MoneroOcean May 25, 2025
2393858
Fixed bug
MoneroOcean May 25, 2025
2de06fc
Fixed bug
MoneroOcean May 25, 2025
27dac42
Fixed bug
MoneroOcean May 25, 2025
f6e29e2
Fixed bug
MoneroOcean May 25, 2025
1d08b2e
Adjusted TARI block submit
MoneroOcean May 25, 2025
e0466b4
Fixed XTM block selection
MoneroOcean May 25, 2025
ad69815
Fixed XTM block selection
MoneroOcean May 25, 2025
cfad7e4
Fixed XTM block selection
MoneroOcean May 25, 2025
b03a11a
Fixed XTM block selection
MoneroOcean May 25, 2025
8cee77b
Fixed XTM block selection
MoneroOcean May 25, 2025
011f94e
Fixed XTM diff
MoneroOcean May 26, 2025
8e2b4d3
Fixed XTM diff
MoneroOcean May 26, 2025
976598e
Fixed XTM diff
MoneroOcean May 26, 2025
35638ce
New script
MoneroOcean May 26, 2025
eba7c8e
Fixed XTM last block
MoneroOcean May 26, 2025
50e7e78
Fixed XTM last block
MoneroOcean May 26, 2025
8eaec75
Fixed XTM last block
MoneroOcean May 26, 2025
cf4b999
Fixed XTM last block
MoneroOcean May 26, 2025
ff9c42b
Fixed XTM last block
MoneroOcean May 26, 2025
55f7975
Fixed XTM last block
MoneroOcean May 26, 2025
835632b
Fixed XTM last block
MoneroOcean May 26, 2025
c81920d
Fixed XTM last block
MoneroOcean May 26, 2025
34e4b59
Fixed XTM last block
MoneroOcean May 26, 2025
b2de270
Fixed XTM last block
MoneroOcean May 26, 2025
46111f4
Fixed XTM last block
MoneroOcean May 26, 2025
443ff15
Fixed XTM last block
MoneroOcean May 26, 2025
9540231
Fixed XTM last block
MoneroOcean May 26, 2025
d5e7477
Adjusted for grpc proxy change
MoneroOcean May 26, 2025
bff0f4c
Added XTM-T pilot implementation
MoneroOcean May 27, 2025
8f8e3dd
Bug fix
MoneroOcean May 27, 2025
4a8520a
Adjusted XTM block diff reporting
MoneroOcean May 28, 2025
bd5890b
Added height
MoneroOcean May 28, 2025
0249ef4
Fixed bt
MoneroOcean May 28, 2025
2e4e9f9
Potential fix
MoneroOcean May 28, 2025
4a1db2b
Potential fix
MoneroOcean May 28, 2025
9f0303d
Fixed XTM-T block hash
MoneroOcean May 28, 2025
714765c
Updated to uint64 strings
MoneroOcean May 29, 2025
7e554ae
Fixed getting XTM-T bt in case it was updated in flight
MoneroOcean May 29, 2025
6438232
Fixed XTM-T block submission
MoneroOcean May 30, 2025
d110c8e
Removed extra debug
MoneroOcean May 31, 2025
0f0e66c
Fixed XTM height string
MoneroOcean May 31, 2025
30905b5
Diff add
MoneroOcean May 31, 2025
dc25665
Fixed XTM diff and height
MoneroOcean Jun 1, 2025
91163a2
Fixed XTM diff and height
MoneroOcean Jun 1, 2025
9c4f40a
New utility scripts
MoneroOcean Jun 1, 2025
73781d0
Fixed bug
MoneroOcean Jun 3, 2025
b9db2ee
Fixed XTM BT
MoneroOcean Jun 4, 2025
f2cb392
More XTM info
MoneroOcean Jun 5, 2025
c2ff530
More XTM info
MoneroOcean Jun 5, 2025
901a796
More XTM info
MoneroOcean Jun 5, 2025
b80acf2
More reliable XTM blocks
MoneroOcean Jun 5, 2025
a4a3714
More XTM info
MoneroOcean Jun 5, 2025
f243c6f
More XTM info
MoneroOcean Jun 5, 2025
f0f2f73
More reliable XTM blocks
MoneroOcean Jun 5, 2025
cf4f4af
More reliable XTM blocks
MoneroOcean Jun 5, 2025
55afb14
More reliable XTM blocks
MoneroOcean Jun 5, 2025
4f4b0eb
More reliable XTM blocks
MoneroOcean Jun 5, 2025
f08f03f
More reliable XTM blocks
MoneroOcean Jun 5, 2025
5507900
More reliable XTM blocks
MoneroOcean Jun 5, 2025
9bd00f3
More reliable XTM blocks
MoneroOcean Jun 5, 2025
ca2abfb
More reliable XTM blocks
MoneroOcean Jun 5, 2025
b63c860
Fixed ARQ blob type
MoneroOcean Jun 7, 2025
b81f701
ARQ support
MoneroOcean Jun 9, 2025
00cbbac
Updated ZEPH
MoneroOcean Jun 11, 2025
694bfe6
Fixed for ZEPH
MoneroOcean Jun 12, 2025
a657c89
Fixed for ZEPH
MoneroOcean Jun 12, 2025
e2ed2ec
Fixed XTM port
MoneroOcean Jun 12, 2025
076e8fa
Disabled XTNC
MoneroOcean Jun 19, 2025
8f78d0f
Fixed block header call
MoneroOcean Jun 21, 2025
f1a0652
Fixed block header call
MoneroOcean Jun 21, 2025
4921f1d
Moved to single step BT for XTM-T
MoneroOcean Jun 25, 2025
5c423f2
Disabled check for XWP
MoneroOcean Jul 7, 2025
6f1d394
Disabled check for XWP
MoneroOcean Jul 7, 2025
7fda321
Disabled check for XWP
MoneroOcean Jul 8, 2025
6db9d21
Fixed XTM block template
MoneroOcean Aug 11, 2025
ad6b66e
c29 xtm mining support
MoneroOcean Sep 4, 2025
16dbc1d
c29 xtm mining support
MoneroOcean Sep 4, 2025
97e6763
Updated Tari C29 support to match luckypool/lolminer implementation
MoneroOcean Sep 13, 2025
e85700a
Fixed lolminer reponse
MoneroOcean Sep 16, 2025
9546169
Fixed c29_cycle_hash
MoneroOcean Sep 16, 2025
16bfc1b
Fixed XTM_C hash
MoneroOcean Oct 1, 2025
ef47ada
SaviumOne support
MoneroOcean Oct 7, 2025
92a3328
Restored ZEPH tx check
MoneroOcean Oct 9, 2025
fd589db
Updated XMR daemon
MoneroOcean Oct 11, 2025
a0793c2
Fixed SAL after fork
MoneroOcean Oct 14, 2025
96c8c02
SAL fixes
MoneroOcean Oct 15, 2025
382f766
SAL fixes
MoneroOcean Oct 15, 2025
e61f636
Fixed SAL
MoneroOcean Oct 16, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
222 changes: 101 additions & 121 deletions README.md

Large diffs are not rendered by default.

35 changes: 0 additions & 35 deletions SQL_MIGRATIONS.md

This file was deleted.

2 changes: 2 additions & 0 deletions block_notify.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/bin/bash
/bin/echo 18081 | /bin/nc -N localhost 2223
79 changes: 79 additions & 0 deletions block_share_dumps/calc_mo_cvs.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
"use strict";

if (Boolean(process.stdin.isTTY) || process.argv.length !== 3) {
console.log("Usage: unxz -c <block hash>.cvs.xz | node calc_mo_cvs.js <your Monero wallet address>");
console.log(" wget -O - https://block-share-dumps.moneroocean.stream/<block hash>.cvs.xz | unxz -c | node calc_mo_cvs.js <your Monero wallet address>");
process.exit(1);
}

const my_wallet = process.argv[2].slice(-16);

let stdin = "";

process.stdin.on('data', function(data) {
stdin += data.toString();
});

function human_hashrate(hashes) {
const power = Math.pow(10, 2 || 0);
if (hashes > 1000000000000) return String(Math.round((hashes / 1000000000000) * power) / power) + " TH/s";
if (hashes > 1000000000) return String(Math.round((hashes / 1000000000) * power) / power) + " GH/s";
if (hashes > 1000000) return String(Math.round((hashes / 1000000) * power) / power) + " MH/s";
if (hashes > 1000) return String(Math.round((hashes / 1000) * power) / power) + " KH/s";
return Math.floor( hashes || 0 ) + " H/s"
};

process.stdin.on('end', function() {
let pplns_window = 0;
let oldest_timestamp = 0;
let newest_timestamp = 0;

let my_share_count = 0;
let my_xmr_diff = 0;
let my_xmr_diff_payed = 0;
let my_coin_raw_diff = {};
let my_coin_xmr_diff = {};

for (let line of stdin.split("\n")) {
if (line.substring(0, 1) == "#") continue;
const items = line.split('\t');
if (items.length < 7) {
console.error("Skipped invalid line: " + line);
continue;
}
const wallet = items[0];
const timestamp = parseInt(items[1], 16);
const raw_diff = parseInt(items[2]);
const count = parseInt(items[3]);
const coin = items[4];
const xmr_diff = parseInt(items[5]);
const xmr_diff_payed = items[6] == "" ? xmr_diff : parseInt(items[6]);
pplns_window += xmr_diff;
if (!oldest_timestamp || timestamp < oldest_timestamp) oldest_timestamp = timestamp;
if (newest_timestamp < timestamp) newest_timestamp = timestamp;
if (wallet === my_wallet) {
my_share_count += count;
my_xmr_diff += xmr_diff;
my_xmr_diff_payed += xmr_diff_payed;
if (!(coin in my_coin_raw_diff)) my_coin_raw_diff[coin] = 0;
my_coin_raw_diff[coin] += raw_diff;
if (!(coin in my_coin_xmr_diff)) my_coin_xmr_diff[coin] = 0;
my_coin_xmr_diff[coin] += xmr_diff;
}
}

console.log("PPLNS window size: \t" + ((newest_timestamp - oldest_timestamp)/1000/60/60).toFixed(2) + " hours");
console.log("PPLNS window size: \t" + pplns_window + " xmr hashes");
console.log("Pool XMR normalized hashrate: \t" + human_hashrate(pplns_window / (newest_timestamp - oldest_timestamp) * 1000));
console.log("");
console.log("Your submitted shares: \t" + my_share_count);
console.log("Your payment: \t" + ((my_xmr_diff_payed / pplns_window) * 100).toFixed(6) + "% (" + my_xmr_diff_payed + " xmr hashes)");
console.log("Your XMR normalized hashrate: \t" + human_hashrate(my_xmr_diff_payed / (newest_timestamp - oldest_timestamp) * 1000));
console.log("");
console.log("You mined these coins:");
for (let coin of Object.keys(my_coin_raw_diff).sort()) {
console.log("\t" + coin + ": " + my_coin_raw_diff[coin] + " raw coin hashes (" + ((my_coin_xmr_diff[coin] / my_xmr_diff) * 100).toFixed(6) + "% of XMR normalized hashrate)");
}

process.exit(0);
});
75 changes: 75 additions & 0 deletions block_share_dumps/calc_mo_cvs_top.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
"use strict";

if (Boolean(process.stdin.isTTY) || process.argv.length !== 2) {
console.log("Usage: unxz -c <block hash>.cvs.xz | node calc_mo_cvs_top.js");
console.log(" wget -O - https://block-share-dumps.moneroocean.stream/<block hash>.cvs.xz | unxz -c | node calc_mo_cvs_top.js");
process.exit(1);
}

let stdin = "";

process.stdin.on('data', function(data) {
stdin += data.toString();
});

function human_hashrate(hashes) {
const power = Math.pow(10, 2 || 0);
if (hashes > 1000000000000) return String(Math.round((hashes / 1000000000000) * power) / power) + " TH/s";
if (hashes > 1000000000) return String(Math.round((hashes / 1000000000) * power) / power) + " GH/s";
if (hashes > 1000000) return String(Math.round((hashes / 1000000) * power) / power) + " MH/s";
if (hashes > 1000) return String(Math.round((hashes / 1000) * power) / power) + " KH/s";
return Math.floor( hashes || 0 ) + " H/s"
};

process.stdin.on('end', function() {
let pplns_window = 0;
let oldest_timestamp = 0;
let newest_timestamp = 0;

let wallets = {};

let my_share_count = 0;
let my_xmr_diff = 0;
let my_xmr_diff_payed = 0;
let my_coin_raw_diff = {};
let my_coin_xmr_diff = {};

for (let line of stdin.split("\n")) {
if (line.substring(0, 1) == "#") continue;
const items = line.split('\t');
if (items.length < 7) {
console.error("Skipped invalid line: " + line);
continue;
}
const wallet = items[0];
const timestamp = parseInt(items[1], 16);
const raw_diff = parseInt(items[2]);
const count = parseInt(items[3]);
const coin = items[4];
const xmr_diff = parseInt(items[5]);
const xmr_diff_payed = items[6] == "" ? xmr_diff : parseInt(items[6]);
pplns_window += xmr_diff;
if (!oldest_timestamp || timestamp < oldest_timestamp) oldest_timestamp = timestamp;
if (newest_timestamp < timestamp) newest_timestamp = timestamp;
if (!(wallet in wallets)) wallets[wallet] = {
share_count: 0,
xmr_diff: 0,
xmr_diff_payed: 0,
coin_raw_diff: {},
coin_xmr_diff: {},
};
wallets[wallet].share_count += count;
wallets[wallet].xmr_diff += xmr_diff;
wallets[wallet].xmr_diff_payed += xmr_diff_payed;
if (!(coin in wallets[wallet].coin_raw_diff)) wallets[wallet].coin_raw_diff[coin] = 0;
wallets[wallet].coin_raw_diff[coin] += raw_diff;
if (!(coin in wallets[wallet].coin_xmr_diff)) wallets[wallet].coin_xmr_diff[coin] = 0;
wallets[wallet].coin_xmr_diff[coin] += xmr_diff;
}

for (let wallet of Object.keys(wallets).sort((a, b) => (wallets[a].xmr_diff < wallets[b].xmr_diff) ? 1 : -1)) {
console.log(wallet + ": " + wallets[wallet].xmr_diff);
}

process.exit(0);
});
16 changes: 0 additions & 16 deletions coinConfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,21 +8,5 @@
"name": "Monero",
"mixIn": 4,
"shortCode": "XMR"
},
"krb": {
"funcFile": "./lib/coins/krb.js",
"paymentFile": "./payment_systems/krb.js",
"sigDigits": 1000000000000,
"name": "Karbowanec",
"mixIn": 4,
"shortCode": "KRB"
},
"aeon": {
"funcFile": "./lib/coins/aeon.js",
"paymentFile": "./payment_systems/aeon.js",
"sigDigits": 1000000000000,
"name": "Aeon Coin",
"mixIn": 4,
"shortCode": "AEON"
}
}
3 changes: 3 additions & 0 deletions config_example.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
{
"pool_id": 0,
"eth_pool_support": 1,
"worker_num": 0,
"bind_ip": "127.0.0.1",
"hostname": "testpool.com",
"db_storage_path": "CHANGEME",
"verify_shares_host": null,
"coin": "xmr",
"mysql": {
"connectionLimit": 20,
Expand Down
91 changes: 0 additions & 91 deletions debug_scripts/block_add.js

This file was deleted.

19 changes: 0 additions & 19 deletions debug_scripts/block_locker.js

This file was deleted.

Loading