Problem
The deposit and withdraw functions mutate the vault state and user balances silently, making it impossible for standard blockchain explorers to parse individual LP activity.
Expected behavior
Both functions use env.events().publish() to broadcast structured logs detailing the user address, underlying amount transferred, and ysTokens minted/burned.
Files to update
Project relevance
Provides the historical data layer required by external indexing tools and the internal analytics dashboard to chart user-specific portfolio activity over time.
Acceptance criteria
Problem
The
depositandwithdrawfunctions mutate the vault state and user balances silently, making it impossible for standard blockchain explorers to parse individual LP activity.Expected behavior
Both functions use
env.events().publish()to broadcast structured logs detailing the user address, underlying amount transferred, and ysTokens minted/burned.Files to update
src/vault.rssrc/test.rsProject relevance
Provides the historical data layer required by external indexing tools and the internal analytics dashboard to chart user-specific portfolio activity over time.
Acceptance criteria
Symbol::new(&env, "deposit")