Commit Graph
100 Commits
Author SHA1 Message Date
jl777 4342e69bf4 -print and tweak error triggers 2018-04-24 18:38:07 +03:00
jl777 9840ae3921 Test 2018-04-24 17:42:46 +03:00
jl777 a17a8c5200 Typo 2018-04-24 17:15:34 +03:00
jl777 5794aafc48 +printout 2018-04-24 16:39:04 +03:00
jl777 599c2c5f4d Allow a block from the future to be rejected without being permabanned 2018-04-24 16:19:15 +03:00
jl777 924afa4c3f Test config 2018-04-24 15:54:52 +03:00
jl777 ed67a29bcd Fix 2018-04-24 15:36:34 +03:00
jl777 f045635ebc Fix 2018-04-24 15:35:48 +03:00
jl777 4825cbeb68 komodo_validate_interest expiration in CTxMemPool::removeExpired 2018-04-24 15:32:15 +03:00
jl777 e868c9ea24 Test 2018-04-24 14:49:41 +03:00
jl777 531b92932a Allow future block to not trigger severe rejection 2018-04-24 14:47:21 +03:00
jl777 2a5ffc0486 Test 2018-04-24 11:02:09 +03:00
jl777 e530155687 Test 2018-04-24 10:53:04 +03:00
jl777 9f6cb8f05e futureblock flag 2018-04-24 10:49:04 +03:00
jl777 2fea1c9723 -print 2018-04-24 00:00:45 +03:00
jl777 43ef3068d1 10 second window for notary mining 2018-04-23 23:47:48 +03:00
jl777 8d725ab46f -komodo_requesthash 2018-04-23 22:59:51 +03:00
jl777 d1cd2af5f4 Test 2018-04-23 22:56:28 +03:00
jl777 82b4714bee Test 2018-04-23 22:55:27 +03:00
jl777 5d9f111967 Test 2018-04-23 22:52:16 +03:00
jl777 f65a34b970 Test 2018-04-23 22:32:35 +03:00
jl777 37091e704e 30 seconds margin for notary mining 2018-04-23 21:33:18 +03:00
jl777 bddeaf5e44 Detect missing prevblock and request it.
On some systems, the chain can get into a state where it has the hash
for a prevblock, but not the prevblock itself.

This condition was treated as a horrible error, but since it can
happen, it is better to return a simple error and let the block get
processed when it comes back again.
2018-04-23 21:09:47 +03:00
jl777 d9cf734306 Test 2018-04-23 20:56:24 +03:00
jl777 027cfdce15 Test 2018-04-23 20:49:28 +03:00
jl777 367265ab29 Test 2018-04-23 20:32:50 +03:00
jl777 ecc342b6da Test 2018-04-23 20:25:32 +03:00
jl777 b80fef6f77 Test 2018-04-23 20:18:46 +03:00
jl777 99dd19d43e Test 2018-04-23 20:04:54 +03:00
jl777 e450b1ceaf Test 2018-04-23 20:02:40 +03:00
jl777 161f617de4 komodo_requestedhash request 2018-04-23 19:58:16 +03:00
jl777 71f2c6969c Revert 2018-04-23 11:23:05 +03:00
jl777 3099c9ca23 Tweak sync constants 2018-04-23 11:17:36 +03:00
jl777 7cae836aa8 Fix 2018-04-23 10:42:14 +03:00
jl777 1e57ae08ca Fix 2018-04-23 10:40:06 +03:00
jl777 882c4cfeef Syntax 2018-04-23 10:38:44 +03:00
jl777 f8a07170af Revert half of windows headers filter 2018-04-23 10:28:16 +03:00
jl777 3ede6dd335 Test 2018-04-22 17:14:27 +03:00
jl777 346d96b956 Test 2018-04-22 17:13:18 +03:00
jl777 307d443cca Test 2018-04-22 17:11:35 +03:00
jl777 05c2ba6371 split out asset chain p2p port from roc port 2018-04-22 17:10:35 +03:00
jl777 67899f2e2c -prints 2018-04-22 16:44:35 +03:00
jl777 59490d6f23 Test 2018-04-22 16:39:33 +03:00
jl777 34775d996c Test 2018-04-22 16:36:00 +03:00
jl777 9c117b3df7 Test 2018-04-22 16:19:51 +03:00
jl777 4735f5b201 Test 2018-04-22 16:16:27 +03:00
jl777 5cf29e5bfd Test 2018-04-22 16:16:14 +03:00
jl777 3a19bc18f5 Test 2018-04-22 16:14:19 +03:00
jl777 9edf27ec05 +print 2018-04-22 16:05:56 +03:00
jl777 3ac6a0a66d Debug 2018-04-22 15:33:42 +03:00
jl777 bbd0d75a7e prohibit same timestamps for staked blocks 2018-04-22 12:54:42 +03:00
jl777 f307157143 Reduce prev block not found to return false from state.DoS error 2018-04-22 11:07:39 +03:00
jl777 d6eb511b21 -print 2018-04-22 00:08:08 +03:00
jl777 8999ab66f1 Test 2018-04-21 23:18:52 +03:00
jl777 e6c99a7ab9 Split out no previndex from invalid prevblock 2018-04-21 23:06:56 +03:00
jl777 971f0b0237 Merge branch 'dev' into jl777 2018-04-21 19:53:06 +03:00
jl777 d859438b65 Merge 2018-04-21 19:52:27 +03:00
jl777 e3e263b59d -print 2018-04-21 19:17:16 +03:00
jl777 a695f47ee3 Merge branch 'dev' into jl777 2018-04-21 17:26:35 +03:00
jl777 28b18b6127 Test 2018-04-21 16:55:03 +03:00
jl777 985907e4ec Fix too strict 2018-04-21 16:36:54 +03:00
jl777 2c089649f0 Fix 2018-04-21 16:19:16 +03:00
jl777 b0bf5d0282 -print 2018-04-21 15:55:59 +03:00
jl777 64b45b7192 Test 2018-04-21 15:16:44 +03:00
jl777 a36c1a705a +print 2018-04-21 14:53:16 +03:00
jl777 41427baa04 Test 2018-04-21 11:36:15 +03:00
jl777 a36fcdf53d Test 2018-04-21 11:28:37 +03:00
jl777 e3b04fea0c Return error if prevblock != best block 2018-04-21 10:43:41 +03:00
jl777 0d8e3988e9 Immediate submit block from miner 2018-04-20 22:44:01 +03:00
jl777 c685d69264 Test 2018-04-20 22:27:11 +03:00
jl777 bd30f12363 Test 2018-04-20 22:21:13 +03:00
jl777 350d40c747 Test 2018-04-20 22:19:56 +03:00
jl777 45af4c09d8 Test 2018-04-20 22:19:20 +03:00
jl777 ebb59e6038 Test 2018-04-20 22:10:25 +03:00
jl777 42a7467aa6 Revert network size check to ASSETCHAINS_STAKED 2018-04-20 21:59:48 +03:00
jl777 f225a9badd Test 2018-04-20 19:44:18 +03:00
jl777 e76694e44c test 2018-04-20 19:43:35 +03:00
jl777 f4b367397a Fix polarity of compare 2018-04-20 17:42:58 +03:00
jl777 2ac071da47 KOMODO_LIMITED_NETWORKSIZE
Prior commits relate to supporting a limited size network.

