clean_yearn_vault_metadata

Documentation for eth_defi.erc_4626.vault_protocol.yearn.export_cleanup.clean_yearn_vault_metadata function.

clean_yearn_vault_metadata(vault_db)

Best-effort cleanup of false Yearn protocol attribution.

The function performs one catalogue request and one Pandas membership operation for the current export. It considers rows currently labelled Yearn and already-generic rows carrying the exclusion marker, so stale sticky curator or homepage fields are corrected too. Any request or validation error is logged and converted to an empty change set so callers can continue publishing the rest of the vault data.

Parameters

vault_db (eth_defi.vault.vaultdb.VaultDatabase) – In-memory database loaded for the current JSON export.

Returns

Vault IDs whose export attribution was cleaned.

Return type

set[str]