andelf / tronpy

TRON Python Client Library.
MIT License
204 stars 96 forks source link

Seperated `trigger_constant_contract` from `trigger_const_smart_contract_function` method #81

Closed Ephraim-Akolo closed 1 year ago

Ephraim-Akolo commented 1 year ago

needed the full dict returned by "wallet/triggerconstantcontract"

MrNaif2018 commented 1 year ago

Hi! Why do we need another method if it just returns a fixed path of a different one? Just call the original method and access needed data at path

Ephraim-Akolo commented 1 year ago

The original method filters out some important parameters such as energy_used and energy_penalty and only returns the constant_result parameter.

Ephraim-Akolo commented 1 year ago

But it appears the original method returning the constant_result is used, so i had to create another function to first return the complete data then the original function to parse out only the constant_result so that there is no breakage in the code.

MrNaif2018 commented 1 year ago

Ah sorry, I've misread the diff. Thanks for the explanation Hint: you can rebase your branch to avoid all those commits stacked together when you submit changes

Ephraim-Akolo commented 1 year ago

okay, thank you.