-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
feat: Improve withdraw-all-rewards UX #9781
Merged
mergify
merged 8 commits into
cosmos:master
from
desmos-labs:improve-withdraw-all-rewards-ux
Jul 28, 2021
Merged
Changes from 5 commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
adc8a83
Improved withdraw-all-rewards UX by forcing BroadcastMode to block if…
RiccardoM 5a69de4
Updated command documentation
RiccardoM 3d7f6b8
Updated how to handle withdraw-all-rewards with different broadcast m…
RiccardoM 94cacd2
Merge branch 'master' into improve-withdraw-all-rewards-ux
RiccardoM 3ebce6f
Update x/distribution/client/cli/tx.go
RiccardoM b66e6ed
Merge branch 'master' of github.com:cosmos/cosmos-sdk into improve-wi…
RiccardoM 5a40a2c
Added CHANGELOG entry
RiccardoM ca9e1d5
Merge remote-tracking branch 'desmos/improve-withdraw-all-rewards-ux'…
RiccardoM File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
is it worth erroring here? Instead of a bit sliently changing the user inputted flag, as the user might not notice this line.
This will also force the user to add the
--FlagMaxMessagesPerTx=0
flag when not using broadcast mode block.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.
@AmauryM To be honest, I think that would result in a bad UX. As per this comment, the
block
broadcast mode should be disincentivized, and thesync
andasync
should be used instead. If we require the users to set a flag for the modessync
andasync
, that might make them simply use theblock
mode instead. For this reason, I think that changing the value and warning them with that log is sufficient.Another thing that could be done is simply set the default value of
FlagMaxMessagesPerTx
to be0
, and error in caseasync
orsync
are used and that value is not zero.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.
Cool. I'm putting automerge on, thanks!
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.
@AmauryM I've swapped the behavior by setting the default chunks to
0
and returning an error whenasync
orsync
is used with aFlagMaxMessagesPerTx
greater than 0