uf-mil / ros_alarms

Alarm system implementation in ROS

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Input Validation

DSsoto opened this issue · comments

It would be nice if the alarm server rejected certain types of alarm names so that simple mistakes are easier to catch. For example, the empty string, possibly strings with whitespace or non-standard characters, etc.

You'd get a warning when creating the alarm, wouldn't that be good to catch any errors like that

A single line at the start of a launch is really easy to miss. Having a bit of structure as to what names are allowed also opens up the possibility for regex searches or operations in the future.

I think whitespace should be legal if the user wants to use it, and python will complain about most non standard characters.
Checking for an empty string would be an easy addition though