* Add `transactionDetails` and `rewards` params to `getBlock` API of web3.js
* Add the same content to the legacy call
…because it's such a PITA to share config between two methods and not have Typedoc throw a fit.
* Add tests to exercise block deserialization in the case that `transactionDetails` is `none` or `accounts`
* Extract the annotated account key parser into a separate struct
* Parse the `getBlock()` responses differently depending on the mode
We currently use the is_connected field to be able to signal to
ReplayStage that a slot has replayable updates. It was discovered that
this functionality is effectively broken, and that is_connected is never
true. In order to convey this information to ReplayStage more
effectively, we need extra state information so this PR changes the
existing bool to bitflags with two bits.
From a compatibility standpoint, the is_connected bool was already
occupying one byte in the serialized SlotMeta in blockstore. Thus, the
change from a bool to bitflags still "fits" in that one byte allotment.
In consideration of a case where a client may wish to downgrade software
and use the same ledger, deserializing the bitflags into a bool could
fail if the new bit is set. As such, this PR introduces the second bit
field, but does not set it anywhere. Once clusters have mass adopted a
software version with this PR, a subsequent change to actually set and
use the new field can be introduced.
* reorganize error using DRY principle
* rename error `Format` to `Deserialization`
* Rename `EncryptionError` to `DiscreteLogError`
* resolve errors from rebase
* resolve clippy
* change `ProofInstructionError` to `ProofError`
* use files for merkle tree inputs on accounts hash
* remove multi-pass scan, simplify
* cleanup and comments
* rework writing into the hash file for clarity
* add test, cleanup
* rename
* move count into option
* Test that `TransactionMessage.decompile()` can decompile a legacy `Message`
* `TransactionMessage.decompile()` now correctly accounts for the number of writable unsigned accounts
The num_repair field is only blockstore insertion metric being updated
outside of Blockstore::insert() call chain; move the update to insert()
with the rest of the fields in BlockstoreInsertionMetrics struct.
* Add dump_node to update stake for heaviest subtrees
Additionally refactor subtrees to store children as a hashset
* Add a more complicated forks test
* chose -> choose
* remove is_dumped flag and reuse latest_invalid_ancestor instead