aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2018-05-18fixup! ui: Support wallets loaded dynamicallyJoão Barbosa
2018-05-16ui: Support wallets loaded dynamicallyJoão Barbosa
2018-05-16ui: Remove unnecessary variable fFirstWalletJoão Barbosa
2018-05-16Merge #10740: [wallet] `loadwallet` RPC - load wallet at runtimeWladimir J. van der Laan
cd53981 [docs] Add release notes for `loadwallet` RPC. (John Newbery) a46aeb6 [wallet] [tests] Test loadwallet (John Newbery) 5d15260 [wallet] [rpc] Add loadwallet RPC (John Newbery) 876eb64 [wallet] Pass error message back from CWallet::Verify() (John Newbery) e0e90db [wallet] Add CWallet::Verify function (John Newbery) 470316c [wallet] setup wallet background flushing in WalletInit directly (John Newbery) 59b87a2 [wallet] Fix potential memory leak in CreateWalletFromFile (John Newbery) Pull request description: Adds a `loadwallet` RPCs. This allows wallets to be loaded dynamically during runtime without having to stop-start the node with new `-wallet` params. Includes functional tests and release notes. Limitations: - currently this functionality is only available through the RPC interface. - wallets loaded in this way will not be displayed in the GUI. Tree-SHA512: f80dfe32b77f5c97ea3732ac538de7d6ed7e7cd0413c2ec91096bb652ad9bccf05d847ddbe81e7cd3cd44eb8030a51a5f00083871228b1b9b0b8398994f6f9f1
2018-05-16Merge #13023: Fix some concurrency issues in ActivateBestChain()Wladimir J. van der Laan
dd435ad Add unit tests for signals generated by ProcessNewBlock() (Jesse Cohen) a3ae8e6 Fix concurrency-related bugs in ActivateBestChain (Jesse Cohen) ecc3c4a Do not unlock cs_main in ABC unless we've actually made progress. (Matt Corallo) Pull request description: Originally this PR was just to add tests around concurrency in block validation - those tests seem to have uncovered another bug in ActivateBestChain - this now fixes that bug and adds tests. ActivateBestChain (invoked after a new block is validated) proceeds in steps - acquiring and releasing cs_main while incrementally disconnecting and connecting blocks to sync to the most work chain known (FindMostWorkChain()). Every time cs_main is released the result of FindMostWorkChain() can change - but currently that value is cached across acquisitions of cs_main and only refreshed when an invalid chain is explored. It needs to be refreshed every time cs_main is reacquired. The test added in https://github.com/bitcoin/bitcoin/pull/13023/commits/6094ce73045fe0b4654ff94327c2059512af88fb will occasionally fail without the commit fixing this issue https://github.com/bitcoin/bitcoin/pull/13023/commits/26bfdbaddbb9f13864deb7241c6d513f22c5ab62 Original description below -- After a bug discovered where UpdatedBlockTip() notifications could be triggered out of order (#12978), these unit tests check certain invariants about these signals. The scheduler test asserts that a SingleThreadedSchedulerClient processes callbacks fully and sequentially. The block validation test generates a random chain and calls ProcessNewBlock from multiple threads at random and in parallel. ValidationInterface callbacks verify that the ordering of BlockConnected BlockDisconnected and UpdatedBlockTip events occur as expected. Tree-SHA512: 4102423a03d2ea28580c7a70add8a6bdb22ef9e33b107c3aadef80d5af02644cdfaae516c44933924717599c81701e0b96fbf9cf38696e9e41372401a5ee1f3c
2018-05-16[docs] Add release notes for `loadwallet` RPC.John Newbery
2018-05-16[wallet] [tests] Test loadwalletJohn Newbery
Add testcases to wallet_multiwallet.py to test the new `loadwallet` RPC method.
2018-05-16[wallet] [rpc] Add loadwallet RPCJohn Newbery
The new `loadwallet` RPC method allows an existing wallet to be loaded dynamically at runtime. `unloadwallet` and `createwallet` are not implemented. Notably, `loadwallet` can only be used to load existing wallets, not to create a new wallet.
2018-05-16[wallet] Pass error message back from CWallet::Verify()John Newbery
Pass an error message back from CWallet::Verify(), and call InitError/InitWarning from WalletInit::Verify(). This means that we can call CWallet::Verify() independently from WalletInit and not have InitErrors printed to stdout. It also means that the error can be reported to the user if dynamic wallet load fails.
2018-05-16[wallet] Add CWallet::Verify functionJohn Newbery
This allows a single wallet to be verified. Prior to this commit, all wallets were verified together by the WalletInit::Verify() function at start-up. Individual wallet verification will be done when loading wallets dynamically at runtime.
2018-05-16Add unit tests for signals generated by ProcessNewBlock()Jesse Cohen
After a recent bug discovered in callback ordering in MainSignals, this test checks invariants in ordering of BlockConnected / BlockDisconnected / UpdatedChainTip signals
2018-05-16Merge #11491: [gui] Add proxy icon in statusbarJonas Schnelli
73cd5b25b [gui] Add proxy icon in statusbar (Cristian Mircea Messel) Pull request description: Relates to #7734 ![image](https://user-images.githubusercontent.com/226170/33406640-8ea700c6-d576-11e7-9d69-fde9a696c219.png) Please ignore the wrong alpha in the screenshot, I couldn't get the screenshot alpha right :( I plan to extend this feature in future PRs to include: - custom Tor icon - clickable icon which opens network settings Old proposals, dropped in favor of current ![image](https://user-images.githubusercontent.com/226170/32688635-979ef690-c6dd-11e7-8869-49da7e0f0a11.png) ![proxy_preview](https://user-images.githubusercontent.com/226170/31521305-99c43f22-afb1-11e7-9daf-d1ed6347daa8.png) ![image](https://user-images.githubusercontent.com/226170/31680585-72706098-b37d-11e7-88ad-028c4c723f42.png) Tree-SHA512: e5f18c20c0be292256a3e78c91cdf390a3b6084346a192a8170460f706f5b6cd198ba5b0035798a85a442fe7f262cf1c2350064670085ff8f473f880ab5ba589
2018-05-15[gui] Add proxy icon in statusbarCristian Mircea Messel
2018-05-15[wallet] setup wallet background flushing in WalletInit directlyJohn Newbery
WalletInit::Start calls postInitProcess() for each wallet. Previously each call to postInitProcess() would attempt to schedule wallet background flushing. Just start wallet background flushing once from WalletInit::Start().
2018-05-15[wallet] Fix potential memory leak in CreateWalletFromFileJohn Newbery
Fix proposed by ryanofsky in https://github.com/bitcoin/bitcoin/pull/12647#discussion_r174875670
2018-05-15Merge #13125: scheduler: Add Clang thread safety annotations for variables ↵MarcoFalke
guarded by m_cs_callbacks_pending 244f4baf0f scheduler: Add Clang thread safety annotations for variables guarded by m_cs_callbacks_pending (practicalswift) Pull request description: Add Clang thread safety annotations for variables guarded by `m_cs_callbacks_pending`. Tree-SHA512: 5c4aa14d1918ff119f945084820f7c1c5618e2a38d8bea8ebbfa6acddbccdacfea81fa61f1f796f8b1fcf57f5e3112da63b9bd0fa97fc9a9ef427fc361945e02
2018-05-15Merge #12881: Minor optimizations to bech32::Decode(); add tests.Wladimir J. van der Laan
60f61f9 Tighten up bech32::Decode(); add tests. (murrayn) Pull request description: Just a few minor optimizations to bech32::Decode(): 1) optimize the order and logic of the conditionals 2) get rid of subsequent '(c < 33 || c > 126)' check which is redundant (already performed above) 3) add a couple more bech32 tests (mixed-case) Tree-SHA512: e41af834c8f6b7d34c22c28b724df42c60f72e00df616e70a12efbc4271d15d80627fe1bc36845caf29f615c238499a566298a863cbe119fef457287231053c8
2018-05-15Merge #13234: Break circular dependency: chain -> pow -> chainWladimir J. van der Laan
5b35b92 Break circular dependency: chain -> pow -> chain (Ben Woosley) Pull request description: chain.h does not actually depend on the methods defined in pow.h, just its include of consensus/params.h, which is standalone and can be included instead. Confirmed by inspection and successful build. Tree-SHA512: fd2a182aad72c62ca54c9ac028d8f3f4416e4d0a5b8ed0a23fb52496d9291a6eeed5252f5e8b8ef4e47ca28bea3d2ed6ff3c41ddb92d102af02a895c9787100c
2018-05-14Break circular dependency: chain -> pow -> chainBen Woosley
chain.h does not actually depend on the methods defined in pow.h, just its include of consensus/params.h, which is standalone and can be included instead. Confirmed by inspection and successful build.
2018-05-14Merge #13158: [Qt]: Improve sendcoinsdialog readabilityMarcoFalke
f08a385590 [qt]: changes sendcoinsdialog's box layout for improved readability. (marcoagner) Pull request description: I'm addressing two (probably duplicate) issues: https://github.com/bitcoin/bitcoin/issues/11606 and https://github.com/bitcoin/bitcoin/issues/10613. Some points worth noting: - I've tried to balance the proposed changes on both issues without going too far and remaining a bit conservative. It will be easier to improve based on suggestions where necessary. - I preferred to maintain a layout that doesn't ask for an address truncation because, in my view, this wallet should be conservative on this. - I didn't follow the idea of aligning the amounts to the right for finding it more natural (and minimalist) to read the information without having to map alignments. Additionally, that approach seems to need more `<hr />`'s (or similar) in order to help the user to map information, which ended up cluttering the box too much (specially with multiple recipients). Thus, I preferred to just give some more space between recipients. Let me know if there are better ideas on this. Visually, I went from this (current): ![screenshot from 2018-05-03 15-11-30](https://user-images.githubusercontent.com/5016303/39581859-16abec82-4edc-11e8-86d3-eb722f8a7ed6.png) To this: ![screenshot from 2018-05-03 15-15-41](https://user-images.githubusercontent.com/5016303/39582066-96856adc-4edc-11e8-804c-468aec44cc8d.png) As a side note, while doing this, I thought about a better way to show fees and found there's already a PR on this (https://github.com/bitcoin/bitcoin/pull/12189) and thought it is Tree-SHA512: e94b740fab6c1babd853a97be65c3b6f86ec174c975a926fde66b147f7a47e0cf0fa10f7255ba92aaba68c76a80dde8c688008179a34705a9799bf24d3c5cd46
2018-05-14Merge #12963: Fix Clang Static Analyzer warningsMarcoFalke
159c32d1f1 Add assertion to guide static analyzers. Clang Static Analyzer needs this guidance. (practicalswift) fd447a6efe Fix dead stores. Values were stored but never read. Limit scope. (practicalswift) Pull request description: Fix Clang Static Analyzer warnings reported by @kallewoof in #12961: * Fix dead stores. Values were stored but never read. * Add assertion to guide static analyzers. See #12961 for details. Tree-SHA512: 83dbec821f45217637316bee978e7543f2d2caeb7f7b0b3aec107fede0fff8baa756da8f6b761ae0d38537740839ac9752f6689109c38a4b05c0c041aaa3a1fb
2018-05-14Merge #13197: util: warn about ignored recursive -includeconf callsWladimir J. van der Laan
2352aa9 test: Ensure that recursive -includeconf produces appropriate warnings (Karl-Johan Alm) c5bcc7d util: warn about recursive -includeconf arguments in configuration files (Karl-Johan Alm) Pull request description: This is a follow-up PR to #10267, and addresses https://github.com/bitcoin/bitcoin/pull/10267#issuecomment-387546144. ~~I am adding extra work for @jnewbery in #12755 here -- maybe I should just rebase on top of that, but not sure what the appropriate approach is here.~~ Tree-SHA512: 87f0c32436b70424e33616ffb88d7cb699f90d6a583a10237e224b28fc936d6a9df95536c8c52ee8546b3942da92b2a357e61bf87e00d1462bc10d46d3bee352
2018-05-14Merge #11689: mempool: Fix missing locking in CTxMemPool::check(…) and ↵MarcoFalke
CTxMemPool::setSanityCheck(…) 47782b49e6 Add Clang thread safety analysis annotations (practicalswift) 0e2dfa8a65 Fix missing locking in CTxMemPool::setSanityCheck(double dFrequency) (practicalswift) 6bc5b7100b Fix missing locking in CTxMemPool::check(const CCoinsViewCache *pcoins) (practicalswift) Pull request description: Fix missing locking in `CTxMemPool::check(const CCoinsViewCache *pcoins)`: * reading variable `mapTx` requires holding mutex `cs` * reading variable `mapNextTx` requires holding mutex `cs` * reading variable `nCheckFrequency` requires holding mutex `cs` Fix missing locking in `CTxMemPool::setSanityCheck(double dFrequency)`: * writing variable `nCheckFrequency` requires holding mutex `cs` Tree-SHA512: ce7c365ac89225223fb06e6f469451b121acaa499f35b21ad8a6d2a266c91194639b3703c5428871be033d4f5f7be790cc297bd8c25b2e0c59345ef09c3693d0
2018-05-14Merge #13127: wallet: Add Clang thread safety annotations for variables ↵MarcoFalke
guarded by cs_db 56921f9369 wallet: Add Clang thread safety annotations for variables guarded by cs_db (practicalswift) Pull request description: Add Clang thread safety annotations for variables guarded by `cs_db`. Tree-SHA512: d59723598e918143f36408b4f49d31138b5d8968ba191472f6a207a63af147627f21e48fd6cc1606dd901d8a58183271e65ea4346a380db3c09e404764a28063
2018-05-14Merge #13005: Make --enable-debug to pick better optionsWladimir J. van der Laan
9e49db2 Make --enable-debug to pick better options (Evan Klitzke) Pull request description: Cherry-picked (and rebased) 94189645e67f364c4445d62e2b00c282d885cbbf from the "up for grabs" PR: "[build] Make --enable-debug pick better options" (#12695). See previous review in #12695. Tree-SHA512: a93cdadcf13e2ef8519acb1ce4f41ce95057a388347bb0a86a5c164dc7d0b0d14d4bb2a466082d5a100b8d50de65c605c40abaed555e8ea77c99e28800a34439
2018-05-14Merge #13081: wallet: Add compile time checking for cs_wallet runtime ↵MarcoFalke
locking assertions 66b0b1b2a6 Add compile time checking for all cs_wallet runtime locking assertions (practicalswift) Pull request description: Add compile time checking for `cs_wallet` runtime locking assertions. This PR is a subset of #12665. The PR was broken up to make reviewing easier. The intention is that literally all `EXCLUSIVE_LOCKS_REQUIRED`/`LOCKS_EXCLUDED`:s added in this PR should follow either directly or indirectly from `AssertLockHeld(…)`/`AssertLockNotHeld(…)`:s already existing in the repo. Consider the case where function `A(…)` contains `AssertLockHeld(cs_foo)` (without first locking `cs_foo` in `A`), and that `B(…)` calls `A(…)` (without first locking `cs_main`): * It _directly_ follows that: `A(…)` should have an `EXCLUSIVE_LOCKS_REQUIRED(cs_foo)` annotation. * It _indirectly_ follows that: `B(…)` should have an `EXCLUSIVE_LOCKS_REQUIRED(cs_foo)` annotation. Tree-SHA512: d561d89e98a823922107e56dbd493f0f82e22edac91e51e6422f17daf2b446a70c143b7b157ca618fadd33d0ec63eb7a57dde5a83bfdf1fc19d71459b43e21fd
2018-05-14Merge #13161: wallet: Reset BerkeleyDB handle after connection failsWladimir J. van der Laan
b6f0b4d wallet: Improve logging when BerkeleyDB environment fails to close (Tim Ruffing) 264c643 wallet: Reset BerkeleyDB handle after connection fails (Tim Ruffing) Pull request description: According to the BerkeleyDB docs, the DbEnv handle may not be accessed after close() has been called. This change ensures that we create a new handle after close() is called. This avoids a segfault when the first connection attempt fails and then a second connection attempt tries to call open() on the already closed DbEnv handle. Without the patch, bitcoindd reliably crashes in the second call to `set_lg_dir()` after `close()` if there is an issue with the database: ``` 2018-05-03T13:27:21Z Bitcoin Core version v0.16.99.0-a024a1841-dirty (debug build) [...] 2018-05-03T13:27:21Z Using wallet directory /home/tim/.bitcoin 2018-05-03T13:27:21Z init message: Verifying wallet(s)... 2018-05-03T13:27:21Z Using BerkeleyDB version Berkeley DB 4.8.30: (April 9, 2010) 2018-05-03T13:27:21Z Using wallet wallet.dat 2018-05-03T13:27:21Z BerkeleyEnvironment::Open: LogDir=/home/tim/.bitcoin/database 2018-05-03T13:27:21Z BerkeleyEnvironment::Open: Error -30974 opening database environment: DB_RUNRECOVERY: Fatal error, run database recovery 2018-05-03T13:27:21Z Moved old /home/tim/.bitcoin/database to /home/tim/.bitcoin/database.1525354041.bak. Retrying. 2018-05-03T13:27:21Z BerkeleyEnvironment::Open: LogDir=/home/tim/.bitcoin/database ErrorFile=/home/tim/.bitcoin/db.log [1] 14533 segmentation fault (core dumped) ./src/bitcoind ``` After the fix: ``` 2018-05-03T17:19:32Z Bitcoin Core version v0.16.99.0-cc09e3bd0-dirty (release build) [...] 2018-05-03T17:19:32Z Using wallet directory /home/tim/.bitcoin 2018-05-03T17:19:32Z init message: Verifying wallet(s)... 2018-05-03T17:19:32Z Using BerkeleyDB version Berkeley DB 4.8.30: (April 9, 2010) 2018-05-03T17:19:32Z Using wallet wallet.dat 2018-05-03T17:19:32Z BerkeleyEnvironment::Open: LogDir=/home/tim/.bitcoin/database ErrorFile=/home/tim/.bitcoin/db.log 2018-05-03T17:19:32Z scheduler thread start 2018-05-03T17:19:32Z BerkeleyEnvironment::Open: Error -30974 opening database environment: DB_RUNRECOVERY: Fatal error, run database recovery 2018-05-03T17:19:32Z Moved old /home/tim/.bitcoin/database to /home/tim/.bitcoin/database.1525367972.bak. Retrying. 2018-05-03T17:19:32Z BerkeleyEnvironment::Open: LogDir=/home/tim/.bitcoin/database ErrorFile=/home/tim/.bitcoin/db.log 2018-05-03T17:19:32Z Cache configuration: 2018-05-03T17:19:32Z * Using 2.0MiB for block index database 2018-05-03T17:19:32Z * Using 8.0MiB for chain state database 2018-05-03T17:19:32Z * Using 440.0MiB for in-memory UTXO set (plus up to 286.1MiB of unused mempool space) 2018-05-03T17:19:32Z init message: Loading block index.. [...] ``` Tree-SHA512: b809b318e5014ec47d023dc3dc40826b9706bfb211fa08bc2d29f36971b96caa10ad48d9a3f96c03933be46fa4ff7e00e952ac77bfffb6563767fb08aa4f23d6
2018-05-14Add compile time checking for all cs_wallet runtime locking assertionspracticalswift
2018-05-14Merge #13116: Add Clang thread safety annotations for variables guarded by ↵MarcoFalke
cs_{rpcWarmup,nTimeOffset,warnings} 8499f15e67 Add Clang thread safety annotations for variables guarded by cs_warnings (practicalswift) cf13ad23d4 Add Clang thread safety annotations for variables guarded by cs_nTimeOffset (practicalswift) 012dec0347 Add Clang thread safety annotations for variables guarded by cs_rpcWarmup (practicalswift) Pull request description: Add Clang thread safety annotations for variables guarded by `cs_{rpcWarmup,nTimeOffset,warnings}`. Tree-SHA512: 8e0a4b9e36a4450bd75ad32c21d813bb572aaaa5b4a4cbdcbf4678e58ade6265c0b275352391168930a63fcbd09caa3b76e74595a7b14646054c52870c46d007
2018-05-14Merge #13205: [tests] Remove spurious error log in p2p_segwit.pyWladimir J. van der Laan
7384a35 [tests] Remove spurious error log in p2p_segwit.py (John Newbery) Pull request description: Since 265d7c44b1aae06aee93f745a865807732218a73, when wait_until() fails, an error message is logged to the test framework log. This means that if wait_until() is called inside a try-except with the expectation that it will fail, a spurious error message is logged. wait_until() shouldn't be called with the expectation of failure. Fix that in p2p_segwit.py. Tree-SHA512: 0a43790b58fee7d2d6bef36e736b0b9ffdde6de5f12d33d15e8e07323597e2be4cd98f17e7fc3a135e06bdafe36613466c0a57e81134e59a251383c62b91918f
2018-05-14Merge #12560: [wallet] Upgrade path for non-HD wallets to HDWladimir J. van der Laan
a8da482 Bump wallet version for pre split keypool (Andrew Chow) dfcd9f3 Use a keypool of presplit keys after upgrading to hd chain split (Andrew Chow) 5c50e93 Allow -upgradewallet to upgradewallets to HD (Andrew Chow) 2bcf2b5 Test sethdseed (Andrew Chow) b5ba01a Add 'sethdseed' RPC to initialize or replace HD seed (Chris Moore) dd3c07a Separate HaveKey function that checks whether a key is in a keystore (Andrew Chow) Pull request description: Revival/rebase of #11085 Adds a new command `sethdseed` which allows you to either set or generate a new HD seed to be used. A new keypool can be generated or the original one kept and new keys added to the keypool will come from the new HD seed. Wallets that are not HD will be upgraded to be version FEATURE_HD_SPLIT when the `sethdseed` RPC command is used. I have also add some tests for this. Additionally `-upgradewallet` can now be used to upgrade a wallet from non-HD to HD. When it is used for such an upgrade, the keypool will be regenerated. Tree-SHA512: e56c792e150590429ac4a1061e8d6f7b20cca06366e184eb9bbade4cd6ae82699a28fe84f87031eadba97ad2c1606517a105f00fb7b45779c979243020071adb
2018-05-13Merge #13214: Enable Travis checking for two Python linting rules we are ↵MarcoFalke
currently not violating 506c5785fb Enable Travis checking for two Python linting rules we are currently not violating (practicalswift) Pull request description: Enable Travis checking for two Python linting rules we are currently not violating: * E101: indentation contains mixed spaces and tabs * E129: visually indented line with same indent as next logical line Tree-SHA512: 955ea5ce4576a5bdd561f9d2bbcfaa82f66a23391c84ddb806830ed15e321e4742457ccc801f457819f626d4a66a1ffcaecee28c3b9f3f907ab8401323743485
2018-05-13Merge #13221: travis: Rename the build stage "check_doc" to "lint"MarcoFalke
3d8ae74657 travis: Rename the build stage "check_doc" to "lint" (practicalswift) Pull request description: Rename the Travis build stage from `check_doc` to `lint`. When `check_doc` was introduced back in fa1b80db889307f5259961ae22128b88b9437b03 it was used to make sure `contrib/devtools/check-doc.py` was run only once. Nowadays `check_docs` is used to trigger various linting type jobs which makes the name `check_doc` a bit misleading. Tree-SHA512: 39d7f3dd2ee6374e60c64fe4366df5f8752e350c4404d2d5b3dd9da64d6ac730a6b523286df4042a14360a5740e068a072ef32e04283ada719c988c7f9a1bf86
2018-05-12travis: Rename the build stage "check_doc" to "lint"practicalswift
2018-05-12Merge #13199: Bugfix: ensure consistency of m_failed_blocks after ↵Pieter Wuille
reconsiderblock 11fa6bb66e Bugfix: ensure consistency of m_failed_blocks after reconsiderblock (Suhas Daftuar) Pull request description: This was introduced in 015a5258adffb0cf394f387a95ac9c8afc34cfc3 and could cause a node to crash (due to assertion failure) when using the `reconsiderblock` rpc. Tree-SHA512: 820dcd761bf983e36f5d0f16777ed75c833daaf62a6b3a4dbd17f6caaf9287223e3a202d06540ac62f8ba72926b73b0873bb76c6273ddcb19d9408f4c1cd325e
2018-05-12Bump wallet version for pre split keypoolAndrew Chow
Bump the wallet version to indicate support for the pre split keypool. Also prevents any wallets from upgrading to versions between HD_SPLIT and PRE_SPLIT_KEYPOOL.
2018-05-12Use a keypool of presplit keys after upgrading to hd chain splitAndrew Chow
After upgrading to HD chain split, we want to continue to use keys from the old keypool. To do this, before we generate any new keys after upgrading, we mark all of the keypool entries as being pre-chain split and move them to a separate pre chain split keypool. Keys are fetched from that keypool until it is emptied. Only then are the new internal and external keypools used.
2018-05-12Allow -upgradewallet to upgradewallets to HDAndrew Chow
Changes the maximum upgradewallet version to the latest wallet version number, 159900. Non-HD wallets will be upgraded to use HD derivation. Non HD chain split wallets will be upgraded to HD chain split. If a non-HD wallet is upgraded to HD, the keypool will be entirely regenerated. Since upgradewallet is effectively run during a first run, all of the first run initial setup stuff is combined with the upgrade to HD
2018-05-12Test sethdseedAndrew Chow
2018-05-12Add 'sethdseed' RPC to initialize or replace HD seedChris Moore
2018-05-12Fix concurrency-related bugs in ActivateBestChainJesse Cohen
If multiple threads are invoking ActivateBestChain, it was possible to have them working towards different tips, and we could arrive at a less work tip than we should. Fix this by introducing a ChainState lock which must be held for the entire duration of ActivateBestChain to enforce exclusion in ABC.
2018-05-12Do not unlock cs_main in ABC unless we've actually made progress.Matt Corallo
Technically, some internal datastructures may be in an inconsistent state if we do this, though there are no known bugs there. Still, for future safety, its much better to only unlock cs_main if we've made progress (not just tried a reorg which may make progress).
2018-05-12Merge #11423: [Policy] Several transaction standardness rulesWladimir J. van der Laan
364bae5 qa: Pad scriptPubKeys to get minimum sized txs (MarcoFalke) 7485488 Policy to reject extremely small transactions (Johnson Lau) 0f8719b Add transaction tests for constant scriptCode (Johnson Lau) 9dabfe4 Add constant scriptCode policy in non-segwit scripts (Johnson Lau) Pull request description: This disables `OP_CODESEPARATOR` in non-segwit scripts (even in an unexecuted branch), and makes a positive `FindAndDelete` result invalid. This ensures that the `scriptCode` serialized in `SignatureHash` is always the same as the script passing to the `EvalScript`. Tree-SHA512: a0552cb920294d130251c48053fa2ff1fbdd26332e62b52147d918837852750f0ce35ce2cd1cbdb86588943312f8154ccb4925e850dbb7c2254bc353070cd5f8
2018-05-11Enable Travis checking for two Python linting rules we are currently not ↵practicalswift
violating
2018-05-10Merge #13210: Enable W191 indentation contains tabs and W291 trailing ↵MarcoFalke
whitespace flake8 checks for Python files 0d31ef4762 Enable W191 and W291 flake8 checks. Remove trailing whitespace from Python files. Convert tabs to spaces. (John Bampton) Pull request description: Tree-SHA512: d062434310d6232469d7ca8e5f2ddb7db7e85cb2a299e609d98bacc318368e43e0777c9f4966df03d50f526bbe27207faa87a7464e62e14671194459a06ad969
2018-05-10Merge #13075: [tests] Remove 'account' API from wallet functional testsMarcoFalke
5d536619ab [tests] Remove 'account' API from wallet functional tests (John Newbery) Pull request description: Next step in #12952. Removes all usage of the 'account' API from the wallet functional tests, except: - rpc_deprecated.py (which specifically tests the `-deprecatedrpc=accounts` command line argument is working properly). - `wallet_labels.py` (which tests that both the 'label' and 'account' APIs work in V0.17). 'account' API usage for both of those tests can be removed once V0.17 has been branched. Also excluded is: - `wallet_importprunedfunds.py` (which fails due to a bitcoind OOM error) Tree-SHA512: 6701b32f83d2d47597ba093ded665d7aa630f7a9c759ff15e3e33a3e3bc7600e8d29cf4e72aed5f8f9f6769cc9b614c681951720eab1ed2473f5f8dec57e7a6f
2018-05-11Enable W191 and W291 flake8 checks.John Bampton
Remove trailing whitespace from Python files. Convert tabs to spaces.
2018-05-10Merge #13192: [tests] Fixed intermittent failure in p2p_sendheaders.py.MarcoFalke
12d1b77f7e [tests] Fixed intermittent failure in p2p_sendheaders.py. (lmanners) Pull request description: Added handling for the case where headers are announced over more than one message. refs #12453 Tree-SHA512: 2c5b48ff019089b86e358181ba170d3aac09d4ae41ec79c2718e0ee83705860501bbcb8fd94d0f5c4f86c0d54a96781a967716621bb8c5ecc991b39af3cec506
2018-05-10Merge #13201: [qa] Handle disconnect_node raceMarcoFalke
09c6699900 [qa] Handle disconnect_node race (Suhas Daftuar) Pull request description: Several tests call disconnect_nodes() on each node-pair in rapid succession, resulting in a race condition if a node disconnects a peer in-between the calculation of the nodeid's to disconnect and the invocation of the disconnectnode rpc call. Handle this. Tree-SHA512: 3078cea0006fcb507c812004a777c505eb1e9dda7c6df12dbbe72395a73ff6f6760f597b6492054f5487b34534417ddef5fbad30553c135c288c4b7cfce79223
2018-05-10test: Ensure that recursive -includeconf produces appropriate warningsKarl-Johan Alm