Commit Graph

12 Commits

Author SHA1 Message Date
Zizou
568f26116e feat: add native balance in StorageChanges (#292)
* feat: add native balance in StorageChanges

This will be used by the next update of DCI to properly track native balance for all the contract that it's indexing. Also added a performance optimization, we now ignore slot updates if the value after the transaction is the same than before.

* docs: add docs on how to generate test assets

---------

Co-authored-by: zizou <111426680+flopell@users.noreply.github.com>
2025-10-06 10:12:37 +00:00
Zizou
12369c3981 fix: update get_block_storage_changes to correctly emit previous value (#280)
Before this commit we were using the latest `ContractSlot` for both previous and new value. This is not correct because if the value changed twice we would have the middle value emitted as "previous". For example if a value was changed like this in a single transaction 1 -> 10 -> 2 we would have `new_value=2` and `previous_values=10` while the previous value was actually 1.

Co-authored-by: zizou <111426680+flopell@users.noreply.github.com>
2025-09-25 17:41:07 +02:00
kayibal
655fae77ab chore: Bump tycho-substreams version 2025-09-05 12:37:40 +01:00
Louise Poole
1c6c2c53c7 chore: bump tycho-substreams crate version (#223)
* chore: bump tycho-substreams crate version

* chore: update cargo.lock
2025-06-25 17:48:46 +02:00
Zizou
27f178de59 fix(sdk): properly handle deletion -> creation -> deletion sequence (#213)
* fix(sdk): properly handle deletion -> creation -> deletion sequence

This commit resolves a bug that occurred when an attribute underwent a deletion, followed by creation, and then another deletion. The system would incorrectly ignore the final deletion because the attribute was mistakenly marked as newly created during the process.

* docs: fix typo

Co-authored-by: Louise Poole <louisecarmenpoole@gmail.com>

---------

Co-authored-by: zizou <111426680+flopell@users.noreply.github.com>
Co-authored-by: Louise Poole <louisecarmenpoole@gmail.com>
2025-06-24 09:41:10 +00:00
Zizou
52d502198e fix: stop using buggy account_creations for creation tagging. (#201)
the `call.account_creations` field had been deprecated by Substreams because of some edge cases where a new account wasn't detected.
This commit removes the usage of this field in our sdk contract extraction logic and some others specific places. We decided to rely on the call type instead. This approach should be much more robust.

Co-authored-by: zizou <111426680+flopell@users.noreply.github.com>
2025-05-13 12:25:14 +02:00
kayibal
0313c9b498 chore: Publish tycho-substreams to crates.io 2025-03-26 17:47:26 +01:00
Zizou
39934347b3 refactor(substreams): remove workspace dependencies (#129)
This is to make each substreams completely independent, before when we would need a new version of a dependency, we would have to change it for every crate which would lead to a change of every substreams module hash. We want to make every Substreams completely independant and frozen, this also helps to maintain a correct versionning.

Co-authored-by: zizou <111426680+flopell@users.noreply.github.com>
2025-01-07 16:04:17 +00:00
kayibal
148fac276c feat(balancer): Add rate providers to static attributes.
Adds the rate providers and additional attributes to balancers static attributes. These will help in the future to migrate some of the components to use the DCI.

Adds a small attributes module to tycho-substreams to make json encoding a bit easier.
2024-07-25 14:11:29 +01:00
Florian Pellissier
7dbf3ffac6 feat: Add a generic function to extract balance deltas from Transfer events. 2024-07-12 14:59:23 +02:00
kayibal
425628ae97 Create a workspace and make clippy happy. 2024-03-14 00:19:54 +00:00
kayibal
e62cc13c0b Move crates under substreams directory.
This way we can run GHA jobs depending on what files changed.
2024-03-13 23:57:23 +00:00