aseba-community / thymio-vpl2

Next generation VPL for Thymio using Qt Quick from Qt 5.x
GNU Lesser General Public License v3.0
2 stars 5 forks source link

Do not allow inconsistent conditions in button and proximity blocks #17

Closed stephanemagnenat closed 7 years ago

stephanemagnenat commented 7 years ago

Currently (and in VPL1), button and proximity blocks can be set in a mode where there is no condition. The corresponding behaviour in VPL1 is to fire at regular interval, which has no justification and can be seen as a undesired side effect of an unspecified behaviour. It is reported and discussed as such in aseba-community/aseba#446. To maintain compatibility with existing educational material, this behaviour is kept in VPL1.

However, it should not be permitted in VPL2. A solution is to create the block with a value set, and do not allow to validate it if no value is set, while showing an error message in the block editor.

stephanemagnenat commented 7 years ago

A solution is to prevent the "ok" button in the block editor if the configuration is invalid.