-
Notifications
You must be signed in to change notification settings - Fork 53
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
PDX-19: Add UnloadFromGarages Action #2197
Conversation
This PR has Quantification details
Why proper sizing of changes matters
Optimal pull request sizes drive a better predictable PR flow as they strike a
What can I do to optimize my changes
How to interpret the change counts in git diff output
Was this comment helpful? 👍 :ok_hand: :thumbsdown: (Email) |
Address recipientAvatarAddress, | ||
IEnumerable<(Address balanceAddress, FungibleAssetValue value)>? | ||
fungibleAssetValues, | ||
IEnumerable<(HashDigest<SHA256> fungibleId, int count)>? fungibleIdAndCounts, | ||
string? memo)> unloadData) |
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.
It is too sad to duplicate codes for type because of csharplang's limitation. 😢
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.
type Foo = (...)
😢
var fungibleAssetValues = | ||
GarageUtils.MergeAndSort( | ||
(value[1] as List)?.Select(raw => | ||
{ | ||
var fungibleAssetValue = (List)raw; | ||
return (fungibleAssetValue[0].ToAddress(), | ||
fungibleAssetValue[1].ToFungibleAssetValue()); | ||
})); |
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.
It will be treated as null
instead of throwing an error, even if invalid items like Dictionary
became.
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.
Also, we should consider unload_from_garages
as good naming 🤔 Should it be bulk_unload_from_my_garages
? 🤔 @boscohyun Please leave your opinion 🙏🏻
Thanks for mentioning me.
|
@boscohyun @moreal Thank you for your opinion. I think |
Add
UnloadFromGarages
action with data structure and serialize/deserialize code.Implementation of execution will be added following PR.