It looks like there is an edge case where it is possible for a hash to
be in the mapIndex, without a pindex. If a block with such a hash is
tried to be Accepted, the AcceptBlockHeader returns true but with a
null pindex, and AcceptBlock fails.

The code says that this indicates that the hash was added from a
blockheader without a block, but I didn’t see that happening. In any
case, it happens a lot on a 2 node network. So much so that if one node
is just mining, before too long the other node will not accept the
block and once that happens, no subsequent block would work as the
prior block is missing.

Of course, with more nodes, these blocks will be around a lot more and
likely it won’t be such an issue, but not so sure that it doesn’t
require restarting the node to get it back on track again.

These prior commits implement a KOMODO_LIMITED_NETWORKSIZE logic where
if it sees that a block has come in which is in the mapIndex but has no
pindex, it automatically addtoblockindex.

There is one edge case still left where both the current block being
processed and its previous block are in this limbo state. Since the
pindex is not mapped to the block, it is problematic to retrieve the
CBlock for the pprev and without the valid pprev the pindex will have a
null pprev and no nHeight set. It is possible that all the other code
will properly deal with such a case and automatically fix it, but
rather than rely on that, in such a case the automatic addtoblockindex
is not done.

A node in such a state would need to exit and restart or somehow fill
in the data from other nodes.

From what I can tell, the above is the main reason why the PoS/PoW
networks were having problems staying in sync. Since even with one
mining node, it was just a matter of time before the other node got
stuck, with more than one mining node we end up with independent forks
that won’t reconcile until the node is restarted.
2018-04-20 17:16:06 +03:00
jl777 a772476349 Test 2018-04-20 16:55:34 +03:00
jl777 3128a24af6 Test 2018-04-20 13:35:16 +03:00
jl777 563d507c61 Test 2018-04-20 13:30:54 +03:00
jl777 cfb55edbbc Test 2018-04-20 13:25:22 +03:00
jl777 7b025a4790 Test 2018-04-20 13:24:48 +03:00
jl777 dd66e3af3a Test 2018-04-20 13:20:26 +03:00
jl777 e16d22ee0f Test 2018-04-20 13:13:18 +03:00
jl777 9464ac21bc Test 2018-04-20 13:03:27 +03:00
jl777 820600d13f Test 2018-04-20 12:43:08 +03:00
jl777 b85130925b Test 2018-04-20 12:42:27 +03:00
jl777 66dd02d288 Test 2018-04-20 12:32:39 +03:00
jl777 b1d85b23e6 Test 2018-04-20 12:21:01 +03:00
jl777 519578c9c9 Test 2018-04-20 12:17:02 +03:00
jl777 0f102ea7e3 Test 2018-04-20 12:14:11 +03:00
jl777 5295318ec4 Test 2018-04-20 12:08:51 +03:00
jl777 8dcf7f3fab Test 2018-04-20 12:07:57 +03:00
jl777 b5d0fe2e24 Test 2018-04-20 11:55:06 +03:00
jl777 b92dfb1eb5 Test 2018-04-20 11:53:02 +03:00
jl777 7732dbc26b Test 2018-04-20 11:34:37 +03:00
jl777 9850dffd80 Test 2018-04-20 11:30:27 +03:00
jl777 fd835d9406 Test 2018-04-20 11:29:12 +03:00