[PATCH][Lit] Catch OSError exception when using Popen constructor

Daniel Dunbar daniel at zuster.org
Tue Oct 21 18:19:01 PDT 2014


Ugh I knew there was something I forgot to test, will fix this evening.

On Tuesday, October 21, 2014, Dan Liew <dan at su-root.co.uk> wrote:

> On 22 October 2014 01:59, Daniel Dunbar <daniel at zuster.org <javascript:;>>
> wrote:
> > Thanks, I've published a new lit package as 0.4.0.
>
> Thanks. Looks likes its broken under Python3 though by your recent
> change (r220354)
>
> ```
> Traceback (most recent call last):
>   File "/usr/lib/python3.4/site-packages/lit/run.py", line 166, in
> execute_test
>     result = test.config.test_format.execute(test, self.lit_config)
>   File "/usr/lib/python3.4/site-packages/lit/formats/shtest.py", line
> 12, in execute
>     self.execute_external)
>   File "/usr/lib/python3.4/site-packages/lit/TestRunner.py", line 491,
> in executeShTest
>     res = parseIntegratedTestScript(test, useExternalSh,
> extra_substitutions)
>   File "/usr/lib/python3.4/site-packages/lit/TestRunner.py", line 421,
> in parseIntegratedTestScript
>     parseIntegratedTestScriptCommands(sourcepath):
>   File "/usr/lib/python3.4/site-packages/lit/TestRunner.py", line 347,
> in parseIntegratedTestScriptCommands
>     if not data.endswith('\n'):
> TypeError: endswith first arg must be bytes or a tuple of bytes, not str
> ```
>
> Attached is a patch that seems to fix the error for me.
>
> --
> Dan Liew
> PhD Student - Imperial College London
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20141021/5f1f29a7/attachment.html>


More information about the llvm-commits mailing list