Wladimir J. van der Laan
2ef5ffa59a
Merge pull request #6915
...
2d8860e
Fix removeForReorg to use MedianTimePast (Suhas Daftuar)
b7fa4aa
Don't call removeForReorg if DisconnectTip fails (Suhas Daftuar)
7e49f5f
Track coinbase spends in CTxMemPoolEntry (Suhas Daftuar)
bb8ea1f
removeForReorg calls once-per-disconnect-> once-per-reorg (Matt Corallo)
474b84a
Make indentation in ActivateBestChainStep readable (Matt Corallo)
b0a064c
Fix comment in removeForReorg (Matt Corallo)
9b060e5
Fix removal of time-locked transactions during reorg (Matt Corallo)
0c9959a
Add failing test checking timelocked-txn removal during reorg (Matt Corallo)
2015-12-01 13:17:34 +01:00
Wladimir J. van der Laan
327291af02
Merge pull request #6914
...
114b581
Prevector type (Pieter Wuille)
2015-12-01 10:22:14 +01:00
Gregory Maxwell
c143c499c8
Merge pull request #7072
...
996d311
[RPC] Add transaction size to JSON output (Nick)
2015-11-30 22:58:43 -08:00
Suhas Daftuar
7e49f5f8b4
Track coinbase spends in CTxMemPoolEntry
...
This allows us to optimize CTxMemPool::removeForReorg.
2015-11-30 13:12:53 -05:00
Gregory Maxwell
e20672479e
Remove mruset as it is no longer used.
2015-11-30 12:53:48 +01:00
Nick
996d3117c7
[RPC] Add transaction size to JSON output
...
This may be useful for blockchain explorers.
2015-11-28 17:06:56 +03:00
Pieter Wuille
eece63fa72
Switch blocks to a constant-space Merkle root/branch algorithm.
...
This switches the Merkle tree logic for blocks to one that runs in constant (small) space.
The old code is moved to tests, and a new test is added that for various combinations of
block sizes, transaction positions to compute a branch for, and mutations:
* Verifies that the old code and new code agree for the Merkle root.
* Verifies that the old code and new code agree for the Merkle branch.
* Verifies that the computed Merkle branch is valid.
* Verifies that mutations don't change the Merkle root.
* Verifies that mutations are correctly detected.
2015-11-27 15:36:52 +01:00
Wladimir J. van der Laan
d8368a07ba
Merge pull request #7095
...
4ec3561
Replace scriptnum_test's normative ScriptNum implementation (Wladimir J. van der Laan)
2015-11-27 14:16:55 +01:00
Wladimir J. van der Laan
5ca149a3db
Merge pull request #7053
...
2e29e7e
Globals: Remove a bunch of Params() calls from main.cpp: (Jorge Timón)
2015-11-27 13:29:54 +01:00
Wladimir J. van der Laan
e92377fa7f
Merge pull request #6134
...
e304432
Pass reference to estimateSmartFee and cleanup whitespace (Suhas Daftuar)
56106a3
Expose RPC calls for estimatesmart functions (Alex Morcos)
e93a236
add estimateSmartFee to the unit test (Alex Morcos)
6303051
EstimateSmart functions consider mempool min fee (Alex Morcos)
f22ac4a
Increase success threshold for fee estimation to 95% (Alex Morcos)
4fe2823
Change wallet and GUI code to use new smart fee estimation calls. (Alex Morcos)
22eca7d
Add smart fee estimation functions (Alex Morcos)
2015-11-27 12:59:37 +01:00
Wladimir J. van der Laan
05d591839f
Merge pull request #5967
...
072e2f8
Alter assumptions in CCoinsViewCache::BatchWrite (Alex Morcos)
2015-11-27 12:44:00 +01:00
Wladimir J. van der Laan
4ec3561eb3
Replace scriptnum_test's normative ScriptNum implementation
...
Compare against the scriptnum from Bitcoin Core 0.10 instead of OpenSSL.
Closes #7086 .
2015-11-25 13:59:49 +01:00
Jorge Timón
2e29e7e247
Globals: Remove a bunch of Params() calls from main.cpp:
...
1) Chainparams: Explicit CChainParams arg for main:
-AcceptBlock
-AcceptBlockHeader
-ActivateBestChain
-ConnectTip
-InitBlockIndex
-LoadExternalBlockFile
-VerifyDB parametric constructor
2) Also pickup more Params()\. in main.cpp
3) Pass nPruneAfterHeight explicitly to new FindFilesToPrune() in main.cpp
2015-11-23 12:14:40 +01:00
Gregory Maxwell
616d61b20d
Merge pull request #6851
...
3e7c891
Optimisation: Store transaction list order in memory rather than compute it every need (Luke Dashjr)
2015-11-20 18:52:44 -08:00
Luke Dashjr
3e7c89196c
Optimisation: Store transaction list order in memory rather than compute it every need
...
Huge performance improvement (450%) for zapwallettxes
2015-11-21 01:48:25 +00:00
Alex Morcos
c0353064dd
Change GetPriority calculation.
...
Compute the value of inputs that already are in the chain at time of mempool entry and only increase priority due to aging for those inputs. This effectively changes the CTxMemPoolEntry's GetPriority calculation from an upper bound to a lower bound.
2015-11-19 21:44:35 -05:00
Alex Morcos
072e2f8644
Alter assumptions in CCoinsViewCache::BatchWrite
...
Previously it would break if you flushed a parent cache while there was a child cache referring to it. This change will allow the flushing of parent caches.
2015-11-18 12:03:50 -05:00
Wladimir J. van der Laan
73fa5e6043
Merge pull request #6932
...
1cf3dd8
Add unit test for UpdateCoins (Alex Morcos)
03c8282
Make CCoinsViewTest behave like CCoinsViewDB (Alex Morcos)
14470f9
ModifyNewCoins saves database lookups (Alex Morcos)
2015-11-18 17:37:58 +01:00
Alex Morcos
e587bc3fd9
Implement helper class for CTxMemPoolEntry constructor
...
This is only for unit tests.
2015-11-16 20:41:32 -05:00
Gregory Maxwell
87ee0e2dbc
Merge pull request #6986
...
6bc9e40
Chainparams: Explicit CChainParams arg for miner: (Jorge Timón)
598e494
Chainparams: Explicit CChainParams arg for main (pre miner): (Jorge Timón)
2015-11-16 17:00:11 -08:00
Alex Morcos
e93a236d7a
add estimateSmartFee to the unit test
2015-11-16 15:33:06 -05:00
Alex Morcos
f22ac4a22c
Increase success threshold for fee estimation to 95%
...
This provides more conservative estimates and reacts more quickly to a backlog.
Unfortunately the unit test for fee estimation depends on the success threshold (and the decay) chosen; also modify the unit test for the new default success thresholds.
2015-11-16 15:33:06 -05:00
Pieter Wuille
6e18268616
Switch to libsecp256k1-based validation for ECDSA
2015-11-15 16:06:57 +01:00
Pieter Wuille
114b5812f6
Prevector type
2015-11-13 18:15:20 +01:00
Alex Morcos
a78e6eaf5c
Fix bug in mempool_tests unit test
2015-11-13 10:50:49 -05:00
Alex Morcos
1cf3dd80a6
Add unit test for UpdateCoins
2015-11-12 09:55:12 -05:00
Alex Morcos
03c82826f9
Make CCoinsViewTest behave like CCoinsViewDB
2015-11-11 21:19:19 -05:00
Jorge Timón
6bc9e4056b
Chainparams: Explicit CChainParams arg for miner:
...
-BitcoinMiner
-CreateNewBlock
-GenerateBitcoins
-ProcessBlockFound
2015-11-11 13:21:17 +01:00
Jorge Timón
598e494587
Chainparams: Explicit CChainParams arg for main (pre miner):
...
-ProcessNewBlock
-TestBlockValidity
2015-11-11 13:21:17 +01:00
MarcoFalke
536766c903
[trivial] New DEFAULT_MIN_RELAY_TX_FEE = 1000
2015-11-09 21:00:16 +01:00
MarcoFalke
5f46a7d068
transaction_tests: Be more strict checking dust
...
* Don't allow off-by-one or more
* Make clear dust is coupled with minRelayTxFee
* Check rounding for odd values
2015-11-09 21:00:16 +01:00
Gregory Maxwell
d1c3762ae8
Revert "Revert "Enable policy enforcing GetMedianTimePast as the end point of lock-time constraints""
...
This reverts commit 8537ecdfc4
.
2015-11-03 17:14:09 +00:00
Wladimir J. van der Laan
8fe30fb4d1
Merge pull request #6928
...
40cd32e
Revert "Add rules--presently disabled--for using GetMedianTimePast as endpoint for lock-time calculations" (Gregory Maxwell)
8537ecd
Revert "Enable policy enforcing GetMedianTimePast as the end point of lock-time constraints" (Gregory Maxwell)
2015-11-02 04:44:47 +01:00
Gregory Maxwell
8537ecdfc4
Revert "Enable policy enforcing GetMedianTimePast as the end point of lock-time constraints"
...
This reverts commit dea8d21fc6
.
2015-11-01 20:05:16 +00:00
Wladimir J. van der Laan
7497e805bd
tests: Initialize networking on windows
2015-11-01 11:45:06 +01:00
Daniel Kraft
0be387a536
unittest: fix test for null tx input
...
Update the unittest that is meant to catch a transaction that is invalid
because it has a null input. The old test failed not because of that
but because it was considered a coinbase with too large script. This is
already checked with a different test, though.
The new test is *not* a coinbase since it has two inputs, but one of
them is null. This really checks the corresponding code path in
CheckTransaction.
2015-10-27 20:11:56 +01:00
Wladimir J. van der Laan
c8322ff7f7
Merge pull request #6888
...
143d173
Use BOOST_CHECK_MESSAGE() rather than BOOST_CHECK() in alerts_tests.cpp and initialize strMiscWarning before calling PartitionCheck()." (Eric Lombrozo)
2015-10-26 17:25:19 +01:00
Eric Lombrozo
143d173969
Use BOOST_CHECK_MESSAGE() rather than BOOST_CHECK() in alerts_tests.cpp and initialize strMiscWarning before calling PartitionCheck()."
2015-10-25 05:47:02 -04:00
Mark Friedenbach
dea8d21fc6
Enable policy enforcing GetMedianTimePast as the end point of lock-time constraints
...
Transactions are not allowed in the memory pool or selected for inclusion in a block until their lock times exceed chainActive.Tip()->GetMedianTimePast(). However blocks including transactions which are only mature under the old rules are still accepted; this is *not* the soft-fork required to actually rely on the new constraint in production.
2015-10-23 09:02:24 -07:00
Jeff Garzik
46f74379b8
Merge pull request #6873
2015-10-23 09:01:22 -04:00
Jeff Garzik
3795e8152b
leveldbwrapper file rename to dbwrapper.*
2015-10-22 21:33:06 -04:00
Jeff Garzik
8587b23038
leveldbwrapper symbol rename: Remove "Level" from class, etc. names
2015-10-22 21:02:20 -04:00
Wladimir J. van der Laan
f2c869aef2
Merge pull request #6848
...
c6824f8
Add DERSIG transaction test cases (J Ross Nicoll)
2015-10-22 18:02:17 +02:00
Wladimir J. van der Laan
3b20e239c6
Merge pull request #6722
...
58254aa
Fix stale comment in CTxMemPool::TrimToSize. (Matt Corallo)
2bc5018
Fix comment formatting tabs (Matt Corallo)
8abe0f5
Undo GetMinFee-requires-extra-call-to-hit-0 (Matt Corallo)
9e93640
Drop minRelayTxFee to 1000 (Matt Corallo)
074cb15
Add reasonable test case for mempool trimming (Matt Corallo)
d355cf4
Only call TrimToSize once per reorg/blocks disconnect (Matt Corallo)
794a8ce
Implement on-the-fly mempool size limitation. (Matt Corallo)
e6c7b36
Print mempool size in KB when adding txn (Matt Corallo)
241d607
Add CFeeRate += operator (Matt Corallo)
e8bcdce
Track (and define) ::minRelayTxFee in CTxMemPool (Matt Corallo)
9c9b66f
Fix calling mempool directly, instead of pool, in ATMP (Matt Corallo)
49b6fd5
Add Mempool Expire function to remove old transactions (Pieter Wuille)
78b82f4
Reverse the sort on the mempool's feerate index (Suhas Daftuar)
2015-10-21 08:50:16 +02:00
Wladimir J. van der Laan
e26a3f6713
Merge pull request #6235
...
55a8975
Chainparams: Translations: DRY: options and error strings (Jorge Timón)
f3525e2
Chainparams: Replace CBaseChainParams::Network enum with string constants (suggested by Wladimir) (Jorge Timón)
2015-10-20 17:06:28 +02:00
Jorge Timón
f3525e24e3
Chainparams: Replace CBaseChainParams::Network enum with string constants (suggested by Wladimir)
2015-10-20 14:22:44 +02:00
J Ross Nicoll
c6824f8a90
Add DERSIG transaction test cases
...
Add test cases for DERSIG flag enforcement against transactions.
2015-10-18 17:27:41 +01:00
Matt Corallo
8abe0f5658
Undo GetMinFee-requires-extra-call-to-hit-0
2015-10-14 12:44:18 -07:00
Wladimir J. van der Laan
9caaf6ed22
Merge pull request #6777
...
dcd8e27
Refer to obfuscate_key via pointer in peripheral CLevelDB classes (James O'Beirne)
1488506
Add tests for gettxoutsetinfo, CLevelDBBatch, CLevelDBIterator (James O'Beirne)
0fdf8c8
Handle obfuscation in CLevelDBIterator (James O'Beirne)
3499ce1
Encapsulate CLevelDB iterators cleanly (Pieter Wuille)
2015-10-13 12:23:45 +02:00
Wladimir J. van der Laan
01f74999e3
Merge pull request #6798
...
700f52e
Clarification of unit test build instructions. (Eric Lombrozo)
2015-10-13 11:35:24 +02:00