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

[Feature] WASM oracle querier #405

Merged
merged 1 commit into from
Sep 22, 2020
Merged

Conversation

yun-yeo
Copy link
Contributor

@yun-yeo yun-yeo commented Sep 22, 2020

Summary of changes

  • Add oracle wasm query interface

It will allow a contract to query exchange rates with any pairs of base/quote denom.

{
   "base_denom": "uusd",
   "quote_denoms": ["uluna", "ukrw",...],
}

Response and query interface can be found https://github.com/terra-project/terra-cosmwasm-bindings

close #404

Report of required housekeeping

  • Github issue OR spec proposal link
  • Wrote tests
  • Updated API documentation (client/lcd/swagger-ui/swagger.yaml)
  • Added a relevant changelog entry: clog add [section] [stanza] [message]

(FOR ADMIN) Before merging

  • Added appropriate labels to PR
  • Squashed all commits, uses message "Merge pull request #XYZ: [title]" (coding standards)
  • Confirm added tests are consistent with the intended behavior of changes
  • Ensure all tests pass

@yun-yeo yun-yeo added enhancement New feature or request wasm Wasm contract related update labels Sep 22, 2020
@yun-yeo yun-yeo self-assigned this Sep 22, 2020
@codecov
Copy link

codecov bot commented Sep 22, 2020

Codecov Report

Merging #405 into develop will increase coverage by 1.52%.
The diff coverage is 88.46%.

Impacted file tree graph

@@             Coverage Diff             @@
##           develop     #405      +/-   ##
===========================================
+ Coverage    66.19%   67.72%   +1.52%     
===========================================
  Files          116      117       +1     
  Lines         5887     5035     -852     
===========================================
- Hits          3897     3410     -487     
+ Misses        1771     1414     -357     
+ Partials       219      211       -8     
Impacted Files Coverage Δ
x/wasm/internal/types/query_binding.go 0.00% <ø> (ø)
x/oracle/wasm/interface.go 87.50% <87.50%> (ø)
app/app.go 92.00% <100.00%> (+4.56%) ⬆️
x/wasm/internal/keeper/test_utils.go 91.21% <100.00%> (+0.22%) ⬆️
x/wasm/internal/keeper/connector.go 47.82% <0.00%> (-9.32%) ⬇️
x/oracle/internal/types/hash.go 54.92% <0.00%> (-7.18%) ⬇️
x/oracle/internal/types/genesis.go 59.25% <0.00%> (-5.26%) ⬇️
x/market/genesis.go 75.00% <0.00%> (-5.00%) ⬇️
x/wasm/genesis.go 70.73% <0.00%> (-4.78%) ⬇️
x/oracle/internal/keeper/reward.go 70.00% <0.00%> (-3.92%) ⬇️
... and 111 more

@hanjukim hanjukim merged commit ce1b2ca into develop Sep 22, 2020
@yun-yeo yun-yeo deleted the feature/wasm-oracle-querier branch September 22, 2020 09:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request wasm Wasm contract related update
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[FEATURE] WASM oracle exchange rate querier
2 participants