Commit Graph

14496 Commits

Author SHA1 Message Date
Jack Grigg a7f9365fb8 test: Set hashFinalSaplingRoot default correctly in create_block 2020-11-18 11:12:09 +00:00
Jack Grigg 030a685392 test: Fix SignatureHash RPC test helper
- Check validity of inIdx.
- ZIP 143 and 243 support.
2020-11-18 11:11:54 +00:00
Jack Grigg bbed3ecc3c test: Remove FindAndDelete from RPC test framework 2020-11-17 18:48:32 +00:00
Jack Grigg 8bc0a591a0 Revert "remove SignatureHash from python rpc tests"
This reverts commit 910ff448d6.
2020-11-17 18:48:32 +00:00
Jesse Cohen aead91419e [doc][trivial] no retargeting in regtest mode 2020-11-17 18:48:32 +00:00
Eric Lombrozo 03f1d38e04 Added fPowNoRetargeting field to Consensus::Params that disables nBits recalculation.
Zcash: Moved conditional into GetNextWorkRequired(), as we had rewritten
CalculateNextWorkRequired() to not have the necessary information. This
means that CalculateNextWorkRequired() will in unit tests calculate what
regtest would use were the new field not set; this is irrelevant, as only
GetNextWorkRequired() is used directly in consensus rules.
2020-11-17 18:48:32 +00:00
Homu 20dd32fe9b Auto merge of #4871 - rex4539:typos, r=str4d
Fix typo
2020-11-17 14:55:24 +00:00
Dimitris Apostolou 31e220a316
Fix typo 2020-11-17 16:33:31 +02:00
mdr0id 4dc94c954f Update expected fails for Sprout txns flows on Canopy 2020-11-16 15:57:49 -08:00
Homu 33fdb1b4bc Auto merge of #4868 - daira:clean-removes-lib, r=str4d
Windows cross-build generates .lib files, which should be ignored by git and removed by clean

Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2020-11-16 21:34:08 +00:00
Homu 6d856869e9 Auto merge of #4869 - zcash:release-v4.1.1, r=nuttycom
Release v4.1.1

Optimize release build
----------------------
The release build now sets CLAGS/CXXFLAGS to use the -O3 optimization
option, which turns on more optimization flags than the previously used
-O1. This produces a faster build, addressing a performance regression in
v4.1.0.

Correctly report Founders' Reward amount in `getblocktemplate`
--------------------------------------------------------------
This release correctly returns the `foundersreward` field from `getblocktemplate`
output pre-Canopy and removes the field post-Canopy. (The Founders' Reward will
expire exactly as Canopy activates, as specified in [ZIP 207](https://zips.z.cash/zip-0207).)
To obtain information about funding stream amounts, use `getblocksubsidy HEIGHT`,
passing in the height returned by the `getblocktemplate` API.
2020-11-16 18:45:38 +00:00
Kris Nuttycombe 251405491b Add notable changes to release notes for v4.1.1 2020-11-16 10:26:11 -07:00
Kris Nuttycombe 7ec8a9c5f4 make-release.py: Updated release notes and changelog for 4.1.1. 2020-11-16 10:23:40 -07:00
Kris Nuttycombe 092829cf5b make-release.py: Updated manpages for 4.1.1. 2020-11-16 10:23:40 -07:00
Kris Nuttycombe 142328b067 make-release.py: Versioning changes for 4.1.1. 2020-11-16 10:07:07 -07:00
Daira Hopwood f6fc97f35e Windows cross-build generates .lib files, which should be ignored by git and removed by clean.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2020-11-16 11:03:22 +00:00
Homu 9248cd743b Auto merge of #4864 - daira:go-faster, r=daira
Set release CFLAGS/CXXFLAGS to use -O3.

Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2020-11-14 08:15:23 +00:00
Homu 61ebef4095 Auto merge of #4865 - nuttycom:fix/shielded_coinbase_fr_rpc_fields, r=str4d
Correctly report founder's reward amount in getblocktemplate prior to Canopy

Previously this would return incorrect results in the case that the
miner reward was sent to a shielded address. Post-Canopy, the
foundersreward field is removed; this information should be obtained
from getblocksubsidy instead.
2020-11-14 04:24:14 +00:00
Kris Nuttycombe c8a90d9b98
Update getblocktemplate documentation.
Co-authored-by: str4d <thestr4d@gmail.com>
2020-11-13 17:09:29 -07:00
Kris Nuttycombe 1a89167944 Document how to get block subsidy information in getblocktemplate. 2020-11-13 16:36:36 -07:00
Kris Nuttycombe d107cf13b6 Correctly report founder's reward amount in getblocktemplate prior to Canopy
Previously this would return incorrect results in the case that the
miner reward was sent to a shielded address. Post-Canopy, the
foundersreward field is removed; this information should be obtained
from getblocksubsidy instead.
2020-11-13 16:25:37 -07:00
Daira Hopwood a0a87ab413 Set release CFLAGS/CXXFLAGS to use -O3.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2020-11-13 22:39:17 +00:00
Homu 0ccc885371 Auto merge of #4863 - nuttycom:fix/ibd_flag_check_order, r=daira
Change order of checks to skip IsInitialBlockDownload check if flag is unset.
2020-11-13 21:49:27 +00:00
Kris Nuttycombe b5ad4cfc5e Change order of checks to skip IsInitialBlockDownload check if flag is unset. 2020-11-13 12:59:14 -07:00
furszy 2be143a20b
sendmany::find_unspent_notes removing an unneeded recursive lock, GetFilteredNotes is already locking cs_main and cs_wallet. 2020-11-13 10:56:39 -03:00
furszy b4e6353f29
asyncOp sendmany: moved inputs total amount check inside load_utxo before the dust validation. 2020-11-13 10:23:59 -03:00
furszy ca9fc49fc4
rpc_wallet_tests: changed "Insufficient funds" error message to a proper "Insufficient transparent funds". This is because we are now throwing the insufficient transparent balance rpc error inside load_utxo. 2020-11-13 10:23:59 -03:00
furszy 3a1b51900c
Improving asyncoperation_sendmany, removing another redundant for loop over all of the available utxos.
What the commits is essentially doing is:
 1) Decouple transparent inputs load into its own method (making use of the recently added TxValues helper).
 2) Move load transactions inputs right after get the available coins from the wallet inside find_utxos.
 3) Remove the redundant loop over the available utxo to calculate the _inputs_total value that occurs after calling find_utxos (_inputs_total is being calculated inside the inputs selection loop only once now, inside load_utxos).
