Actions
Bug #16838
closedTechnique with non ascii characters breaks migration from 5.0 to 6.0
Status:
Released
Priority:
N/A
Assignee:
Category:
Web - Technique editor
Target version:
Pull Request:
Severity:
UX impact:
User visibility:
Effort required:
Priority:
0
Name check:
To do
Fix check:
Checked
Regression:
Description
The error manifests itself by:
- no technique anymore in the technique editor,
- error in /var/log/rudder/webapp/....stderr.log
:
[2020-02-28 14:37:57+0100] ERROR bootchecks - An error occured while updating ncf techniques: Failure getting techniques from ncf api: code 500: { "error": [ { "details": "Cause: 'ascii' codec can't decode byte 0xc3 in position 6883: ordinal not in range(128)\nTraceback (most recent call last):\n File \"/usr/share/ncf/api/ncf_api_flask_app/views.py\", line 118, in get_techniques\n techniques = ncf.get_all_techniques_metadata(True,migration)\n File \"/usr/share/ncf/tools/ncf.py\", line 443, in get_all_techniques_metadata\n method_calls = parse_technique_methods(file, methods)\n File \"/usr/share/ncf/tools/ncf.py\", line 322, in parse_technique_methods\n out = check_output([CFENGINE_PATH, \"-pjson\", \"-f\", technique_file], env=env)\n File \"/usr/share/ncf/tools/ncf.py\", line 80, in check_output\n output, error = process.communicate()\n File \"/usr/lib/python3.5/subprocess.py\", line 801, in communicate\n stdout, stderr = self._communicate(input, endtime, timeout)\n File \"/usr/lib/python3.5/subprocess.py\", line 1485, in _communicate\n self.stdout.encoding)\n File \"/usr/lib/python3.5/subprocess.py\", line 705, in _translate_newlines\n data = data.decode(encoding)\nUnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 6883: ordinal not in range(128)\n", "message": "Unknown internal error during techniques fetching" } ] }
Workaround:
- edit /usr/share/ncf/tools/ncf.py
line 79 and 80 with the patch in pull request,
- service apache2 restart
- touch /opt/rudder/etc/force_ncf_technique_update
- service rudder-jetty restart
Updated by François ARMAND over 4 years ago
- Assignee changed from François ARMAND to Alexis Mousset
- Pull Request set to https://github.com/Normation/ncf/pull/1148
Updated by François ARMAND over 4 years ago
- Status changed from In progress to Pending release
Applied in changeset commit:f2bf1daf675226394306c39e6da8e8931ab451d6.
Updated by Vincent MEMBRÉ over 4 years ago
- Fix check changed from To do to Checked
Updated by Vincent MEMBRÉ over 4 years ago
- Subject changed from Technique with non ascii characters break migration from 5.0 to 6.0 to Technique with non ascii characters breaks migration from 5.0 to 6.0
Updated by Vincent MEMBRÉ over 4 years ago
- Status changed from Pending release to Released
This bug has been fixed in Rudder 6.0.4 which was released today.
Updated by Alexis Mousset over 2 years ago
- Project changed from 41 to Rudder
- Category changed from Technique editor - API to Web - Technique editor
Actions