Bugfix: Correctly calculate priority when inputs are mined after dependent transactions enter the memory pool #7149

Closed
wants to merge 9 commits into
from

Projects

None yet

5 participants

@luke-jr
Member
luke-jr commented Dec 1, 2015

This is needed to restore proper CreateNewBlock functioning for unconfirmed transaction chains.

@morcos morcos referenced this pull request Dec 2, 2015
Merged

Lower bound priority #7008

@luke-jr
Member
luke-jr commented Jan 13, 2016

Added RPC tests and fixed an additional bug found with them. This should now be ready for merging to master and 0.12.

@sipa
Member
sipa commented Jun 2, 2016

Weak concept NACK. I don't think we should be spending effort on maintaining the old priority system (which was completely arbirary anyway).

@luke-jr luke-jr added a commit to bitcoinknots/bitcoin that referenced this pull request Jun 9, 2016
@luke-jr luke-jr Merge #7149 bugfix_priority fbe78b2
@luke-jr luke-jr added a commit to bitcoinknots/bitcoin that referenced this pull request Jun 27, 2016
@luke-jr luke-jr Merge #7149 bugfix_priority cf9b330
morcos and others added some commits Jun 30, 2015
@morcos @luke-jr morcos Add GetStartingPriority method to reliably get the original priority …
…of a transaction in the mempool
c6c89bb
@morcos @luke-jr morcos Change GetPriority calculation to dynamically update
Track the value of inputs that get confirmed in the chain and keep a cached value of priority at a given height and return current priority by only assuming these in chain inputs are aging.
8aa1ae2
@morcos @luke-jr morcos Add consistency check for on the fly priority calculations 98ef483
@luke-jr luke-jr QA: Add test for priority via getrawmempool 2d72888
@luke-jr luke-jr QA: Enable testing priority via getblocktemplate as well cc260ed
@luke-jr luke-jr QA: Extend txn_priority test to check across a reorganisation 6704f5b
@luke-jr luke-jr Bugfix: Correct off-by-one errors in getrawmempool startingpriority a…
…nd currentpriority

- Since the transaction arrives after block N, its starting priority is that for block N+1.
- The current priority is likewise as considered for mining the next block.
92c18a4
@luke-jr luke-jr Bugfix: rpc-tests/txn_priority: When connecting disconnected nodes, t…
…heir mempools may not sync, so only sync blocks
fab562b
@luke-jr luke-jr CTxMemPool::check: Use height+1 for priority comparison, since height…
… is not guaranteed to work
ae93a95
@fanquake
Contributor

Closing this due to inactivity.

@fanquake fanquake closed this Jan 12, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment