* RPC: include orphans into mempool entries
* no need for + 1
* give request option to choose mempool pool(s)
* add to wallet, fix bg
* use orphanpool rpc to test for orphans
* fix fmt
* fix crash when quering orphan pool in get_mempool_entries
* pass the tests, fix fromAppMessage bug
* Update config_test.go
don't think this is needed
* needed for tests to pass
* inverse to transactionpoolfilter, cut down code to two ifs.
* fmt
* update test to true false, forgot one includetransactionpool renaming
* update and simplyfiy get_mempool_entry handler
* comment outdated
* i think we usually use make instead of var.
* Fix some leftovers of includeTransactionPool
Co-authored-by: Ori Newman <orinewman1@gmail.com>
* Fix RPC connections counting
* show incomming connections count
* Use the flag RPCMaxClients instead of the const RPCMaxInboundConnections
* Add grpc server name to log message
Co-authored-by: Michael Sutton <mikisiton2@gmail.com>
* Avoid creating the chain iterator if high hash is actually low hash
* Always use iterator in nextPruningPointAndCandidateByBlockHash
* Initial failing test
* Minimal failing test + some comments
* go lint
* Add simpler tests with two different errors
* Missed some error checks
* Minor
* A workaround patch for preventing the missing utxo child diff bug
* Make sure we fully resolve virtual
* Move ResolveVirtualWithMaxParam to test consensus
* Mark virtual not updated and loop in batches
* Refactor: remove VirtualChangeSet from functions return values
* Remove workaround comments
* If block has no body, virtual is still considered updated
* Remove special error ErrReverseUTXODiffsUTXODiffChildNotFound
Co-authored-by: Ori Newman <orinewman1@gmail.com>
* Avoid creating the chain iterator if high hash is actually low hash
* Always use iterator in nextPruningPointAndCandidateByBlockHash
Co-authored-by: Ori Newman <orinewman1@gmail.com>
* start
* pass tests, (cannot get before put!) and clean up.
* add rpc call.
* create and pass tests, fix bugs. fully implement rpc
* As always fmt
* remover old test
* clean up proto comment
* put the logger back in place.
* revert back to 10 sec limit.
* migration, change utxoChanged removal to whole utxoEntryPair, add methods to update circulating supply, intialize circulating supply from reset.
* Update utxoindex.go
* ad
* rename to max, change comment
* one more total to max
Co-authored-by: Ori Newman <orinewman1@gmail.com>
* Fix wallet parsing of multi tx data
* Output wallet msgs to stderr when creating/signing tx
* Fix go fmt
Co-authored-by: Ori Newman <orinewman1@gmail.com>
* include utxoIndex and isNearlySynced in GetInfo
* fmt fixing
* add missing IsNearlySynced
* change `isNearlySynced` -> `isSynced` & `isUtxoIndexSet` ->`isUtxoIndexed`
* Add a check for `HasPeers` to make `isSynced` identical to `GetBlockTemplate.isSynced`
Co-authored-by: msutton <mikisiton2@gmail.com>
* add wallet daemon state messages to a terminal window log
* refactoring changed var name to harmonize it
* fix global vars made the part of the "sever" class
* fix log message phrasing
Co-authored-by: Michael Sutton <mikisiton2@gmail.com>
* Move OnBlockAdded event to the channel that was only used by virtualChanged events
* Don't send notifications for header-only and invalid blocks
* Return block status from block processor and use it for event raising decision
* Use MaybeEnqueue for consensus events
* go lint
* Fix RPC call to actually include tx ids
Co-authored-by: msutton <mikisiton2@gmail.com>
* Increase virtualChangeChan to 100e3
Don't crash when sending UTXO RPC notification to a closed route
Throw error if virtualChangeChan is full
* Use MaybeEnqueue in more places
* Remove comment
* Ignore capacity reached errors on MaybeEnqueue
* Wallet synchronization improvement
* Much faster sync on startup
* Avoid double scan of the same address range
* Eliminate 1 sec delay on start
* Rename constant and add numIndexesToQueryForRecentAddresses const
Co-authored-by: Ori Newman <orinewman1@gmail.com>
* Use a channel from within consensus in order to raise change events in order -- note that this is only a draft commit for discussion
* Fix compilation
* Check for nil
* Allow nil virtualChangeChan
* Remove redundant comments
* Call notifyVirtualChange instead of notifyUTXOsChanged
* Remove redundant comment
* Add a separate function for initVirtualChangeHandler
* Remove redundant type
* Check for nil in the right place
* Fix integration test
* Add data to virtual changeset and cleanup block added event logic
* Renames
* Comment
Co-authored-by: Ori Newman <orinewman1@gmail.com>
* Allow blank address in NotifyUTXOsChanged to get all updates
* To see if address is possible to extract: Check for NonStandardTy rather than error
* Don't swallow errors
Co-authored-by: Ori Newman <orinewman1@gmail.com>
* Block template cache improvement
* Avoid concurrent calls to template builder
* Clear cache on new block event
* Move IsNearlySynced logic to within consensus and cache it for each template
* Use a single consensus call for building template and checking synced
Co-authored-by: msutton <mikisiton2@gmail.com>
* Add acceptedTransactionIds to GetVirtualSelectedParentChainFromBlockResponseMessage and VirtualSelectedParentChainChangedNotificationMessage
* Modify appmessage structs to include new fields
* Implement the functionality for acceptedTransactionID notifications
* Add missing field for IncludeAcceptedTransactionIds
* Notify of block added before notifying that chain changed
* Use consensushashing instead of Transaction.ID
* Don't notify of empty virtual changes
* Don't generate virtualChainChanged notification if there's nobody subscribed
* Fix test to not expect empty notifications
* Don't generate acceptedTransactionIDs if they were not requested by anyone
Co-authored-by: Ori Newman <orinewman1@gmail.com>
* Added option to choose from address in kaspawallet + fixed a bug with 0 change
* Checking if From is missing
* Fixed after merge to kaspad0.12
* Applying changes also to send command
* Better help description
* Fixed bug where we take all utxos except the one we wanted
* Swallow the parsing error only when we want to filter
* checking for wallet address directly
* go fmt
* Changing to `--from-address`
Co-authored-by: Ori Newman <orinewman1@gmail.com>
* Add "sweep" command to kaspawallet
* minor linting & layout improvements.
* contain code in "sweep"
* update to sweep.go
* formatting and bugs
* clean up renaming of ExtractTransaction functions
* Nicer formating of display
* address reveiw.
* one more sweeped -> swept
* missed one reveiw comment. (extra mass).
* remove redundant code from split function.
Co-authored-by: Ori Newman <orinewman1@gmail.com>
* Use separate than finality depth for merge set calculations after HF
* Add comments and edit error messages
* Fix TestValidateTransactionInContextAndPopulateFee
* Don't disconnect from node if isViolatingBoundedMergeDepth
* Use new merge root for virtual pick parents; apply HF1 daa score split for validation only
* Use `blue work` heuristic to skip irrelevant relay blocks
* Minor
* Make sure virtual's merge depth root is a real block
* For ghostdag data we always use the non-trusted data
* Fix TestBoundedMergeDepth and in IBD use VirtualMergeDepthRoot instead of MergeDepthRoot
* Update HF1DAAScore
* Make sure merge root and finality are called + avoid calculating virtual root twice
* Update block version to 1 after HF
* Update to v0.12.0
Co-authored-by: msutton <mikisiton2@gmail.com>
* Add send and sign commands to protobuf
* Added Send and Sign stubs in kaspawalletd server
* Implement Sign
* Implemented Send
* Allow Broadcast command to supply multiple transactions
* No longer prompt for password in DecryptMnemonics
* Rename TransactionIDs -> TxIDs to keep consistency with Broadcast
* Add some comments and formatting
Co-authored-by: Ori Newman <orinewman1@gmail.com>