Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enforce superclasses of base rounds to always define required attributes #2246

Open
jmoreira-valory opened this issue Jul 10, 2024 · 1 comment
Labels
core-packages Related to core packages enhancement New feature or request

Comments

@jmoreira-valory
Copy link
Collaborator

Is your feature request related to a problem? Please describe.
Some base rounds require a number of base attributes to be defined by the superclasses. For example, none_type on CollectSameUntilThresholdRound.

If the superclass fails to initialize these attributes, the business logic will proceed without a warning. However, if during the execution variable is required to launch an event, it will crash the application when accessing that attribute.

Describe the solution you'd like
In summary, the application should throw a warning or exception when these required attributes are not initialized. This applies to several other base round classes.

Describe alternatives you've considered

Additional context

@jmoreira-valory jmoreira-valory changed the title Enforce base rounds to always define required attributes Enforce superclases of base rounds to always define required attributes Jul 10, 2024
@jmoreira-valory jmoreira-valory changed the title Enforce superclases of base rounds to always define required attributes Enforce superclasses of base rounds to always define required attributes Jul 10, 2024
@Adamantios Adamantios added enhancement New feature or request core-packages Related to core packages labels Jul 10, 2024
@Adamantios
Copy link
Collaborator

The solution in #2276 does not align with the intended one for this issue.
The agent crashes after it has started running, and only if the problematic round is entered.
Instead, we wanted to achieve a solution in which the check happens before the FSM cycle starts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core-packages Related to core packages enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants