Skip to content

Commit

Permalink
Merge pull request tendermint#198 from kogisin/kogisin/197-naming-con…
Browse files Browse the repository at this point in the history
…sistency

feat: change naming for consistency in public proposals
  • Loading branch information
jaybxyz authored Oct 27, 2021
2 parents 4a8eadd + 4235393 commit dea1446
Show file tree
Hide file tree
Showing 24 changed files with 453 additions and 739 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

# Farming Module

A farming module is a Cosmos SDK module that implements farming functionality, which provides farming rewards to participants called farmers. A primary use case is to use this module to provide incentives for liquidity pool investors for their pool participation.
The farming module is a Cosmos SDK module that implements farming functionality, which provides farming rewards to participants called farmers. A primary use case is to use this module to provide incentives for liquidity pool investors for their pool participation.

**Farming module v1 is in active development**
- see the [main](https://github.com/tendermint/farming/tree/main) branch for the latest
Expand Down
2 changes: 1 addition & 1 deletion app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,7 @@ func NewFarmingApp(
AddRoute(paramproposal.RouterKey, params.NewParamChangeProposalHandler(app.ParamsKeeper)).
AddRoute(distrtypes.RouterKey, distr.NewCommunityPoolSpendProposalHandler(app.DistrKeeper)).
AddRoute(upgradetypes.RouterKey, upgrade.NewSoftwareUpgradeProposalHandler(app.UpgradeKeeper)).
AddRoute(farmingtypes.RouterKey, farming.NewPublicPlanProposal(app.FarmingKeeper))
AddRoute(farmingtypes.RouterKey, farming.NewPublicPlanProposalHandler(app.FarmingKeeper))

govKeeper := govkeeper.NewKeeper(
appCodec, keys[govtypes.StoreKey], app.GetSubspace(govtypes.ModuleName), app.AccountKeeper, app.BankKeeper,
Expand Down
9 changes: 4 additions & 5 deletions client/docs/statik/statik.go

Large diffs are not rendered by default.

21 changes: 21 additions & 0 deletions client/docs/swagger-ui/swagger.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1392,6 +1392,7 @@ paths:
url: 'https://github.com/tendermint/farming/tree/main/docs/How-To/cli#plan'
'/cosmos/farming/v1beta1/rewards/{farmer}':
get:
summary: Rewards returns rewards for a farmer
description: Returns all rewards coins that corresponds to the farmer
operationId: Rewards
responses:
Expand All @@ -1417,6 +1418,9 @@ paths:
method
signatures required by gogoproto.
description: >-
QueryRewardsResponse is the response type for the Query/Rewards
RPC method.
'400':
description: Bad Request
schema: {}
Expand Down Expand Up @@ -1631,6 +1635,7 @@ paths:
https://github.com/tendermint/farming/tree/main/docs/How-To/cli#rewards
'/cosmos/farming/v1beta1/stakings/{farmer}':
get:
summary: Stakings returns all stakings by a farmer.
description: >-
Returns all stakings (staked and queued coins) that corresponds to the
farmer
Expand Down Expand Up @@ -1675,6 +1680,9 @@ paths:
method
signatures required by gogoproto.
description: >-
QueryStakingsResponse is the response type for the Query/Stakings
RPC method.
'400':
description: Bad Request
schema: {}
Expand Down Expand Up @@ -1889,6 +1897,7 @@ paths:
https://github.com/tendermint/farming/tree/main/docs/How-To/cli#stakings
'/cosmos/farming/v1beta1/total_stakings/{staking_coin_denom}':
get:
summary: TotalStakings returns total staking amount for a staking coin denom
description: Returns total stakings that corresponds to the staking_coin_denom
operationId: TotalStakings
responses:
Expand All @@ -1899,6 +1908,9 @@ paths:
properties:
amount:
type: string
description: >-
QueryTotalStakingsResponse is the response type for the
Query/TotalStakings RPC method.
'400':
description: Bad Request
schema: {}
Expand Down Expand Up @@ -2664,6 +2676,9 @@ definitions:
NOTE: The amount field is an Int which implements the custom method
signatures required by gogoproto.
description: >-
QueryRewardsResponse is the response type for the Query/Rewards RPC
method.
cosmos.farming.v1beta1.QueryStakingsResponse:
type: object
properties:
Expand Down Expand Up @@ -2695,11 +2710,17 @@ definitions:
NOTE: The amount field is an Int which implements the custom method
signatures required by gogoproto.
description: >-
QueryStakingsResponse is the response type for the Query/Stakings RPC
method.
cosmos.farming.v1beta1.QueryTotalStakingsResponse:
type: object
properties:
amount:
type: string
description: >-
QueryTotalStakingsResponse is the response type for the
Query/TotalStakings RPC method.
google.protobuf.Any:
type: object
properties:
Expand Down
6 changes: 3 additions & 3 deletions docs/Tutorials/demo/budget_with_farming.md
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ We use the following values of the fields.
{
"title": "Public Farming Plan",
"description": "Are you ready to farm?",
"add_request_proposals": [
"add_plan_requests": [
{
"name": "First Public Ratio Plan",
"farming_pool_address": "cosmos1228ryjucdpdv3t87rxle0ew76a56ulvnfst0hq0sscd3nafgjpqqkcxcky",
Expand Down Expand Up @@ -399,7 +399,7 @@ Add second public ratio plan proposal
{
"title": "Update Public Farming Plan",
"description": "Are you ready to farm?",
"update_request_proposals": [
"modify_plan_requests": [
{
"plan_id": 1,
"name": "First Public Ratio Plan",
Expand All @@ -416,7 +416,7 @@ Add second public ratio plan proposal
"epoch_ratio": "0.500000000000000000"
}
],
"add_request_proposals": [
"add_plan_requests": [
{
"name": "Second Public Ratio Plan",
"farming_pool_address": "cosmos1228ryjucdpdv3t87rxle0ew76a56ulvnfst0hq0sscd3nafgjpqqkcxcky",
Expand Down
Loading

0 comments on commit dea1446

Please sign in to comment.