Project

General

Profile

Actions

Bug #8142

closed

Technique editor no more usable if mismatched/unclosed ${} $() in input

Added by Nicolas CHARLES over 8 years ago. Updated over 2 years ago.

Status:
Rejected
Priority:
1 (highest)
Assignee:
-
Category:
Web - Technique editor
Target version:
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)


Related issues 1 (0 open1 closed)

Related to Rudder - Bug #10268: technique editor return error 500 and /var/rudder/ncf/50_techniques/ emptyReleasedFrançois ARMANDActions
Actions

Also available in: Atom PDF