-
Notifications
You must be signed in to change notification settings - Fork 254
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
Fix contracts integration test #679
Conversation
I was trying the same thing, then decided to adjust the
But couldn't find any appropriate values that would accept our dummy contract, which is strange. I also waited for 2 blocks between the |
The issue appears to have been introduced in paritytech/substrate#12383 |
Replicating the test using the old API resulted in the same behavior: use crate::node_runtime::runtime_types::sp_weights::OldWeight;
let instantiate_tx = node_runtime::tx().contracts().instantiate_old_weight(
100_000_000_000_000_000, // endowment
OldWeight(
1_295_000_000_000,
), // gas_limit
None, // storage_deposit_limit
code_hash,
data,
salt,
); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for fixing this! LGTM!
Prior to paritytech/substrate#12383, setting
proof_size
to0
worked for all extrinsics. Following that a proper value needed to be supplied. Howeveru64::MAX
was too high as it breached the limit for normal class transactions weight (I think about0.75 * MAX_BLOCK_WEIGHT
).Interestingly
0
still worked forinstantiate_with_code
andcall
, but the fix was to set it tou64::MAX / 2
.