Conversation
|
Thanks, @21Chani! I really appreciate your awesome PR. Would you mind adding a test file for return types, you could find some reference in |
Absolutely sir, will do it soon as I get back from gym |
Sorry for the late, wasn't that simple, just added a new one to make sure type is safe now. Also with that realized that args also needed the same extractor as return, just added. About the proposal for testing type, I had to do in this new way: Let me know what you think |
|
@21Chani My wrong, I should send this file for you as reference |
@SamuelQZQ I didn't forget it, already started doing some tests for view function, but also encountered some challenges, busy week, moving to a new place and still have work to do, probably until sunday I can bring to you some updates 😃 |
|
@SamuelQZQ I am messing with types here, and just realized the entropy is getting really huge, I'm thinking to start separated pr's for make it easy, one for slight type cleanups, another for converting structs on args and other for returning, I realized they have some slight changes, what you think? |
|
hey @21Chani , I merged you recent pr, but finally found that it cannot pass the |
|
@21Chani I have merged the other pr, please resolve conflict here |
Awesome, I will fix this branch 🫡 |

This PR will
Add a better handling for primitives conversion with object mapping
Before:
Now
This will ensure reusability and simplicity to the code, before 3 files for convertor was creating the same huge type 3 times for validating simple types
With this approach we can now just define a Map object with the respective type to a string or value:
This way we can avoid the the huge ternary verifications.
Add a convertor for struct objects
Using the fungible asset as example because I had to struggle a bit to support it with raw aptos package, aiming to provide full support for this in future with surf package.