diff options
| author | bitflash-maintainer <noreply@bitflash.invalid> | 2026-08-11 13:10:57 +0000 |
|---|---|---|
| committer | bitflash-maintainer <noreply@bitflash.invalid> | 2026-08-19 22:48:26 +0000 |
| commit | db2692dcd8984fe0e5a2a6a796f7b3cbee216c32 (patch) | |
| tree | 45e00acf1557d6d1604aed08dd670766679b8b98 /src/net.cpp | |
| parent | ec1627c68d3b6abdbf84b2a816d98bdd4ce113c9 (diff) | |
pool: gate jobs on peer height, not tip age
The sync gate compared the tip timestamp against 30 minutes. That cannot
distinguish "we are not synced" from "the network is slow", and it failed
in both directions on the same day.
A pool mining its own fork keeps its tip fresh, so the check passed for
the whole of heights 3966-4085 -- 120 consecutive blocks, all orphaned,
5890.50 BTF of payouts voided, and nothing in the log to say so. Then,
once the pool stopped finding blocks, the same check refused to issue
jobs against a tip that was the network's own best. The pool is ~90% of
the hashrate, so nobody else could move the chain either: stale tip, no
jobs; no jobs, stale tip.
Gate on the height peers announce in their version message instead.
Median, so one peer cannot stall us with an absurd claim, and a block of
slack to match WarnIfBehind. Peers predating the announcement report -1
and are ignored; with no reports at all we mine our best chain, which is
what the node does anyway without a pool attached.
(cherry picked from commit 4e76e34f37a82c0885f75db7dfb9e49db410171d)
Diffstat (limited to 'src/net.cpp')
0 files changed, 0 insertions, 0 deletions