diff options
-rw-r--r-- | grc/core/params/dtypes.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/grc/core/params/dtypes.py b/grc/core/params/dtypes.py index 093ca67dc9..94a1a8d671 100644 --- a/grc/core/params/dtypes.py +++ b/grc/core/params/dtypes.py @@ -115,3 +115,10 @@ def validate_vector(param): if not all(isinstance(item, valid_types) for item in param.get_evaluated()): raise ValidateError('Expression {!r} is invalid for type {!r}.'.format( param.get_evaluated(), param.dtype)) + +@validates('gui_hint') +def validate_gui_hint(param): + try: + param.parse_gui_hint(param.value) + except Exception as e: + raise ValidateError(str(e))
\ No newline at end of file |