Commit graph

18074 commits

Author SHA1 Message Date
MarcoFalke 3e3a50aeb8
Merge #13911: doc: Revert translated string change, clarify wallet log messages
c4a884d555 Trivial: Revert translated string change, clarify wallet log messages (Pierre Rochard)

Pull request description:

  Fixes https://github.com/bitcoin/bitcoin/pull/12992 post-merge nits from @jnewbery

Tree-SHA512: 002d8a69b489fd216e15b7d6200d7117c489b32405d5e9f514f120d43113fd97ca2f235452b0093e0760bc03baf714edc4564ae14af8456e1b2a54f83c577bf3
2018-08-09 08:11:17 -04:00
MarcoFalke 8ac7125d59
Merge #13916: qa: wait_for_verack by default
fa5587fe71 qa: wait_for_verack by default (MarcoFalke)

Pull request description:

  This removes the need to do so manually every time a connection is added.

Tree-SHA512: a46c92cb4df41e30778b42b9fd3dcbd8d2d82aa7503d1213cb1c1165034f648d8caee01c292e2d87d05b0f71696996eef5be8a753f35ab49e5f66b0e3bf29f21
2018-08-09 08:07:28 -04:00
MarcoFalke 8eb9870052
Merge #13876: wallet: Catch filesystem_error and raise InitError
fa8527ffec wallet: Catch filesystem_error and raise InitError (MarcoFalke)

Pull request description:

  Fixes #13754 by restoring the previous behaviour

Tree-SHA512: f64052e89f6b332be395df2a5ea6f227c213fa2f38e415e83f30a4fad0938e947e5cddff7902368a43c07be135955a31b90f7eac5a46875c58d54ea95f87f6e6
2018-08-09 08:03:23 -04:00
Conor Scott 44bbceeef1 [Tests] Cleanup feature_block.py, remove unnecessary PreviousSpendableOutput object 2018-08-09 12:58:36 +02:00
Conor Scott 736f941424 [Tests] Cleanup extra instances of create_transaction 2018-08-09 12:58:36 +02:00
Conor Scott 157651855f [Tests] Rename create_tx and move to blocktools.py 2018-08-09 12:58:35 +02:00
MarcoFalke fa5587fe71
qa: wait_for_verack by default 2018-08-08 17:22:35 -04:00
MarcoFalke fa31ca0c22
qa: Remove redundant checkmempool/checkblockindex extra_args 2018-08-08 14:29:19 -04:00
Pierre Rochard c4a884d555 Trivial: Revert translated string change, clarify wallet log messages 2018-08-08 11:00:55 -04:00
Wladimir J. van der Laan df9f712746
Merge #13894: shutdown: Stop threads before resetting ptrs
faab63111d shutdown: Stop threads before resetting ptrs (MarcoFalke)

Pull request description:

  On shutdown some threads would continue to run after or during a pointer reset. This leads to occasional segfaults on shutdown.

  Fix this by resetting the smart pointers after all threads that might read from them have been stopped.

  This should fix:
  * A segfault in the txindex thread, that occurs when the txindex destructor is done, but the thread was not yet stopped (as this is done in the base index destructor)
  * A segfault in the scheduler thread, which dereferences conman. (e.g. CheckForStaleTipAndEvictPeers)

Tree-SHA512: abbcf67fadd088e10fe8c384fadfb90bb115d5317145ccb5363603583b320efc18131e46384f55a9bc574969013dfcbd08c49e0d42c004ed7212eca193858ab2
2018-08-08 15:19:00 +02:00
Wladimir J. van der Laan 78dae8cacc
Merge #13780: 0.17: Pre-branch maintenance
3fc20632a3 qt: Set BLOCK_CHAIN_SIZE = 220 (DrahtBot)
2b6a2f4a28 Regenerate manpages (DrahtBot)
eb7daf4d60 Update copyright headers to 2018 (DrahtBot)

Pull request description:

  Some trivial maintenance to avoid having to do it again after the 0.17 branch off.

  (The scripts to do this are in `./contrib/`)

Tree-SHA512: 16b2af45e0351b1c691c5311d48025dc6828079e98c2aa2e600dc5910ee8aa01858ca6c356538150dc46fe14c8819ed8ec8e4ec9a0f682b9950dd41bc50518fa
2018-08-08 13:55:27 +02:00
Mason Simon bb5b1c0b2d [Docs] upgrade rescan time warning from minutes to >1 hour 2018-08-07 22:39:34 -07:00
Wladimir J. van der Laan 9d86aad287
Merge #13812: wallet: sum ancestors rather than taking max in output groups
23fbbb100f wallet: sum ancestors rather than taking max in output groups (Karl-Johan Alm)

Pull request description:

  This is pointed out in https://github.com/bitcoin/bitcoin/pull/12257#discussion_r204549758.

  Basically, the ancestors gives an indication as to how many ancestors the resulting transaction will have, which is more precise when summing up the values, rather than taking the maximum, since all the coins in the group will become ancestors if selected.

Tree-SHA512: 0588c4b6059669650614817e041526a2ab89dda8c07fca8e077c7669dca1fed51cd164f7df56340840ab60285d48f3b140dcee64f64bf696b2dd4ab16d556a13
2018-08-07 17:23:04 +02:00
Wladimir J. van der Laan e8f387f997
Merge #13843: [trivial] Add doxygen-compatible comments to CAffectedKeysVisitor
3339d84535 [trivial] add doxygen-compatible comments to CAffectedKeysVisitor (Pierre Rochard)

Pull request description:

Tree-SHA512: 0003fde198a6977d0c8988efc8f76428f9e095009fddf131b07bd9809ef76a778c86bb2b1305e33df16101b6b703cf43eb6193462bb9f3687f98c1d9b109dd96
2018-08-07 16:49:18 +02:00
MarcoFalke 1cd5f2cf9a
Merge #13895: Docs: fix GetWarnings docs to reflect behavior
13bb5cae31 Docs: fix GetWarnings docs to reflect behavior (Ben Woosley)

Pull request description:

  In "gui", it returns all warnings, joined by a separator
  In "statusbar", it returns the last warning set which seems notionally to be the most important, though that is debatable

Tree-SHA512: 5fc0dc68d143a040b7b893b7176188e2b064c2cf1d559420906e4de636e16e9ab7451a1b87603020a7a8f66d6b94f4ee6c7da2697efad879f9e6de9c0e0c9ac1
2018-08-07 10:30:31 -04:00
Wladimir J. van der Laan 7c82e40e76
Merge #13857: docs: fix typo in translation_process.md
081f5b4e2b Docs: Improve "of" grammar (johnlow95)

Pull request description:

Tree-SHA512: 7227371372cd4cc0ec2dbbbf0947c63f63ba41f8c6f9f6909f1dd37a724bf09a60bc57037233cc282922bcbcf2aff3bfd35bef823bdf11ffe26ba990fa3f7e32
2018-08-07 16:22:05 +02:00
Wladimir J. van der Laan e7ea858729
Merge #13527: policy: Remove promiscuousmempoolflags
faa24441ec policy: Remove promiscuousmempoolflags (MarcoFalke)

Pull request description:

  It seems odd to clutter validation code with features that can only ever be used for testing (testnet or regtest). Removing that test-only code makes the mempool logic less painful to understand and easier to reason about when changed or refactored in the future.

Tree-SHA512: 3b897aa9604ac8d82ebe9573c6efd468c93ddaa08d378ebc902e247b7aa6c68fcde71e5b449c08f17a067146cdc66dc50a67ce06d07607c27e5189a49c3fba3f
2018-08-07 15:45:37 +02:00
Wladimir J. van der Laan b413ba0273
Merge #13705: build: Add format string linter
bcd4b0f5cd Add linting of WalletLogPrintf(...) format strings (practicalswift)
a3e4556949 build: Add format string linter (practicalswift)

Pull request description:

  Add format string linter.

  This linter checks that the number of arguments passed to each variadic format string function matches the number of format specifiers in the format string.

  Example output:

  ```
  $ test/lint/lint-format-strings.sh
  src/init.cpp: Expected 2 argument(s) after format string but found 1 argument(s):
    LogPrintf("We have a mismatch here: foo=%s bar=%d\n", foo)
  src/init.cpp: Expected 1 argument(s) after format string but found 2 argument(s):
    LogPrint(BCLog::RPC, "RPC stopped. This is a mismatch: %s\n", s1, s2)
  $ echo $?
  1
  ```

