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

Liquidity Module for Swagger documentation QA (2.2.1) #206

Closed

Conversation

dongsam
Copy link
Contributor

@dongsam dongsam commented Mar 30, 2021

Description

It is PR to get the swagger documentation QA suggestions based on the sources, continues to after #172, #188

The commit of this PR consists of a .proto, swagger file diff to receive reviews and suggestions comments and is not for merge purposes, so please ignore the confilts

In 2.2.1 version, #173 (comment) feedbacks was applied and a description of the structure was added and modified.

Copy link
Contributor

@barriebyron barriebyron left a comment

Choose a reason for hiding this comment

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

@dongsam so awesome to see these files in entirety, thank you so much. I think that we can continue to improve this content by clarifying the intention of each message and pinning down the language that accurately describes each message. I made some assumptions based on the light paper (which I should have started with, I think I'm starting to understand little bit now). I can use help in the many places I wasn't sure

proto/tendermint/liquidity/v1beta1/genesis.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/liquidity.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/liquidity.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/liquidity.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/liquidity.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/tx.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/tx.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/tx.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/tx.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/tx.proto Outdated Show resolved Hide resolved
@dongsam dongsam requested a review from defihyung April 2, 2021 08:13
Copy link
Contributor

@defihyung defihyung left a comment

Choose a reason for hiding this comment

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

@barriebyron Thanks for taking your time to provide this valuable feedback. It is really helpful. I left some comments to give you my opinion and some answers to questions. Check out the links that I provide in the comments and if you still feel lost or curious about anything, feel free to let me know. This concept took me a while to understand as well. I am also learning some of the new concepts that are coming up in the next version.

proto/tendermint/liquidity/v1beta1/genesis.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/liquidity.proto Outdated Show resolved Hide resolved

option go_package = "github.com/tendermint/liquidity/x/liquidity/types";

// Msg defines the liquidity Msg service.
Copy link
Contributor

Choose a reason for hiding this comment

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

Since this liquidity module will be included in Cosmos SDK, we try to follow how they comment service.

References:

proto/tendermint/liquidity/v1beta1/tx.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/tx.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/tx.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/tx.proto Outdated Show resolved Hide resolved
Comment on lines 100 to 102
// Withdraw submit to the batch from the Liquidity pool with the specified `pool_id`, `pool_coin` of the pool
// this requests are stacked in the batch of the liquidity pool, not immediately processed and
// processed in the `endblock` at once with other requests.
Copy link
Contributor

Choose a reason for hiding this comment

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

All requests (deposit, withdraw, swap) are accumulated in what is called batch and they are processed at the end of each block.

In Cosmos SDK, there are BeginBlocker and EndBlocker. They will be triggered at the beginning and at the end of each block respectively. In this liquidity module, we add ExecutePoolBatch logic to execute whatever requests (deposit, withdraw, swap) are accumulated in batch. I hope this makes sense? If you need more explanation, let me know :)

proto/tendermint/liquidity/v1beta1/tx.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/tx.proto Outdated Show resolved Hide resolved
@dongsam
Copy link
Contributor Author

dongsam commented Apr 5, 2021

@barriebyron Thanks for the review and suggestion! Except for a few things we're still discussing, we've applied and committed them all. If the discussions are resolved, we will merge them to the develop branch

@dongsam
Copy link
Contributor Author

dongsam commented Apr 6, 2021

I just open new PR #214 to apply the suggestions using to cherry-pick for minimizing conflicts

I think all discussions are resolved, and If there is no further suggestion, we will close the PR.

@barriebyron
Copy link
Contributor

Oh, I see what you did here with #214
so did you want to close this PR @dongsam

i was not complete in my review, so let me know if you want me to look at anything specific

@dongsam
Copy link
Contributor Author

dongsam commented Apr 7, 2021

Oh, I see what you did here with #214
so did you want to close this PR @dongsam

i was not complete in my review, so let me know if you want me to look at anything specific

Okay, so we're gonna keep this PR going, and if get suggestions, I'll do it like #214
Thanks @barriebyron

@barriebyron barriebyron added the documentation Improvements or additions to documentation label Apr 9, 2021
Copy link
Contributor

@barriebyron barriebyron left a comment

Choose a reason for hiding this comment

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

thanks for your thoughtful comments @defihyung and welcome to Tendermint! See my new questions and suggestions


option go_package = "github.com/tendermint/liquidity/x/liquidity/types";

// Msg defines the liquidity Msg service.
Copy link
Contributor

Choose a reason for hiding this comment

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

Right! okay

Comment on lines 100 to 102
// Withdraw submit to the batch from the Liquidity pool with the specified `pool_id`, `pool_coin` of the pool
// this requests are stacked in the batch of the liquidity pool, not immediately processed and
// processed in the `endblock` at once with other requests.
Copy link
Contributor

Choose a reason for hiding this comment

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

Very good explanation, I think the suggested change still makes sense.

Comment on lines 100 to 102
// Withdraw submit to the batch from the Liquidity pool with the specified `pool_id`, `pool_coin` of the pool
// this requests are stacked in the batch of the liquidity pool, not immediately processed and
// processed in the `endblock` at once with other requests.
Copy link
Contributor

Choose a reason for hiding this comment

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

@defihyung are BeginBlocker and EndBlocker the operations that begin and end a block?
image

per https://github.com/cosmos/cosmos-sdk/blob/master/docs/spec/SPEC-SPEC.md

If I understand correctly, we now have a new operation category for batch. Would it make sense to put the batch operations in a new file XX_batch.md?

proto/tendermint/liquidity/v1beta1/tx.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/tx.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/tx.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/tx.proto Outdated Show resolved Hide resolved
proto/tendermint/liquidity/v1beta1/tx.proto Outdated Show resolved Hide resolved
@dongsam
Copy link
Contributor Author

dongsam commented Apr 14, 2021

I just apply the suggestions from #221,
And open new PR #222 based latest branch for QA continuously

@barriebyron barriebyron changed the title Suggestions for Swagger documentation QA (2.2.1) Liquidity Module for Swagger documentation QA (2.2.1) Apr 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants