Revisit #4846 (comments were to wait until headers first had been tested sufficiently first!)
Improve logic for advertising blocks #8958
pull rebroad wants to merge 1 commits into bitcoin:master from rebroad:BetterBroadcastLogic changing 1 files +2 −1-
rebroad commented at 3:42 PM on October 18, 2016: contributor
- laanwj added the label P2P on Oct 18, 2016
-
paveljanik commented at 7:54 PM on October 18, 2016: contributor
OMG, do we really use the similar code somewhere else? Using ternary operator twice on one line and without parens is getting closer to the programmers hell!
-
rebroad commented at 12:29 AM on October 19, 2016: contributor
@paveljanik It's similar to 2 * 3 + 1 which, as far as I know, most people don't use brackets for as it's understood what order the numbers are combined.
Rebased.
- rebroad closed this on Oct 19, 2016
- rebroad reopened this on Oct 19, 2016
- rebroad force-pushed on Oct 19, 2016
-
dcousens commented at 12:58 AM on October 19, 2016: contributor
Personally, I'd highly appreciate a constant variable above for readability.
-
gmaxwell commented at 1:13 AM on October 19, 2016: contributor
This won't compile, it's reintroducing a checkpoints dependency (nBlockEstimate) that was recently removed by 0278fb5 in PR #8865 (the whole block is not entered if we're in initial block download, and if we're not... then any block we'd consider would already be past the estimator that it gives us).
For future PR's it would be much more helpful to write what a change intends to accomplish (and, especially, WHY) in terms more specific than "improve". :) Hopefully every change is an improvement.
- rebroad force-pushed on Oct 19, 2016
-
rebroad commented at 3:29 AM on October 19, 2016: contributor
- dcousens approved
-
sdaftuar commented at 1:19 PM on October 23, 2016: member
NACK. This is thoroughly busted -- first you need cs_main here to do what you're trying, second you can't skip announcing a block to a peer just because you think it's on a longer (not necessarily more work) chain than yours!
-
MarcoFalke commented at 6:09 PM on December 6, 2016: member
Needs rebase if still relevant.
- rebroad renamed this:
Improve logic for advertising blocks
WIP: Improve logic for advertising blocks
on Dec 11, 2016 - rebroad force-pushed on Dec 11, 2016
- rebroad renamed this:
WIP: Improve logic for advertising blocks
Improve logic for advertising blocks
on Dec 11, 2016 -
Improve logic for advertising blocks 9bde4175c6
- rebroad force-pushed on Dec 11, 2016
- fanquake closed this on May 17, 2017
- DrahtBot locked this on Sep 8, 2021