Tree-SHA512: 19ab844a63f04bf193d66682ca42745a1c7d6c454b30222491b9fe8dc047054c4a6d3ee7921ec0676fb9ca2e7f6f93bd6c97996fb09667269bd491cb875349f3
2018-08-07 15:32:36 +02:00
practicalswift bcd4b0f5cd Add linting of WalletLogPrintf(...) format strings 2018-08-07 14:57:54 +02:00
Wladimir J. van der Laan 51c693d49e
Merge #13657: wallet: assert to ensure accuracy of CMerkleTx::GetBlocksToMaturity
93de2891fa wallet: assert to ensure accuracy of CMerkleTx::GetBlocksToMaturity (Ben Woosley)

Pull request description:

  According to my understanding, it should not be possible for coinbase
  transactions to be conflicting, thus it should not be possible for
  GetDepthInMainChain to return a negative result. If it did, this would
  also result in innacurate results for GetBlocksToMaturity due to the
  math therein. asserting ensures accuracy.

Tree-SHA512: 8e71c26f09fe457cfb00c362ca27066f7f018ea2af1f395090fdc7fd9f5964b76f4317c23f7a4923776f00087558511da5c1c368095be39fb1bacc614a93c32f
2018-08-07 14:19:50 +02:00
practicalswift a3e4556949 build: Add format string linter
This linter checks that the number of arguments passed to each variadic format
string function matches the number of format specifiers in the format string.
2018-08-07 14:07:21 +02:00
Wladimir J. van der Laan 8c3c402a5a
Merge #13717: docs: Link to python style guidelines from developer notes
a9e898a4ad docs: Link to python style guidelines from developer notes (Mason Simon)

Pull request description:

  Initially I moved the python style guidelines from the functional test README, but some of the python rules are test-specific, and most of the developer notes doc is C++ centric, so just dropping a link seemed better.

Tree-SHA512: 9d4d5cc45526319a118595d90fcfad2c9aced22007aa096d8af04ba1b963312822804f4c15b0b227d66af49565034437691b7760e7ff6d1e3f8b10b898906362
2018-08-07 13:56:31 +02:00
Wladimir J. van der Laan b81a8a5ea9
Merge #13667: wallet: Fix backupwallet for multiwallets
a1a998cf24 wallet: Fix backupwallet for multiwallets (Daniel Kraft)

Pull request description:

  `backupwallet` was broken for multiwallets in their own directories (i.e. something like `DATADIR/wallets/mywallet/wallet.dat`).  In this case, the backup would use `DATADIR/wallets/wallet.dat` as source file and not take the specific wallet's directory into account.

  This led to either an error during the backup (if the wrong source file was not present) or would silently back up the wrong wallet; especially the latter behaviour can be quite bad for users.

Tree-SHA512: 7efe2450ca047e40719fcc7cc211ed94699056020ac737cada7b59e8240298675960570c45079add424d0aab520437d5050d956acd695a9c2452dd4317b4d2c4
2018-08-07 13:31:54 +02:00
Wladimir J. van der Laan 37ab117a87
Merge #13872: [docs] Reformat -help output for help2man
7272fdcfe7 [docs] Reformat -help output for help2man (Tim Ruffing)

