Automated rollback of commit ee0856d0d92717dee6bb71788c3e562adb5c998a. Revert #24569.

PiperOrigin-RevId: 227083461
This commit is contained in:
Smit Hinsu 2018-12-27 18:32:31 -08:00 committed by TensorFlower Gardener
parent 770b26ea08
commit add19e0e56

View File

@ -207,12 +207,9 @@ def _get_python_lib(repository_ctx, python_bin):
def _check_python_lib(repository_ctx, python_lib):
"""Checks the python lib path."""
return_codes = []
for entry in python_lib.split(":"):
cmd = 'test -d "%s" -a -x "%s"' % (entry, entry)
result = repository_ctx.execute([_get_bash_bin(repository_ctx), "-c", cmd])
return_codes.append(result.return_code)
if all(return_codes):
cmd = 'test -d "%s" -a -x "%s"' % (python_lib, python_lib)
result = repository_ctx.execute([_get_bash_bin(repository_ctx), "-c", cmd])
if result.return_code == 1:
_fail("Invalid python library path: %s" % python_lib)