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
Not using contract_method_call in contracts. -> I also noticed that our contract_method_call only accepts kwargs. It does not accept args. Maybe this is why it was not used?
Many contract calls have code duplication. e.g., get_multiple_projects_info and get_multiple_projects_minter.
Rationale: enforce should be used in lower levels, not inside behaviours. Also, exception handling in behaviours looks dirty and might mean that we can create methods at lower level modules to avoid that.
Resolution: In many examples of the ElCollectooorr's code, the enforce is used at the response's contents, instead of checking the state of the contract call's response. If we check that the response is successful instead, we do not need to check for the contents.
I wasn't aware of contract_method_call, is there any benefit to using it in comparison to what we have now?
No there is no additional benefit apart from uniformity across repos.
The reason why this merging is done on the round is to avoid sending large payloads. Apart from it being kinda ugly, do you see any other issues?
I see, sending large payloads is not a good idea. One reason to keep all the processing on the behaviour side would be for example to separate the concerns or to enhance readability, i.e., it is easier to read a behaviour and understand the skill. @DavidMinarsch would you have anything to add on this?
This review was performed for commit: e7f5eae
contract_method_call
in contracts. -> I also noticed that ourcontract_method_call
only acceptskwargs
. It does not acceptargs
. Maybe this is why it was not used?get_multiple_projects_info
andget_multiple_projects_minter
.agent-academy-1/packages/valory/skills/fractionalize_deployment_abci/behaviours.py
Line 101 in 3a7412b
agent-academy-1/packages/valory/skills/fractionalize_deployment_abci/behaviours.py
Line 243 in 3a7412b
agent-academy-1/packages/valory/skills/elcollectooorr_abci/behaviours.py
Line 319 in 3a7412b
agent-academy-1/packages/valory/skills/elcollectooorr_abci/behaviours.py
Lines 465 to 469 in 3a7412b
enforce
e.g.,:agent-academy-1/packages/valory/skills/fractionalize_deployment_abci/behaviours.py
Line 125 in 3a7412b
agent-academy-1/packages/valory/skills/fractionalize_deployment_abci/behaviours.py
Line 216 in 3a7412b
enforce
should be used in lower levels, not inside behaviours. Also, exception handling in behaviours looks dirty and might mean that we can create methods at lower level modules to avoid that.Resolution: In many examples of the ElCollectooorr's code, the
enforce
is used at the response's contents, instead of checking the state of the contract call's response. If we check that the response is successful instead, we do not need to check for the contents.agent-academy-1/packages/valory/skills/fractionalize_deployment_abci/rounds.py
Lines 65 to 72 in 3a7412b
agent-academy-1/packages/valory/skills/elcollectooorr_abci/rounds.py
Lines 755 to 772 in 3a7412b
The text was updated successfully, but these errors were encountered: