Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No events are given to reply from other than wasm submsg #1995

Open
loloicci opened this issue Jan 15, 2024 · 3 comments
Open

No events are given to reply from other than wasm submsg #1995

loloicci opened this issue Jan 15, 2024 · 3 comments

Comments

@loloicci
Copy link
Contributor

loloicci commented Jan 15, 2024

The comment

/// with full Cosmos SDK events.
(SubMsgResponse is a field of Reply) says this contains all the SDK events.
However, x/wasm discards events from other than wasm submsg in https://github.com/CosmWasm/wasmd/blob/07c8beea006cd009e0c7b865fb32753f61221e1b/x/wasm/keeper/msg_dispatcher.go#L117 and this is passed to reply in https://github.com/CosmWasm/wasmd/blob/07c8beea006cd009e0c7b865fb32753f61221e1b/x/wasm/keeper/msg_dispatcher.go#L147.

Is it intentional? And if it is, I think the reason should be written in spec and cosmwasm's comment for SubMsgResponse.

@webmaster128
Copy link
Member

Thank you for bringing this up. The filtering was added for good reason (which I do not know in detail at this point). We'll update the docs to highlight this. Moving to the cosmwasm repo.

@webmaster128 webmaster128 transferred this issue from CosmWasm/wasmd Jan 18, 2024
@loloicci
Copy link
Contributor Author

Thank you @webmaster128 for your reply and for updating the docs! If you know who knows this well, could you give this question or tell this ISSUE to them?

@p0mvn
Copy link

p0mvn commented Mar 1, 2024

This leads to the fact that we charge gas for the attributes but not the events here:
https://github.com/CosmWasm/wasmd/blob/09c49d81d38990d232080069b9804af35d68a1b0/x/wasm/keeper/gas_register.go#L200-L211

What are the reasons for this behavior? If we filter events, should we also filter out their attributes?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants