Commit Graph

16704 Commits

Author SHA1 Message Date
UdjinM6
fbb49f92d0 Bail out properly on Evo DB consistency check failures in ConnectBlock/DisconnectBlock (#3044) 2019-08-07 11:55:06 +02:00
Alexander Block
4286dde498 Remove support for InstantSend locked gobject collaterals (#3019) 2019-08-07 11:52:09 +02:00
UdjinM6
f66ff6be02
Drop state from DisconnectBlock params (finilize 10297 backport) 2019-08-06 06:50:03 -05:00
Pasta
42cf74dec4
add #if ENABLE_MINER to relevant sections
Signed-off-by: Pasta <pasta@dashboost.org>
2019-08-06 06:50:03 -05:00
PastaPastaPasta
53f046ce2c
Fix makefile
Co-Authored-By: UdjinM6 <UdjinM6@users.noreply.github.com>
2019-08-06 06:46:42 -05:00
PastaPastaPasta
106fdfa0b0
Fix tests
Co-Authored-By: UdjinM6 <UdjinM6@users.noreply.github.com>
2019-08-06 06:46:42 -05:00
Wladimir J. van der Laan
6edcf43fcd
Merge #10683: rpc: Move the generate RPC call to rpcwallet
2a96283 rpc: Update `generate` for developer notes (Wladimir J. van der Laan)
df7e2f0 rpc: Move the `generate` RPC call to rpcwallet (Wladimir J. van der Laan)

Tree-SHA512: ec658d6178f8435dc54b9d9c6dd59f873055a8ae0c3f177c02049d77b93107dd5fc17a1ff56d50f051810d52fdf306846eaba2ef4fc8d2a6cfa831f57a1045c4
2019-08-05 16:49:30 -05:00
Wladimir J. van der Laan
f1f9e5dfb5
Merge #11002: [wallet] return correct error code from resendwallettransaction
055d95f [wallet] return correct error code from resendwallettransaction (John Newbery)

Pull request description:

  New code in #10995 uses `RPC_INVALID_REQUEST`. According to the comment in rpc/protocol.h:
  ```
  // RPC_INVALID_REQUEST is internally mapped to HTTP_BAD_REQUEST (400).
  // It should not be used for application-layer errors.
  ```
  Change the returned error code to `RPC_WALLET_ERROR`

  #11000 will need to be updated to test for the correct error code.

Tree-SHA512: 0201b3a2091adf17ad301825da5bd29f0ea7e284b5394cbef80483fc293a558acc849f74a0780bb8501acab324fc722e41ae049cffec7afb76884e26df4b809e
2019-08-05 16:47:12 -05:00
Wladimir J. van der Laan
a7ef222617
Merge #10995: Fix resendwallettransactions assert failure if -walletbroadcast=0
01699fb Fix resendwallettransactions assert failure if -walletbroadcast=0 (Matt Corallo)

Pull request description:

  This fixes #10981 in my preferred way.

Tree-SHA512: 2e43d3ac78d13c5d59db23a82c76c722cc3344767a8237617080e489296d27a98bb1b3bd469b2c9b289b57a9da3709c90448d7a23bcc2e1dfb791c4fd16be015
2019-08-05 16:46:46 -05:00
Pasta
60b3ae1821
add gArgs
Signed-off-by: Pasta <pasta@dashboost.org>
2019-08-02 12:41:37 -05:00
Pasta
f3259d0d28
remove DB_PEAK_USAGE_FACTOR
Signed-off-by: Pasta <pasta@dashboost.org>
2019-08-02 12:40:53 -05:00
Wladimir J. van der Laan
453d756571
Merge #10148: Use non-atomic flushing with block replay
176c021 [qa] Test non-atomic chainstate writes (Suhas Daftuar)
d6af06d Dont create pcoinsTip until after ReplayBlocks. (Matt Corallo)
eaca1b7 Random db flush crash simulator (Pieter Wuille)
0580ee0 Adapt memory usage estimation for flushing (Pieter Wuille)
013a56a Non-atomic flushing using the blockchain as replay journal (Pieter Wuille)
b3a279c [MOVEONLY] Move LastCommonAncestor to chain (Pieter Wuille)

Tree-SHA512: 47ccc62303f9075c44d2a914be75bd6969ff881a857a2ff1227f05ec7def6f4c71c46680c5a28cb150c814999526797dc05cf2701fde1369c06169f46eccddee
2019-08-01 14:57:28 -05:00
Gregory Sanders
8ed0d522fb
disable jni in builds
Github-Pull: #11056
Rebased-From: 844b73e486
Tree-SHA512: f735853c3d9abbde5032cc55201b0ddc29679e681ba7d3822cbcbeee17c7185ee984b235411224cfb8ff12550de88a0f1367d55ad24bf52c5c03061330849eb2
2019-08-01 14:48:40 -05:00
MarcoFalke
33807c8cee
Merge #11000: test: Add resendwallettransactions functional tests
bdf607e43 test: Add resendwallettransactions functional tests (João Barbosa)

Pull request description:

  Adds functional tests to cover the behaviour introduced in #10995.

Tree-SHA512: 3be337cbe51edab2cc0eb9ecfa68d00cd3c3a00aef0672cd841706802726c9cd4138626a8f209c3d9fbd207ce332daa062f270e4c94c1c2398bfc475e36423f6
2019-08-01 14:42:39 -05:00
MarcoFalke
7f1009ed57
Merge #11023: [tests] Add option to attach a python debugger if functional test fails
cc5d38f4b Add option to attach a python debugger if test fails (John Newbery)

Pull request description:

  Adds a simple option to the test_framework to attach pdb if the test fails.

  Helpful for catching and debugging intermittent failures: Run the test in a loop with this option. The first failure will cause execution to pause and nodes will be left running for interactive debugging.

  @sdaftuar

Tree-SHA512: 01cfae15fa3f04ed6ec6a99fef60a6c6a59723429309e81eacd6767caf12f5758f59b337804291ecab33a38a2958f36e2b513d201bee72a2eeb207a67046f952
2019-08-01 14:42:19 -05:00
Wladimir J. van der Laan
52aef4cfec
Merge #10301: Check if sys/random.h is required for getentropy.
ee2d10a Check if sys/random.h is required for getentropy on OSX. (James Hilliard)

Pull request description:

  This should check and include sys/random.h if required for osx as mentioned [here](https://github.com/bitcoin/bitcoin/pull/9821#issuecomment-290936636).

Tree-SHA512: e9491f67f2e8b2e6bcdbcbb8063295e844d5627daf5336e3e17b4a8027d888fa65a08e4580a745abdc35ffd8d86b4fc7434daaac172c4a06ab7566a2ed0bfb92
2019-08-01 14:41:39 -05:00
Wladimir J. van der Laan
8cb2508c93
Merge #10974: Fix typo in sendcoinsdialog.
7f121a0 Fix typo in sendcoinsdialog. (Masahiko Hyuga)

Pull request description:

Tree-SHA512: 7b3ea344a8a432b6e3835b6870ccfaa197df43f812fea506259b644a44442e36ee39967eed246d9b4b5334528b63f41d7e8af9fd2267e51bcf7557ed652452e4
2019-08-01 14:39:48 -05:00
Wladimir J. van der Laan
80bc6df26f
Merge #10892: Replace traditional for with ranged for in block and transaction primitives
72f0060 Replace traditional for with ranged for in primitives (Dag Robole)

Pull request description:

  Replace traditional for with ranged for in block and transaction primitives to improve readability

Tree-SHA512: c0fff603d2939149ca48b6aa72b59738a3658d49bd58b2d4ffbc85bdb774d8d5bb808fe526fe22bb9eb214de632834d373e2aab44f6019a83c0b09440cea6528
2019-08-01 14:36:08 -05:00
Wladimir J. van der Laan
07d08a8224
Merge #10912: [tests] Fix incorrect memory_cleanse(…) call in crypto_tests.cpp
065039d [tests] Fix incorrect memory_cleanse(…) call in crypto_tests.cpp (practicalswift)

Pull request description:

  `chKey` and `chIV` are pointers, not arrays :-)

  Probably the result of copy-pasting of old code where the code was operating on arrays instead of pointers.

  If I'm reading the code correctly the absence/presence of these `memory_cleanse(…)` calls won't alter the outcome of the test in question (`TestPassphraseSingle`) even if fixed. Therefore removing.

Tree-SHA512: a053b2817bedf6ef889744e546ce9a0f165dee94aef6850d9d6a6bb05b0018789597371ecf154a4aec8588c0ef5626ef08c23c35e35927f6b0497b5f086146fe
2019-08-01 14:32:23 -05:00
Wladimir J. van der Laan
5dc2193d2f
Merge #10824: Avoid unnecessary work in SetNetworkActive
a2420ae Avoid unnecessary work in SetNetworkActive (João Barbosa)

Pull request description:

  This PR adds an early return to avoid unnecessary notifications when the status doesn't change.

Tree-SHA512: 85d05ca6fa36cb581f94bc154d08bd72cd53f6a857173c6fb2f184058f9c0208c4cf5e5d196825a78339902d8f256688eb6793f99abc7be9c7cfac85136180d9
2019-08-01 14:32:12 -05:00
Wladimir J. van der Laan
8fdf594316
Merge #10927: test: Make sure wallet.backup is created in temp path
88af227 test: Make sure wallet.backup is created in temp path (Wladimir J. van der Laan)

Pull request description:

  This assures that we don't overwrite a random file called `wallet.backup` that happens to be in the current directory. It also assures that the temporary file will be cleaned up.

  Noticed by Evan Klitzke, came up in discussion here: https://github.com/bitcoin/bitcoin/pull/10880#discussion_r128460722

Tree-SHA512: 2d2c23c2deba26a1130a29279b3d8565b277eb90a98a6a6d7dd4948f5cbbd5ec5453b3082e3e4e21e0e2423e642bbd2f4433e4c21032d3c8cff27ee35e87e7e7
2019-08-01 14:28:36 -05:00
Wladimir J. van der Laan
b2b0bc9b0a
Merge #10870: [Qt] Use wallet 0 in rpc console if running with multiple wallets
9737572 [Qt] Use wallet 0 in rpc console if running with multiple wallets (Jonas Schnelli)

Pull request description:

  Current master with multiwallet results in accessing wallet 0 in QT (send / receive / tx history / etc.), **but** the RPC console cannot access that wallet (only non-wallet commands work).

  This is a quick solution to re-allow accessing the same wallet (Index 0) via RPC console in multiwallet.

  The solutions design is not "state of the art" (should go over WalletModel). Ideally we work on an overall multiwallet support for the GUI (which then would remove this change).

  I think we should consider this as a bugfix.

Tree-SHA512: 16cf844662248ffd3d82c7d0cbe5879f231fbc7d4f5a4aab4180a9087018519c98301e4ac311eaec2cc39dddf25d3edf9be99a6622ea682c138a820a9b21fd0c
2019-08-01 14:27:47 -05:00
Wladimir J. van der Laan
6096212d55
Merge #10883: Rename -usewallet to -rpcwallet
2264236 Rename -usewallet to -rpcwallet (Alex Morcos)

Pull request description:

Tree-SHA512: 99bdbff5d18e464e620b7b2a1ff8db874b3888db4d43348c96c372097ed51edd796b564e4ef1193ccd75d0a1fd51f865cf6fff4e0e3672654cd2933c851d210a
2019-08-01 11:36:58 -05:00
Pasta
1a96452287
add gArgs
Signed-off-by: Pasta <pasta@dashboost.org>
2019-08-01 11:33:45 -05:00
UdjinM6
8d89350b8a
Use less alarming fee warning note (#3038) 2019-08-01 17:50:42 +03:00
UdjinM6
02f6188e8f
Do not count 0-fee txes for fee estimation (#3037) 2019-08-01 17:50:23 +03:00
UdjinM6
51c84248ad
Merge pull request #3032 from PastaPastaPasta/backport-chacha-poly1305
Backport chacha-poly1305, prepare for V2 P2P Encrypted Messaging
2019-08-01 17:49:40 +03:00
UdjinM6
b4d72d4dc9
Merge pull request #3036 from PastaPastaPasta/backports-0.15-pr22
Backports 0.15 pr22
2019-08-01 17:48:57 +03:00
Wladimir J. van der Laan
fdf34ff655
Merge #10849: Multiwallet: simplest endpoint support
6b9faf7 [QA] add basic multiwallet test (Jonas Schnelli)
979d0b8 [tests] [wallet] Add wallet endpoint support to authproxy (John Newbery)
76603b1 Select wallet based on the given endpoint (Jonas Schnelli)
32c9710 Fix test_bitcoin circular dependency issue (Jonas Schnelli)
31e0720 Add wallet endpoint support to bitcoin-cli (-usewallet) (Jonas Schnelli)
dd2185c Register wallet endpoint (Jonas Schnelli)

Pull request description:

  Alternative for #10829 and #10650.
  It adds the most simplest form of wallet based endpoint support (`/wallet/<filename>`).
  No v1 and no node/wallet endpoint split.

Tree-SHA512: 23de1fd2f9b48d94682928b582fb6909e16ca507c2ee19e1f989d5a4f3aa706194c4b1fe8854d1d79ba531b7092434239776cae1ae715ff536e829424f59f9be
2019-08-01 09:05:19 -05:00
Wladimir J. van der Laan
6fb74ead60
Merge #10832: init: Factor out AppInitLockDataDirectory and fix startup core dump issue
dba485d init: Factor out AppInitLockDataDirectory (Wladimir J. van der Laan)

Pull request description:

  Alternative to #10818, alternative solution to #10815.

  After this change: All the AppInit steps before and inclusive AppInitLockDataDirectory must not have Shutdown() called in case of failure. Only when AppInitMain fails, Shutdown should be called.

  Changes the GUI and bitcoind code to consistently do this.

Tree-SHA512: 393e1a0ae05eb8e791025069e3ac4f6f3cdeb459ec63feda85d01cf6696ab3fed7632b6a0ac3641b8c7015af51d46756b5bba77f5e5f0c446f0c2dea58bbc92e
2019-08-01 09:02:48 -05:00
Pasta
d97fd1ca76
state that getinfo will be deprecated in a future version
Signed-off-by: Pasta <pasta@dashboost.org>
2019-07-25 11:20:48 -05:00
Pasta
d6633b5fba
apply rpcconsole.cpp patch
Signed-off-by: Pasta <pasta@dashboost.org>
2019-07-24 12:56:48 -05:00
Pasta
f0c73f5cec
Revert "Skip mempool.dat when wallet is starting in "zap" mode (#2782)"
This reverts commit 60a91848a4.
2019-07-24 12:55:09 -05:00
Pasta
4a22fb78f9
s/dash-util-test.py/bitcoin-util-test.py
Signed-off-by: Pasta <pasta@dashboost.org>
2019-07-24 12:52:32 -05:00
PastaPastaPasta
e0424c1a0b
s/libbitcoin/libdash
Co-Authored-By: UdjinM6 <UdjinM6@users.noreply.github.com>
2019-07-24 12:15:22 -05:00
Pasta
316fa18593
s/bitcoind/dashd
Signed-off-by: Pasta <pasta@dashboost.org>
2019-07-24 12:13:09 -05:00
Pasta
f38ed3c71b
#10821 continued
Signed-off-by: Pasta <pasta@dashboost.org>
2019-07-24 12:12:30 -05:00
Pasta
64c195a03d
remove witness/segwit based text
Signed-off-by: Pasta <pasta@dashboost.org>
2019-07-24 12:08:08 -05:00
Pasta
c84636a473
update commented time estimates for fees
Signed-off-by: Pasta <pasta@dashboost.org>
2019-07-24 12:07:03 -05:00
Pasta
6ce278f563
s/149900/140100
Signed-off-by: Pasta <pasta@dashboost.org>
2019-07-24 12:05:42 -05:00
Pasta
c34ec30b61
s/bitcoin/dash
Signed-off-by: Pasta <pasta@dashboost.org>
2019-07-24 12:03:39 -05:00
Pasta
83af2d8d50
remove redundant wait_node
Signed-off-by: Pasta <pasta@dashboost.org>
2019-07-24 12:02:28 -05:00
Pasta
ae1beffe00
remove boost list_of
Signed-off-by: Pasta <pasta@dashboost.org>
2019-07-24 11:59:09 -05:00
Pieter Wuille
d76cd903e4
Merge #10419: [trivial] Fix three recently introduced typos
efc2e3302 [trivial] Fix three recently introduced typos (practicalswift)

Tree-SHA512: 99e97f3c1350299dfce9c0c35547d480f25c0b877da311d9120f113afd3089eda31b88b2378e2370f288b0c41bb69cee0fd3abca661cd93d5a56982f90709f91
2019-07-24 11:59:09 -05:00
Pieter Wuille
b430366dd9
Merge #10199: Better fee estimates
38bc1ec Make more json-like output from estimaterawfee (Alex Morcos)
2d2e170 Comments and improved documentation (Alex Morcos)
ef589f8 minor cleanup: remove unnecessary variable (Alex Morcos)
3ee76d6 Introduce a scale factor (Alex Morcos)
5f1f0c6 Historical block span (Alex Morcos)
aa19b8e Clean up fee estimate debug printing (Alex Morcos)
10f7cbd Track first recorded height (Alex Morcos)
3810e97 Rewrite estimateSmartFee (Alex Morcos)
c7447ec Track failures in fee estimation. (Alex Morcos)
4186d3f Expose estimaterawfee (Alex Morcos)
2681153 minor refactor: explicitly track start of new bucket range and don't update curNearBucket on final loop. (Alex Morcos)
1ba43cc Make EstimateMedianVal smarter about small failures. (Alex Morcos)
d3e30bc Refactor to update moving average on fly (Alex Morcos)
e5007ba Change parameters for fee estimation and estimates on all 3 time horizons. (Alex Morcos)
c0a273f Change file format for fee estimates. (Alex Morcos)

Tree-SHA512: 186e7508d86a1f351bb656edcd84ee9091f5f2706331eda9ee29da9c8eb5bf67b8c1f2abf6662835560e7f613b1377099054f20767f41ddcdbc89c4f9e78946d
2019-07-24 11:59:09 -05:00
Wladimir J. van der Laan
c7dcf79f02
Merge #10821: Add SSE4 optimized SHA256
6b8d872 Protect SSE4 code behind a compile-time flag (Pieter Wuille)
fa9be90 Add selftest for SHA256 transform (Pieter Wuille)
c1ccb15 Add SSE4 based SHA256 (Pieter Wuille)
2991c91 Add SHA256 dispatcher (Pieter Wuille)
4d50f38 Support multi-block SHA256 transforms (Pieter Wuille)

Pull request description:

  This adds an SSE4 assembly version of the SHA256 transform by Intel, and uses it at run time if SSE4 instructions are available, and use a fallback C++ implementation otherwise. Nearly every x86_64 CPU supports SSE4. The feature is only enabled when compiled with `--enable-experimental-asm`.

  In order to avoid build dependencies and other complications, the original Intel YASM code was translated to GCC extended asm syntax.

  This gives around a 50% speedup on the SHA256 benchmark for me.

  It is based on an earlier patch by @laanwj, though only includes a single assembly version (for now), and removes the YASM dependency.

Tree-SHA512: d31c50695ceb45264291537b93c0d7497670be38edf021ca5402eaa7d4e1e0e1ae492326e28d4e93979d066168129e62d1825e0384b1b906d36f85d93dfcb43c
2019-07-24 11:59:09 -05:00
MarcoFalke
d587fe3f0e
Merge #10681: add gdb attach process to test README
7ec3343 add gdb attach process to test README (Gregory Sanders)

Pull request description:

  Saved me many hours. h/t to @jnewbery for the new guide efforts

Tree-SHA512: 4d8ba1717eb842201079488f1cfe369d5d5114df5278643a3f996c986a51e3e039ea994a6f2f06bf6607b697388ad6561198da4693e3cb1ca4a8424e6d423d85
2019-07-24 11:59:09 -05:00
Wladimir J. van der Laan
b535dfbc41
Merge #10857: [RPC] Add a deprecation warning to getinfo's output
1c9b818 getinfo deprecation warning (Andrew Chow)

Pull request description:

  This is an alternative to #10841

  This PR implements @gmaxwell's suggestion of a `nag` field for getinfo which warns about the deprecation. Instead of calling it `nag`, I have named it `deprecation-warning`. The output of `getinfo` will look like this:
  ```
  {
    "version": 149900,
    "protocolversion": 70015,
    "walletversion": 139900,
    "balance": 0.00000000,
    "blocks": 476281,
    "timeoffset": 0,
    "connections": 2,
    "proxy": "",
    "difficulty": 804525194568.1318,
    "testnet": false,
    "keypoololdest": 1496858803,
    "keypoolsize": 197,
    "unlocked_until": 0,
    "paytxfee": 0.00000000,
    "relayfee": 0.00001000,
    "errors": "This is a pre-release test build - use at your own risk - do not use for mining or merchant applications",
    "deprecation-warning": "WARNING: getinfo is deprecated and will be fully removed in 0.16. Projects should transition to using getblockchaininfo, getnetworkinfo, and getwalletinfo before upgrading to 0.16"
  }
  ```

  I think this should be tagged for 0.15

Tree-SHA512: ea1bac96a67f797519e8748ddd661cf0a1127cbc38f145b98f10cf9b54dcf0519b353062ce9888e1f51875497299c75ff5147566944451bc3fc117620e773489
2019-07-24 11:59:09 -05:00
Jonas Schnelli
2ada45284b
Merge #10864: Avoid redundant redeclaration of GetWarnings(const string&)
e0d459264 Avoid redundant redeclaration of GetWarnings(const string&) (practicalswift)

Pull request description:

  Avoid redundant redeclaration of `GetWarnings(const string&)`.

  `std::string GetWarnings(const std::string& strFor)` is declared in `warnings.h` and defined in `warnings.cpp`.

Tree-SHA512: d1503e00a2073cf080d66eafa303dc9c660a7ac15d4d2abcf2e4aa69cf9622d89a8e3f09324139bb7b8debaa6d1ee4a1c1681d347cebd99b1d3672a4da6d1ace
2019-07-24 11:59:09 -05:00
Jorge Timón
fa2cd234b2
\#10193 Introduce src/reverse_iterator.hpp and include it...
...where it will be needed

Taken from https://gist.github.com/arvidsson/7231973 with small
modifications to fit the bitcoin core project
2019-07-24 11:59:09 -05:00