[PATCH] D43165: [lit] Fix problem in how Python versions open files with different encodings

Stella Stamenova via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Feb 14 10:54:55 PST 2018


stella.stamenova added a comment.

A couple of things:

1. Aaron actually forgot to update the change, the final revision should first try to open as before and then fall back to Latin-1 on a decode exception.
2. This is not a Windows specific failure - it is a python 3 issue, so running the tests with python 3 on any platform fails to open the file when it's a binary file with just 'r'
3. And yes, 'rb' causes failures in difflib later because it expects a string and throws an exception when it is given an array of bytes


Repository:
  rL LLVM

https://reviews.llvm.org/D43165





More information about the llvm-commits mailing list