You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
1- Clone wasmd repo
2- Build
3- Init a new chain, add a new key, add balance, create gentx, collect, run the chain
4- Store cw_template.wasm
5- Instantiate it
6- Query the contract
7- Check validator logs
Environment
wasmd version: v0.54.0
cosmos-sdk: v0.50.11
wasmvm: 2.2.1
Description of the bug
When ever someone queries a smart contract using smart queries, the node reports the following error:
that seems to be relative to the checkDiscountEligibility function, traking transaction count
wasmd/x/wasm/keeper/keeper.go
Line 871 in 04cb6e5
The same error happens also when a contract gets executed using a sudo message, for example from the governance module.
wasmd/x/wasm/keeper/keeper.go
Line 634 in 04cb6e5
From my debugging, it seems that TxContractsFromContex is returning ok = false
wasmd/x/wasm/types/context.go
Line 100 in 90b49fc
How to reproduce
1- Clone wasmd repo
2- Build
3- Init a new chain, add a new key, add balance, create gentx, collect, run the chain
4- Store cw_template.wasm
5- Instantiate it
6- Query the contract
7- Check validator logs
Additional notes
The same function (checkDiscountEligibility) works correctly when called from execute and instantiate transactions.
Everything is working correctly even if the error it's shown, simply all the query and sudo transactions are never discounted.
The text was updated successfully, but these errors were encountered: