From a80375f2b1edb87866e4296b3a8bf67405153560 Mon Sep 17 00:00:00 2001 From: mendesfabio Date: Mon, 6 May 2024 13:12:04 -0300 Subject: [PATCH 1/2] fix holders count --- src/mappings/vault.ts | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/mappings/vault.ts b/src/mappings/vault.ts index 1c0622ca..c6f8063e 100644 --- a/src/mappings/vault.ts +++ b/src/mappings/vault.ts @@ -253,6 +253,8 @@ function handlePoolJoined(event: PoolBalanceChanged): void { } } + pool.save(); + // Managed, StablePhantom and ComposableStable pools only emit the PoolBalanceChanged event // with a non-zero value for the BPT amount when the pool is initialized, // when the amount of BPT informed in the event corresponds to the "excess" BPT that was preminted @@ -267,6 +269,9 @@ function handlePoolJoined(event: PoolBalanceChanged): void { } } pool.totalShares = pool.totalShares.minus(scaledPreMintedBpt); + + pool.save(); + // This amount will also be transferred to the vault, // causing the vault's 'user shares' to incorrectly increase, // so we need to negate it. We do so by processing a mock transfer event @@ -288,8 +293,6 @@ function handlePoolJoined(event: PoolBalanceChanged): void { handleTransfer(mockEvent); } - pool.save(); - updatePoolLiquidity(poolId, event.block.number, event.block.timestamp); } From e68786a845461030c304b737fd649e45d4d57d59 Mon Sep 17 00:00:00 2001 From: mendesfabio Date: Mon, 6 May 2024 13:12:34 -0300 Subject: [PATCH 2/2] disable mainnet grafting --- networks.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/networks.yaml b/networks.yaml index 29d80ce8..8c3a4daa 100644 --- a/networks.yaml +++ b/networks.yaml @@ -2,10 +2,10 @@ mainnet: network: mainnet graft: # Apr-11-2024 02:34:11 PM +UTC - block: 19633000 + # block: 19633000 # always make sure the base subgraph has not been pruned # it should be possible to run time travel queries on it going back to the vault's startBlock - base: QmX6XKG5dSUf2FjKpeAdVPjbZSZ5qptnGGegHcwk4367Ph + # base: QmX6XKG5dSUf2FjKpeAdVPjbZSZ5qptnGGegHcwk4367Ph EventEmitter: address: "0x1ACfEEA57d2ac674d7E65964f155AB9348A6C290" startBlock: 16419620