2020-11-13 10:23:58 -03:00
furszy 2c7b08029d
sendmany operation: Creating TxValues struct to store the transaction values in a more organized manner. 2020-11-13 10:23:58 -03:00
furszy a9f3315872
move-only: asyncOp_sendmany, target amount calculation moved before find inputs (utxos and notes). 2020-11-13 10:23:58 -03:00
furszy 88eef56581
sendmany: removing now unused SendManyInputUTXO class. 2020-11-13 10:23:58 -03:00
furszy 726daeee4e
asyncRPCOperation_sendmany:find_utxos, removing a redundant loop over all of the available utxo in the wallet. 2020-11-13 10:23:58 -03:00
furszy c84390279c
COutput: implemented Value() method. 2020-11-13 10:23:58 -03:00
furszy d8e154ebfb
wallet:COutput adding fIsCoinbase member. 2020-11-13 10:23:58 -03:00
furszy a1b7cd4b05
sendmany::find_utxo removing an unneeded recursive lock, AvailableCoins is already locking cs_main and cs_wallet. 2020-11-13 10:23:57 -03:00
furszy 359a05d6ae
wallet:AvailableCoins filter by destination/s feature implemented + connected to sendmany async operation. 2020-11-13 10:23:56 -03:00
furszy 4007e24ed0
asyncrpcoperation_sendmany::find_utxos removing a redundant coinbase check, coinbases are already being filtered by the AvailableCoins flag. 2020-11-13 10:22:33 -03:00
furszy fbfb2c0339
wallet:AvailableCoins nMinDepth filter implemented + connected to sendmany async operation. 2020-11-13 10:22:31 -03:00
furszy e4e9712d08
wallet:AvailableCoins fOnlySpendable filtering flag implemented + connected to sendmany async operation. 2020-11-13 10:17:39 -03:00
Homu ac792a3947 Auto merge of #4860 - daira:clarify-meantarget, r=daira
GetNextWorkRequired: clarify why this computation is equivalent to that in the protocol spec

refs https://github.com/zcash/zips/pull/418 cc: @teor2345

Comment-only change; no documentation or testing required.

Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2020-11-12 14:10:57 +00:00
Daira Hopwood 4d16bfd181 GetNextWorkRequired: clarify why this computation is equivalent to that in the protocol spec.
refs https://github.com/zcash/zips/pull/418

Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2020-11-12 10:52:49 +00:00
Jack Grigg 6c43a57e78 test: Use default shielded address in RPC tests where the type is irrelevant
This means we are running these tests against the recommended functionality,
and that these RPC tests will now use the faster Sapling addresses.
2020-11-11 22:43:26 +00:00
Homu 5c47b9bb08 Auto merge of #4852 - str4d:cargo-update, r=str4d
Update Rust dependencies
2020-11-11 00:40:35 +00:00
Jack Grigg 120b184d8f cargo update 2020-11-10 21:39:55 +00:00
Homu 091f5d7816 Auto merge of #4851 - adityapk00:mining_fix, r=str4d
Don't compile ehHashState::* if mining is disabled

Compile currently fails if using `CONFIGURE_FLAGS=--disable-mining`, because the `ehHashState::*` functions inadvertently get included.
2020-11-10 20:50:38 +00:00
adityapk00 7732b9aff2 Don't compile ehHashState::* if mining is disabled 2020-11-10 11:31:47 -08:00
Homu 60331b9e83 Auto merge of #4574 - oxarbitrage:issue4475, r=daira
Add blockhash parameter to getrawtransaction

Code ported manually from https://github.com/bitcoin/bitcoin/pull/10275 in attempt to fix https://github.com/zcash/zcash/issues/4475
2020-11-10 15:52:11 +00:00
Daira Hopwood 5701095c22
Wording improvements to getrawtransaction RPC documentation 2020-11-10 14:41:07 +00:00
Homu caed4adf50 Auto merge of #4849 - str4d:lint-fixes, r=str4d
Lint fixes

Fixes most lints currently reported by `test/lint/lint-all.sh`.

Includes changes cherry-picked from the following upstream PRs:
- bitcoin/bitcoin#8700
- bitcoin/bitcoin#8840
- bitcoin/bitcoin#9867
  - We backported the second commit in zcash/zcash#3146
- bitcoin/bitcoin#10771
- bitcoin/bitcoin#11394
- bitcoin/bitcoin#11649
- bitcoin/bitcoin#17329
- bitcoin/bitcoin#19258
2020-11-10 01:42:15 +00:00
str4d e531d72337
doc: Adjust subtree developer notes to refer to Zcash
We don't maintain any of the current subtrees, but we might in future.

Co-authored-by: Daira Hopwood <daira@jacaranda.org>
2020-11-10 01:40:51 +00:00