You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When converting an EVM address to a Fuel address, it's essential to pad zeros.
To simplify this process we need to add utility methods within the Address class that will automatically handle this zero-padding for us. This enhancement will reduce potential errors for all applications interacting with the EVM address.
The text was updated successfully, but these errors were encountered:
Torres-ssf
changed the title
Utility Method for Zero-Padding EVM Addresses in the Address Class
Implement utility method for zero-padding EVM addresses in the Address class
Sep 15, 2023
So we do have a couple of functions already implemented that do something similar, however not matching this exact developer experience. Our Address.fromEvmAddress currently expects a wrapped and padded address (to match our EvmAddress type) to obtain an Address.
The use case detailed by @Torres-ssf is more appropriate, as an address would be returned from the EVM unwrapped and unpadded, requiring the user to do such to pass it to our function. I'll raise a PR to improve the dev ex of this function.
When converting an EVM address to a Fuel address, it's essential to pad zeros.
To simplify this process we need to add utility methods within the
Address
class that will automatically handle this zero-padding for us. This enhancement will reduce potential errors for all applications interacting with the EVM address.The text was updated successfully, but these errors were encountered: