v3.11.1 – v3.13.0
These releases add fusion vault validate and make vault information and Morpho market data public SDK functions. They apply to developers who read vaults or Morpho markets from Python code and scripts. From v3.13.0, the vault read and the Morpho API helpers are imported from SDK modules in place of ipor_fusion.cli.
New
1. External State event decoding (v3.11.1)
Now: decode_external_state_event decodes the nine ExternalState (market 50) events the vault emits. It returns None for any other topic. A listed topic whose data or topics do not match the declaration raises ExternalStateEventDecodeError.
Usage: decode_external_state_event(log) is imported from ipor_fusion and takes one log. It returns an ExternalStateEvent or None.
2. Vault validation (v3.12.0)
Now: fusion vault validate prints a verdict (ok, warning or critical) and the findings. It exits 1 on a critical verdict. The same check is public as validate_vault in ipor_fusion.validation, which returns a frozen VaultValidation.
Usage: fusion vault validate from the CLI, or validate_vault(ctx, vault_address) in Python. With --json, the verdict is in the verdict field. Exit code 1 is also used for runtime errors.
3. Vault information as JSON (v3.13.0)
Before: the vault read and the fusion vault info --json document lived in private CLI helpers. Library users had to import private names from ipor_fusion.cli.
Now: fetch_vault_data in ipor_fusion.vault_data and build_vault_info_json in ipor_fusion.vault_info are public SDK functions. The fusion vault info text and JSON output are unchanged.
Usage: fetch_vault_data returns a VaultData. build_vault_info_json takes it and returns the fusion vault info --json document.
Breaking changes
1. Vault read and vault information imports (v3.13.0)
Before: the vault read, the explorer client and the unpriceable-token reader lived in ipor_fusion.cli.vault_fetcher, cli.explorer and cli.vault_unpriceable. The cache helpers lived in cli.config_store.
Now: those CLI modules are gone. The code moved without behaviour changes to ipor_fusion.vault_data, ipor_fusion.vault_info, ipor_fusion.explorer, ipor_fusion.cache and ipor_fusion.readers.unpriceable. fetch_vault_data, VaultData and fetch_deployment_info are imported from ipor_fusion.vault_data. build_vault_info_json(..., resolve_name=...) in ipor_fusion.vault_info replaces cli.vault_cmd._build_json_output. get_contract_name is imported from ipor_fusion.explorer, and the cache helpers from ipor_fusion.cache.
Applies to: code that imports from ipor_fusion.cli.vault_fetcher, cli.explorer or cli.vault_unpriceable, imports the cache helpers from cli.config_store, or calls cli.vault_cmd._build_json_output.
2. Morpho API and market summary imports (v3.13.0)
Before: the Morpho public GraphQL API client and the fusion market JSON builders lived in the CLI: ipor_fusion.cli.morpho_api, and the private builders _build_json and _meta_morpho_json in cli.market_cmd.
Now: they are public SDK modules. ipor_fusion.morpho_api holds fetch_market, fetch_vault and MorphoApiError. ipor_fusion.market_info holds build_morpho_blue_market_json (formerly _build_json) and build_meta_morpho_json (formerly _meta_morpho_json). The fusion market morpho-blue --json and meta-morpho --json output is unchanged.
Applies to: code that imports ipor_fusion.cli.morpho_api, or calls cli.market_cmd._build_json or _meta_morpho_json.
Fixes
1. Prices from the pre-audit price oracle (v3.11.1)
Before: the price oracle middleware deployed before the August 2024 audit returns getAssetPrice as a bare uint256. Decoding it as two words failed. On those vaults vault info reported every USD value as null, and vault oracle-mapping reported status “resolved” with a null price.
Now: price_oracle_middleware() returns LegacyPriceOracleMiddleware for the pre-audit middleware. It decodes the bare price.
Impact: vault info reports USD values on pre-audit vaults.
2. Blocks with long extra data (v3.11.2)
Before: some Avalanche blocks carry a 66-byte extraData, which web3’s block formatter rejects with a ValueError. vault info failed whenever the head was one of them.
Now: Web3Context.from_url injects ExtraDataToPOAMiddleware. Other blocks are left as they are.
Impact: None for existing code.
3. Near-liquidation positions listed as critical (v3.13.0)
Before: fusion vault info listed a lending position near liquidation among the warnings. Its own line read CRITICAL, and fusion vault validate counted it as critical.
Now: the position is listed among the criticals. In --json it moves from health_check.warnings to health_check.criticals.
Impact: scripts that parse the JSON output find this finding under health_check.criticals.
4. External State event decoder input (v3.11.2)
Before: a hex-text topic raised TypeError. An integer passed as data was coerced into zero bytes and decoded as a rescue of the zero address.
Now: the decoder accepts bytes-like values and 0x-prefixed hex text, from raw JSON-RPC logs and indexers alike. Once the topic is recognized, every malformed part raises ExternalStateEventDecodeError.
Impact: None for existing code.
Upgrade with pip install -U ipor-fusion. Full changelog: v3.11.1 on GitHub, v3.11.2 on GitHub, v3.12.0 on GitHub, v3.13.0 on GitHub.
These notes describe changes to the IPOR Fusion SDK. They are not operational or financial advice. Operators are responsible for testing changes against their own vaults and configuration before use.