LagoonSettlementEvent

Documentation for eth_defi.lagoon.analysis.LagoonSettlementEvent Python class.

class LagoonSettlementEvent

Bases: object

Capture Lagoon vault flow when it is settled.

  • Use to adjust vault treasury balances for internal accounting

  • Shows the Lagoon vault status after the settlement at a certain block height

  • We do not capture individual users

The cycle is - Value vault - Settle deposits (USD in) and redeemds (USDC out, shares in) - Because valuation is done before the settle, you need to be careful what the values reflect here - We pull some values from receipt, some values at the end of the block

Attributes summary

chain_id

tx_hash

block_number

timestamp

vault

deposit_events

redeem_events

deposited

redeemed

shares_minted

shares_burned

total_assets

total_supply

share_price

pending_redemptions_underlying

pending_redemptions_shares

underlying_balance

share_token

Get USDC.

underlying

Get USDC.

Methods summary

__init__(chain_id, tx_hash, block_number, ...)

get_serialiable_diagnostics_data()

JSON serialisable diagnostics data for logging

get_underlying_balance()

How much of treasury we are holding after this update

get_underlying_diff()

How much the underlying asset changed in the vault treasury

__init__(chain_id, tx_hash, block_number, timestamp, vault, deposit_events, redeem_events, deposited, redeemed, shares_minted, shares_burned, total_assets, total_supply, share_price, pending_redemptions_underlying, pending_redemptions_shares, underlying_balance)
Parameters
Return type

None

get_serialiable_diagnostics_data()

JSON serialisable diagnostics data for logging

Return type

dict

get_underlying_balance()

How much of treasury we are holding after this update

Return type

decimal.Decimal

get_underlying_diff()

How much the underlying asset changed in the vault treasury

Return type

decimal.Decimal

property share_token: eth_defi.token.TokenDetails

Get USDC.

property underlying: eth_defi.token.TokenDetails

Get USDC.