Skip to content

Conversation

murka
Copy link

@murka murka commented Oct 1, 2025

Description:

This PR upgrade ton/evaa spellbook to EVAA V9 with backward compatibility to old versions of EVAA smart contracts.


Note

Adds EVAA V9 support across supply/withdraw/liquidate by parsing new logs, tracking protocol_version and subaccount_id, updating pool upgrade LTs, and adding a new asset.

  • EVAA V9 support
    • Add v9_upgrate_lt to macros/project/evaa/evaa_ton_pools.sql and populate for pools.
    • Derive protocol_version (v3/v4/v9) based on tx_lt vs upgrade LTs.
  • Models
    • models/evaa/ton/evaa_ton_supply.sql:
      • Split parsing for pre-v4 vs post-v4/V9; include protocol_version and subaccount_id (post-v4+).
    • models/evaa/ton/evaa_ton_withdraw.sql:
      • Support both log::withdraw_success and V9 log::supply_withdraw_success (opcode 0x16); extract withdraw records (with subaccount_id).
    • models/evaa/ton/evaa_ton_liquidate.sql:
      • Add V9 parsing branch; include protocol_version and subaccount_id; capture liquidator_address (post-v4+).
  • Schema updates (models/evaa/ton/evaa_ton_schema.yml)
    • Add protocol_version and subaccount_id columns to withdraw/supply model definitions; minor tag formatting.
  • Assets
    • models/evaa/ton/evaa_ton_assets.sql: add TONUSDT_STONFI mapping.

Written by Cursor Bugbot for commit 71398dd. This will update automatically on new commits. Configure here.

@murka murka marked this pull request as draft October 1, 2025 16:07
Copy link

github-actions bot commented Oct 1, 2025

CLA Assistant Lite bot All contributors have signed the CLA ✍️ ✅

@github-actions github-actions bot added WIP work in progress dbt: daily covers the Daily dbt subproject labels Oct 1, 2025
@murka
Copy link
Author

murka commented Oct 1, 2025

fyi: @shuva10v @iMCrazyDev @sepezho

@murka
Copy link
Author

murka commented Oct 1, 2025

I have read the CLA Document and I hereby sign the CLA

github-actions bot added a commit that referenced this pull request Oct 1, 2025
- name: pool_name
description: "EVAA pool name"
- name: protocol_version
description: "Protocol version (v3, v4, v9)"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • subaccount_id

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dbt: daily covers the Daily dbt subproject WIP work in progress

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants