fix: missing swap event for cw pool (backport #7938) #7950
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Closes: #XXX
What is the purpose of the change
Numia team has a problem tracking swap events for a CW pool. The reason is that the event is missing.
Context: https://osmosis-network.slack.com/archives/C04M8FQ5Y2G/p1712020788660349
While there is a workaround that they can implement, it would be a hack looking for events at another layer of abstraction.
I propose adding this change to the v24 scope. The core of the change is emitting the swap event in
x/cosmwasmpool
.I evaluated the option of emitting this at the poolmanager layer. However, given that we have many swap APIs, it would take some careful effort to make sure that nothing is missed. Given the above, it is cleaner and less risky to simply add the event at the
x/cosmwasmpool
level.Given that events are now state breaking, it is important to account for the above risks.
Documentation and Release Note
Unreleased
section ofCHANGELOG.md
?Where is the change documented?
x/{module}/README.md
)Summary by CodeRabbit
This is an automatic backport of pull request #7938 done by [Mergify](https://mergify.com).