SpikoHistoricalReader
Documentation for eth_defi.tokenised_fund.spiko.historical.SpikoHistoricalReader Python class.
- class SpikoHistoricalReader
Bases:
eth_defi.vault.base.VaultHistoricalReaderRead USTBL supply and issuer-published NAV/share history.
Spiko’s verified Oracle uses the Chainlink AggregatorV3 surface. The reader derives the public TVL estimate by multiplying each token-supply observation by the official NAV observation available at the scanned block.
Create an USTBL historical reader.
- Parameters
vault – USTBL adapter to read.
stateful – Whether to retain the shared adaptive reader state.
Attributes summary
addressfirst_blockMethods summary
__init__(vault, stateful)Create an USTBL historical reader.
Construct USTBL supply and official oracle calls.
process_result(block_number, timestamp, ...)Build one USTBL observation from multicall results.
- __init__(vault, stateful)
Create an USTBL historical reader.
- Parameters
vault (SpikoVault) – USTBL adapter to read.
stateful (bool) – Whether to retain the shared adaptive reader state.
- construct_multicalls()
Construct USTBL supply and official oracle calls.
- Returns
Token
totalSupplyand oraclelatestRoundDatacalls.- Return type
collections.abc.Iterable[eth_defi.event_reader.multicall_batcher.EncodedCall]
- process_result(block_number, timestamp, call_results)
Build one USTBL observation from multicall results.
- Parameters
block_number (int) – Sampled Ethereum block number.
timestamp (datetime.datetime) – Naive UTC timestamp of the sampled block.
call_results (list[eth_defi.event_reader.multicall_batcher.EncodedCallResult]) – Results for the calls built by this reader.
- Returns
USTBL supply, NAV/share, TVL and closed-flow status.
- Return type