Patch by Axel Naumann!
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
Comment Actions
What problem does this solve exactly? I thought this switch is a hack that works around places where we didn't correctly encode/decode bytestreams and it seems we should better fix the root cause.
Comment Actions
Apologies for the slow response.
This is about a test file using a unicode (or non-ASCII?) character, for instance ächo.C. If you put this into a lit test suite and run lit without this patch it will complain:
Exception in thread Thread-3: Traceback (most recent call last): File "/usr/lib/python2.7/threading.py", line 801, in __bootstrap_inner self.run() File "/usr/lib/python2.7/threading.py", line 754, in run self.__target(*self.__args, **self.__kwargs) File "/usr/lib/python2.7/multiprocessing/pool.py", line 405, in _handle_results cache[job]._set(i, obj) File "/usr/lib/python2.7/multiprocessing/pool.py", line 572, in _set self._callback(self._value) File "/mnt/a/build/cling/cling-all-in-one/cling-all-in-one/src/utils/lit/lit/run.py", line 443, in consume_test_result self.display.update(test_with_result) File "/mnt/a/build/cling/cling-all-in-one/cling-all-in-one/src/utils/lit/lit/main.py", line 50, in update test.getFullName()) File "/mnt/a/build/cling/cling-all-in-one/cling-all-in-one/src/utils/lit/lit/ProgressBar.py", line 271, in update self.term.CLEAR_EOL + message) UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 20: ordinal not in range(128)
This patch prevents that exception. (Which btw brings lit into a terrible state...)