tokenised_fund.backfill
Documentation for eth_defi.tokenised_fund.backfill Python module.
Coordinate tokenised-fund metadata and historical backfills.
Each protocol owns its implementation in
eth_defi.tokenised_fund.<protocol>.backfill beside its vault adapter. This
module provides the stable registry used by the generic operator script.
Module Attributes
Canonical protocol selectors accepted by the |
Functions
Make the default all-protocol run tolerate unavailable private data. |
|
|
Run tokenised-fund backfills selected through environment variables. |
|
Parse and validate a comma-separated protocol selection. |
|
Run selected protocol backfills sequentially. |
- PROTOCOL_BACKFILLS: dict[str, collections.abc.Callable[[], None]] = {'asseto': <function main>, 'centrifuge': <function main>, 'franklin': <function main>, 'kinexys': <function main>, 'libeara': <function main>, 'ondo': <function main>, 'securitize': <function main>, 'spiko': <function main>, 'superstate': <function main>, 'sygnum': <function main>, 'theo': <function main>, 'usyc': <function main>, 'wisdomtree': <function main>}
Canonical protocol selectors accepted by the
PROTOCOLSenvironment variable.
- parse_protocols(value)
Parse and validate a comma-separated protocol selection.
An unset or blank value selects every registered protocol in deterministic registry order. Duplicate selectors are removed without changing order.
- Parameters
- Returns
Validated protocol slugs.
- Raises
ValueError – If an unknown protocol is requested.
- Return type
- run_protocol_backfills(protocols)
Run selected protocol backfills sequentially.
Protocol backfills intentionally share the configured vault database, reader-state and Parquet paths, so deterministic sequential execution avoids concurrent file replacement.
- Parameters
protocols (collections.abc.Iterable[str]) – Validated protocol slugs.
- Returns
Completed protocol slugs.
- Return type
- configure_optional_private_backfills(protocols_value, protocols)
Make the default all-protocol run tolerate unavailable private data.
WisdomTree metadata is public on-chain, but its official NAV history needs a private DataSpan API key. The implicit all-protocol workflow therefore registers its metadata and skips only the private price scan when neither the key nor an explicit price-scan choice is present. Explicit WisdomTree selections continue to fail closed without the credential.
- main()
Run tokenised-fund backfills selected through environment variables.
DRY_RUNdefaults totruefor the aggregate entry point. Operators must explicitly setDRY_RUN=falsebefore any protocol may write.PROTOCOLSdefaults to all registered integrations.- Returns
None.
- Return type
None