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

Transaction movement type mapping is incorrect #497

Closed
ghost opened this issue Aug 9, 2022 · 1 comment
Closed

Transaction movement type mapping is incorrect #497

ghost opened this issue Aug 9, 2022 · 1 comment
Labels
bug Something isn't working serialization Involve message serialization

Comments

@ghost
Copy link

ghost commented Aug 9, 2022

TransactionMovement.from_map is inconsistent with the movement deserialization using the chain reader

"Token" ->
%{res | type: {:token, Map.get(movement, :token_address), Map.get(movement, :token_id)}}

def deserialize(data) do
{address, <<amount::64, rest::bitstring>>} = Utils.deserialize_address(data)
{type, rest} = Type.deserialize(rest)
{
%__MODULE__{
to: address,
amount: amount,
type: type
},
rest
}
end

This is causing self repair to fail

@ghost ghost added bug Something isn't working serialization Involve message serialization labels Aug 9, 2022
@ghost ghost self-assigned this Aug 9, 2022
@ghost ghost mentioned this issue Aug 9, 2022
@ghost
Copy link
Author

ghost commented Aug 11, 2022

Closed by #494

@ghost ghost closed this as completed Aug 11, 2022
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working serialization Involve message serialization
Projects
None yet
Development

No branches or pull requests

0 participants