Pull request description:

  This commit slightly changes the format of the "Usage" strings in CLI
  `-help` messages to meet the expection of the help2man tool, which we
  use to generate man pages. On the way, we remove a few calls to
  `strprintf()`, which became superficial after commit 32fbfda.

  Before:
  ![screenshot from 2018-08-04 12-11-25](https://user-images.githubusercontent.com/1071625/43675564-6e2e016c-97e2-11e8-8de7-0912a4088efd.png)
  After:
  ![screenshot from 2018-08-04 12-11-46](https://user-images.githubusercontent.com/1071625/43675566-712d7032-97e2-11e8-85a7-5decc6dcb4b2.png)

Tree-SHA512: 9752ee0d0fde0b084e00232609866291ff493f4feb45919279b0f142b04635c049ddd2bf71ff6ad57d4ae1ed37103348640d253bb4f0b3e16b7fd2bb4b2a6fba
2018-08-07 10:32:53 +02:00
Ben Woosley 13bb5cae31
Docs: fix GetWarnings docs to reflect behavior
In "gui", it returns all warnings, joined by a separator
In "statusbar", it returns just the first warning
2018-08-06 17:16:15 -04:00
MarcoFalke faab63111d
shutdown: Stop threads before resetting ptrs 2018-08-06 16:35:41 -04:00
Wladimir J. van der Laan 26f59f5054
Merge #12992: [wallet] Add wallet name to log messages
909f54c80a [wallet] Add wallet name to log messages (Pierre Rochard)

Pull request description:

  After multiple wallets became supported, wallet-related log messages became ambiguous as to which wallet they were being emitted by.

  This pull request adds a `CWallet::WalletLogPrintf` function to be used when logging wallet-specific events. This function prepends the wallet's name to the log message and forwards it to `LogPrintf`

  fixes #11317

Tree-SHA512: d258dcc9aa0f1330159bc66b4020f84709c5bba5165bdc62503543557d8999777f0b94a7a82a08823e2b2ceb84f4f8d1cd5493f99c076a13539f1f6155dc55ad
2018-08-06 17:36:23 +02:00
Wladimir J. van der Laan 317477a246
Merge #13853: doc: correct versions in dependencies.md
322d34ef65 doc: correct versions in dependencies.md (fanquake)

Pull request description:

Tree-SHA512: 02487b35bc3dd79b9e91aff48433f763746b7ea76ad5f2b9c79f1f11f6c9441c69b4406880329113aa4bd660887ee810b3beb6c9d54c3e5514004f55d6ca4916
2018-08-06 16:39:39 +02:00
Wladimir J. van der Laan 238432302a
Merge #13859: qa: Add emojis to test_runner path and wallet filename
5e17777777 qa: Create unicode tempdir in test_runner (MarcoFalke)

Pull request description:

  Now that wallet filenames are properly quoted when used for rpc (#13823), we can add some unicode symbols to the test_runner path. Thus, the "extern" wallet that uses a full path has a unicode symbol in its name.

  Should add unicode coverage to
  * `listwallets`
  * `wallet.getwalletinfo`
  * `(un)loadwallet`

Tree-SHA512: 1633fde56f8748df0cfef9c31a878c105dfaac85d1041b292261f44c4d40e96942aacbf7d6e839e8bbf979dc131d81c24ceb521e927fc8a5a71ba093f36b891b
2018-08-06 16:33:22 +02:00
MarcoFalke 2ab72080ad
Merge #13696: Add aarch64 qt depends support for cross compiling bitcoin-qt
00db418176 Add aarch64 qt depends support for cross compiling bitcoin-qt (TheCharlatan)

Pull request description:

  This also adds a generic qt linux target in packages.mk . I am a bit confused by the existing docs for the RISC addition. Are there boards that would support running bitcoin-qt, or at the very least forwarding X over ssh? Is everybody building depends with `NO_QT=1` when targeting RISC? If not, I will revert the change for a generic qt linux package definition back to the piecemeal solution.

  This pull request should close #13495

Tree-SHA512: 519b951bf50f214ad725e5330094582a212333cd85b0ae442c67f9afec5629995dfad130258c7706a61f7b7cccbfa49bce69b9931f7e30cf12b382cd9a0a4749
2018-08-05 13:22:12 -04:00
MarcoFalke fa8527ffec
wallet: Catch filesystem_error and raise InitError 2018-08-04 12:04:38 -04:00
Tim Ruffing 7272fdcfe7 [docs] Reformat -help output for help2man
This commit slightly changes the format of the "Usage" strings in CLI
`-help` messages to meet the expection of the help2man tool, which we
use to generate man pages. On the way, we remove a few calls to
`strprintf()`, which became superficial after commit 32fbfda.
2018-08-04 16:17:13 +02:00
MarcoFalke fafe73a626
qa: Raise feature_help timeout to 5s 2018-08-03 17:41:21 -04:00
MarcoFalke faabd7bc47
qa: Use files for stdout/stderr to support Windows 2018-08-03 17:29:46 -04:00
MarcoFalke facb56ffaf
qa: Run gen_rpcauth with sys.executable 2018-08-03 16:25:54 -04:00
Pierre Rochard 3339d84535 [trivial] add doxygen-compatible comments to CAffectedKeysVisitor 2018-08-03 15:30:08 -04:00
MarcoFalke fada8966c5
qa: Close stdout and stderr file when node stops 2018-08-03 13:43:59 -04:00
MarcoFalke 5e17777777
qa: Create unicode tempdir in test_runner 2018-08-03 11:29:02 -04:00
MarcoFalke 2b67354aa5
Merge #13849: travis: use only travis jobs: instead of mix of jobs+matrix
566f826902 use only travis jobs: instead of mix of jobs+matrix (Julian Fleischer)

Pull request description:

  This is extracted from https://github.com/bitcoin/bitcoin/pull/13816 to make that one simpler.

  The travis `matrix` and `jobs` top level items are actually aliases for each other. The goal is to be able to specify not just the environment per job but also the `os` (for https://github.com/bitcoin/bitcoin/pull/13816 ). So this PR moves the environment variables from the `env.matrix` section to `jobs.include`.

  `jobs` and build stages subsume the matrix functionality. IMHO this makes it clearer to add stages (as every item clearly references which stage it belongs to).

  The `before_install`, `install`, etc. steps default to belonging to the `test` stage and were moved up .

Tree-SHA512: afd01e03d076c3ac6c2ab20facbe0fbbbc028c92880d02e866b077e9ca365a4e9e8c237a0d999234180c684bc4612c0bf6c3026b96d93b5f91c7e60e4de7775e
2018-08-03 08:11:37 -04:00
fanquake 322d34ef65
doc: correct versions in dependencies.md 2018-08-03 09:06:36 +08:00
johnlow95 081f5b4e2b
Docs: Improve "of" grammar 2018-08-03 02:49:48 +08:00
Pierre Rochard 909f54c80a [wallet] Add wallet name to log messages
After multiple wallets became supported, wallet-related log messages
became ambiguous as to which wallet they were being emitted by.

fixes #11317
2018-08-02 12:09:39 -04:00
MarcoFalke 1ef57a96b8
Merge #13255: trivial: Fixed typos and cleaned up language
d5f745a5c7 trivial: correct typos (Varunram)
3be70ba400 trivial: Fixed typos and cleaned up language (William Robinson)

Pull request description:

  This rebases and fixes some of the outstanding nits in #13010. Let either merge quickly or close for now.

Tree-SHA512: 4cc1a5f854f2d6a19332334e2608a19e2be6b97dc09114c8186237ea77ee4b62372ebf6841a61cca548cedb47f0e6f11d4c0aba51a71949cd5aff8cef88204d6
2018-08-02 10:22:51 -04:00
Wladimir J. van der Laan 489b51b08e
Merge #13823: qa: quote path in authproxy for external multiwallets
fa67505e1e qa: Quote wallet name for rpc path (MarcoFalke)

Pull request description:

  When using external multiwallets they are specified by their full path which might contain non-ascii characters (e.g. umlauts or emojis).

  Fix this by url-quoting the path.

Tree-SHA512: 7cc66514579d9f602f88a6817c5ab43a44c6d3711df452dc904173f0bc34e2c0b2c34877497f06b61f6720c532fa183053f54622dc454e316c89cee7eaa72463
2018-08-02 16:00:04 +02:00
Julian Fleischer 566f826902 use only travis jobs: instead of mix of jobs+matrix 2018-08-02 15:36:00 +02:00
Varunram d5f745a5c7
trivial: correct typos 2018-08-02 21:27:17 +08:00
William Robinson 3be70ba400
trivial: Fixed typos and cleaned up language 2018-08-02 21:27:16 +08:00
MarcoFalke 9c4324d866
Merge #13851: fix locale for lint-shell
83c48d9a1f fix locale for lint-shell (Julian Fleischer)

Pull request description:

  A piece of code from https://github.com/bitcoin/bitcoin/pull/13816 which I am hereby splitting into smaller PRs.

  The `shellcheck` executable shipped with travis's trusty linux environment (contains shellcheck `0.3.1` in `/usr/local/bin` as opposed to the distros `0.3.3` in `/usr/bin`) segfaults when `LC_ALL=C`.

  This makes sure that in travis, no matter from where the script is called, `LC_ALL` is left unset. Comment changed accordingly.

Tree-SHA512: 86afa9247f2adbeefa75bf3d56a94766f8e8e1839f40b73763ff7b893a09c848ee64648fc06ce3e6bd0f650127365f508b37fdefb48d61e49f5d551c074cb16e
2018-08-02 09:08:40 -04:00
Julian Fleischer 83c48d9a1f fix locale for lint-shell 2018-08-02 14:46:05 +02:00
Wladimir J. van der Laan 990e182587
Merge #13837: qa: Extract rpc_timewait as test param
fa5b440971 qa: Extract rpc_timewait as test param (MarcoFalke)

Pull request description:

  Also increase it for wallet_dump and wallet_groups

Tree-SHA512: 7367bc584228bda3010c453713a1505c54a8ef3d116be47dab9934d30594089dfeb27ffa862f7517fd0ec8b5dc07f4904d67ef2a53dd284cbe2a58982e410e2b
2018-08-02 14:36:54 +02:00