-
Notifications
You must be signed in to change notification settings - Fork 411
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
Handle wasmvm Burn message #489
Conversation
Codecov Report
@@ Coverage Diff @@
## wasmvm-0.14.0-beta3 #489 +/- ##
=======================================================
+ Coverage 56.89% 56.97% +0.07%
=======================================================
Files 41 41
Lines 4396 4411 +15
=======================================================
+ Hits 2501 2513 +12
- Misses 1687 1689 +2
- Partials 208 209 +1
|
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.
Great stuff. Thanks
@@ -15,8 +15,8 @@ WORKDIR /code | |||
COPY . /code/ | |||
|
|||
# See https://github.com/CosmWasm/wasmvm/releases | |||
ADD https://github.com/CosmWasm/wasmvm/releases/download/v0.14.0-beta1/libwasmvm_muslc.a /lib/libwasmvm_muslc.a | |||
RUN sha256sum /lib/libwasmvm_muslc.a | grep b69cf9ffbdfb2f1bd1e6f730ecee1eb0d06a1473840a24709aec7a7df5907d45 | |||
ADD https://github.com/CosmWasm/wasmvm/releases/download/v0.14.0-beta3/libwasmvm_muslc.a /lib/libwasmvm_muslc.a |
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.
Ah, you fixed this. Thank you
@@ -181,6 +181,7 @@ var ( | |||
stakingtypes.NotBondedPoolName: {authtypes.Burner, authtypes.Staking}, | |||
govtypes.ModuleName: {authtypes.Burner}, | |||
ibctransfertypes.ModuleName: {authtypes.Minter, authtypes.Burner}, | |||
wasm.ModuleName: {authtypes.Burner}, |
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.
💯
|
||
var _ Messenger = MessageHandlerFunc(nil) | ||
|
||
// MessageHandlerFunc is a helper to construct simple function based message handler |
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.
I like it.
if err != nil { | ||
return nil, nil, err | ||
} | ||
if err := burner.SendCoinsFromAccountToModule(ctx, contractAddr, types.ModuleName, coins); err != nil { |
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.
Ah, it is a two step process? Only module accounts can burn.
Glad you took this on and not me. So many gotchas
require.NoError(t, err) | ||
example := InstantiateHackatomExampleContract(t, ctx, keepers) // with deposit of 100 stake | ||
|
||
specs := map[string]struct { |
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.
👍
Continue #479