Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
[build fail] python: can't open '....': [Errno2] No such file or directory #3788
Please provide the following information. The more we know about your system and use case, the more easily and likely we can help.
Description of the problem / feature request / question:
Trying to build tensorflow with opencl support using this repo.
Here's a verbose output:
When I check inside
How can I debug the python command that is run by bazel in this case ?
If possible, provide a minimal example to reproduce the problem:
Have you found anything relevant by searching the web? No
Anything else, information or logs or outputs that would be helpful?
(If they are large, please upload as attachment or provide link).
I Ran into a similar issue compiling tensorflow using a pyenv python version, where I received
It seems there's a clash in the use of pyenv and bazel.
What worked for me was:
There's probably a more elegant way, but worth giving this a try.
Thanks for your suggestion @Taltzipi! I can imagine that this helps.
I don't think this is a sandboxing bug. Usually these kind of issues result from the environment being somehow "special" (e.g. Python is installed via pyenv, from source, relies on LD_LIBRARY_PATH or PATH being set to special values...).
Not saying that this shouldn't work with Bazel, but it means that I also don't have any more clue what the reason is than anyone else on the team ;)
It might help to consider that the error "[Errno 2] No such file or directory" can also (a bit confusingly) mean that the binary relies on shared libraries that were not found, which could be, because Bazel strips certain environment variables when running actions?
I am building tensorflow from scratch for the first time, and I immediately hit this issue. I did not want to restart the whole process over again without my carefully constructed pyenv environment, so I looked for a solution. Since the file
I believe the "problem" is the builders' usage of
Unassigning - sorry, I can't be of help fixing this. It's not really a sandboxing issue (in the sense of: we could change Bazel's sandbox somehow to make this work). I think pyenv might be just fundamentally incompatible with our sandboxing - but that said, I don't know anything about pyenv. I think someone with more experience in Python should look into this.