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

add params query #969

Merged
merged 1 commit into from
Sep 1, 2022
Merged

Conversation

jhernandezb
Copy link
Contributor

@jhernandezb jhernandezb commented Aug 31, 2022

closes #889

> wasmd q wasm params
code_upload_access:
  address: ""
  permission: Everybody
instantiate_default_permission: Everybody

Should we add legacy queries for this?

@jhernandezb jhernandezb requested a review from alpe as a code owner August 31, 2022 17:00
@codecov
Copy link

codecov bot commented Aug 31, 2022

Codecov Report

Merging #969 (e54d56e) into main (e714fdf) will decrease coverage by 0.14%.
The diff coverage is 18.18%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #969      +/-   ##
==========================================
- Coverage   59.31%   59.17%   -0.15%     
==========================================
  Files          51       51              
  Lines        6229     6251      +22     
==========================================
+ Hits         3695     3699       +4     
- Misses       2268     2286      +18     
  Partials      266      266              
Impacted Files Coverage Δ
x/wasm/client/cli/query.go 0.00% <0.00%> (ø)
x/wasm/keeper/querier.go 70.58% <100.00%> (+0.58%) ⬆️

Copy link
Contributor

@alpe alpe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice! Thanks a lot for adding this feature! 💯

// QueryParamsResponse is the response type for the Query/Params RPC method.
message QueryParamsResponse {
// params defines the parameters of the module.
Params params = 1 [ (gogoproto.nullable) = false ];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍


require.Equal(t, paramsResponse.Params.CodeUploadAccess, types.AllowNobody)
require.Equal(t, paramsResponse.Params.InstantiateDefaultPermission, types.AccessTypeNobody)
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for adding tests! 🌻

@alpe alpe merged commit 0f2794c into CosmWasm:main Sep 1, 2022
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

Successfully merging this pull request may close these issues.

Add gRPC query for WASM params
2 participants