Closed dvanhove89 closed 2 years ago
This is due to the fact that REStake uses CosmWASM to get the account details.
Under the hood, CosmWASM uses StargateClient
which calls the following method:
https://github.com/cosmos/cosmjs/blob/1e11948c076aa756300691a5c82f897cd6a351a2/packages/stargate/src/stargateclient.ts#L213
As you can see, that method uses the accountFromAny
method which is able to deserialize only basic Cosmos accounts:
https://github.com/cosmos/cosmjs/blob/1e11948c076aa756300691a5c82f897cd6a351a2/packages/stargate/src/accounts.ts#L44
Desmos has its own custom account implementation: the Desmos Profile. This is not supported by CosmWASM by default, hence why it's returning that error. I am personally taking care of this with cosmos/cosmjs#1099 to make it possible to pass a custom account deserializer function to StargateClient
. Once that's done, I will take care of updating REStake code to support Desmos accounts as well.
Thanks so much for all your work on this @RiccardoM - I have to admit I'm only just keeping on top of my todo list at the moment so really appreciate you running with this
Restake is able to pick up the list of supported validators and my own delegation, however when attempting any action (delegate, manual compound, claim, enable restake), the following error is thrown:
Failed to broadcast: Unsupported type: '/desmos.profiles.v1beta1.Profile'