Actions
Bug #8142
closedTechnique editor no more usable if mismatched/unclosed ${} $() in input
Pull Request:
Severity:
Minor - inconvenience | misleading | easy workaround
UX impact:
User visibility:
Operational - other Techniques | Technique editor | Rudder settings
Effort required:
Priority:
0
Name check:
Fix check:
Regression:
Description
If I make a typo, and use a variable like ${) (curly bracket + parenthesis), i get the following error message, which is super unhelpful
An Error occured! Could not write technique 'broken' from path /var/rudder/configuration-repository/ncf, cause is: Error while running post-hook command [u'/var/rudder/configuration-repository/ncf/ncf-hooks.d/post.write_technique.rudderify.sh', u'/var/rudder/configuration-repository/ncf', u'broken'] Details: INFO: Alternative source path added: /var/rudder/configuration-repository/ncf Traceback (most recent call last): File "/usr/share/ncf/tools/ncf_rudder.py", line 372, in write_one_technique_for_rudder(sys.argv[2],sys.argv[3]) File "/usr/share/ncf/tools/ncf_rudder.py", line 43, in write_one_technique_for_rudder techniques = ncf.get_all_techniques_metadata(alt_path='/var/rudder/configuration-repository/ncf')['data'] File "/usr/share/ncf/tools/ncf.py", line 499, in get_all_techniques_metadata method_calls = parse_technique_methods(file) File "/usr/share/ncf/tools/ncf.py", line 260, in parse_technique_methods promises = json.loads(out) File "/usr/lib64/python2.6/json/__init__.py", line 307, in loads return _default_decoder.decode(s) File "/usr/lib64/python2.6/json/decoder.py", line 319, in decode obj, end = self.raw_decode(s, idx=_w(s, 0).end()) File "/usr/lib64/python2.6/json/decoder.py", line 338, in raw_decode raise ValueError("No JSON object could be decoded") ValueError: No JSON object could be decoded
We should predetect it when we hit save (or while typing it)
Actions