Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Improve error message about non-active segwit on simnet I started playing with simnet and was confronted with error message: ``` [ERR] FNDG: Unable to broadcast funding tx for ChannelPoint(<point>:0): -22: TX rejected: transaction <tx> has witness data, but segwit isn't active yet ``` I wasn't aware of the activation period so I got quite puzzled. Google helped. But I think the message could mention likely cause. Newly it optionally prints something like: ``` (The threshold for segwit activation is 300 blocks on simnet, current best height is 113) ``` * btcctl: add regtest mode to btcctl * build: replace travis-ci with github actions. test go 1.14 use golangci-lint * build: update deps * build: clean linter warnings * btcjson: change getblock default verbosity to 1 This change makes btcd's getblock command match bitcoind's. Previously the default verbosity was 0, which caused errors when using the rpcclient library to connect to a bitcoind node - getblock would unmarshall incorrectly since it didn't expect a verbosity=1 result when it did not specify verbosity. * rpcclient: send legacy GetBlock request for backwards compatibility Without this, users of this library wouldn't be able to issue GetBlock requests to nodes which haven't updated to support the latest request format, namely the use of a single `int` parameter to denote verbosity instead of two `bool`s. * rpcclient: Add cookie auth Based on Hugo Landau's cookie auth implementation for Namecoin's ncdns. Fixes btcsuite#1054 * rpcclient: Refactor cookie caching * rpcclient: Try user+pass auth before cookie auth * rpcclient: Read first line of cookie instead of trimming space * rpcclient: serialize nil inputs to empty list * Improve chain state init efficiency Remove unnecessary slice of all block indexes and remove DB iteration over all block indexes that used to determined the size of the slice. * Add blockchain.NewUtxoEntry() to directly create entries for UtxoViewpoint The current methods to add to a UtxoViewpoint don't allow for a situation where we have only UTXO data but not a whole transaction. This commit allows contstruction of a UtxoEntry without requiring a full MsgTx. AddTxOut() and AddTxOuts() both require a whole transaction, including the inputs, which are only used in order to calculate the txid. In some situations, such as with use of the utreexo accumulator, we only have the utxo data but not the transaction which created it. For reference, utreexo's initial usage of the blockchain.NewUtxoEntry() function is at https://github.com/mit-dci/utreexo/pull/135/files#diff-3f7b8f9991ea957f1f4ad9f5a95415f0R96 * Add getchaintxstats JSON-RPC client command * Add fundrawtransaction RPC call * Add getbalances RPC client command * rpcclient: Add GetTransactionWatchOnly method * peer: knownInventory, sentNonces - use generic lru While here, also rename and generalize limitMap and apply to other maps which need to be bounded. * btcec: Avoid panic in fieldVal.SetByteSlice for large inputs The implementation has been adapted from the dcrec module in dcrd. The bug was initially fixed in decred/dcrd@3d9cda1 while transitioning to a constant time algorithm. A large set of test vectors were subsequently added in decred/dcrd@8c6b52d. The function signature has been preserved for backwards compatibility. This means that returning whether the value has overflowed, and the corresponding test vectors have not been backported. This fixes btcsuite#1170 and closes a previous attempt to fix the bug in btcsuite#1178. * config+service_windows: add flag to disable win service To run integration tests with btcd on Windows in non-interactive environments (such as the Travis build with Windows machines), we need to make sure we can still spawn a child process instead of only a windows background service. * updated docs for getblock-verbosity fixes * Update json_rpc_api.md Corrections suggested by @onyb btcsuite#1608 (comment) * netsync: handle notfound messages from peers backport from decred/dcrd#2253 When a peer sends a notfound message, remove the hash from requested map. Also increase notfound ban score and return early if it disconnects the peer. * release: update release script path * release: remove old scripts and update process doc - remove prep_release.sh and notes.sample - update license in release.sh - add notes for maintainers on the release process - mention CHANGES file modifications * Update CHANGES file for 0.21.0 release Also updated changes for 0.20.1, and added a small note about changes since 0.12.0. * btcd: bump version to v0.21.0-beta * Handle Dash transaction version 3 * Handle new payload * Change version field size to int16 * Include payload size and payload in serialization process Co-authored-by: Antonin Hildebrand <antonin@hildebrand.cz> Co-authored-by: Dan Cline <kidscline01@gmail.com> Co-authored-by: David Hill <dhill@mindcry.org> Co-authored-by: Henry <henry.wfisher@gmail.com> Co-authored-by: Wilmer Paulino <wilmer.paulino@gmail.com> Co-authored-by: Olaoluwa Osuntokun <laolu32@gmail.com> Co-authored-by: JeremyRand <jeremyrand@airmail.cc> Co-authored-by: Torkel Rogstad <torkel@rogstad.io> Co-authored-by: Mikael Lindlof <mikuz.dev@gmail.com> Co-authored-by: adiabat <rx@awsomnet.org> Co-authored-by: Federico Bond <federicobond@gmail.com> Co-authored-by: Anirudha Bose <anirudha.bose@ledger.fr> Co-authored-by: Javed Khan <tuxcanfly@gmail.com> Co-authored-by: Anirudha Bose <anirudha.bose@alumni.cern> Co-authored-by: Oliver Gugger <gugger@gmail.com> Co-authored-by: qqjettkgjzhxmwj <37233887+JettScythe@users.noreply.github.com> Co-authored-by: Dan Cline <dan@dancline.net> Co-authored-by: John C. Vernaleo <jcv@netpurgatory.com> Co-authored-by: Mariusz Nowostawski <nowostawski@gmail.com>
- Loading branch information