-
Notifications
You must be signed in to change notification settings - Fork 13.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sanity check Python on OSX for LLDB tests #33084
Conversation
r? @brson (rust_highfive has picked a reviewer for you, use r? to override) |
Note that tests still won't pass on the most recent OSX version due to what I believe is #33062. |
need to uninstall it entirely (or move it out of 'PATH') to get lldb tests | ||
working. | ||
|
||
", python.display()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this mean one cannot even build Rust when another Python version is in PATH?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I unfortunately didn't get that far in testing. If I had Homebrew Python installed and /usr/local/bin/python
in my PATH then I'd still get weird errors about a missing "six" module, but once /usr/local/bin
was removed from PATH that error went away.
Python would successfully report an import of the lldb
module (or at least the interpreter would exit cleanly) but would print some other errors during the ./configure
step.
I can try to get a clearer picture of what's going on soon as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Couldn't we just adapt compiletest to always use /usr/bin/python
for running the LLDB scripts on OSX?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, so to be clear scary errors are printed out if /usr/local/bin
is in PATH
even if /usr/bin/python
is used:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/Applications/Xcode.app/Contents/SharedFrameworks/LLDB.framework/Resources/Python/lldb/__init__.py", line 98, in <module>
import six
ImportError: No module named six
That being said the lldb_batchmode.py
script seems to run just fine and continue despite this error.
Unfortunately I still can't get tests passing due to #33062, but it seems like yes, we should just tell compiletest to use /usr/bin/python unconditionally.
Right now on the most recent version of LLDB installed on OSX we'll segfault on all the LLDB tests if this isn't called (unfortunately). Hopefully we've updated LLDB on the bots to actually get this working everywhere! Closes rust-lang#32994
9b31be3
to
5195935
Compare
Ok, I've modified to let |
CFG_LLDB_PYTHON=/usr/bin/python | ||
;; | ||
*) | ||
CFG_LLDB_PYTHOn=$CFG_PYTHON |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
CFG_LLDB_PYTHOn
<- the lowercase 'n' is probably a typo.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indeed!
Force usage of /usr/bin/python whenever we run LLDB tests on OSX because it looks like no other Python will work.
5195935
to
cbe6292
Compare
Looks good. Thanks Alex! |
@bors r+ |
📌 Commit cbe6292 has been approved by |
⌛ Testing commit cbe6292 with merge 4c34d4e... |
💔 Test failed - auto-win-msvc-32-opt |
These errors don't seem related... |
@bors retry |
💔 Test failed - auto-win-gnu-32-nopt-t |
@bors: retry On Thu, Apr 21, 2016 at 10:58 AM, bors [email protected] wrote:
|
⌛ Testing commit cbe6292 with merge 680327d... |
💔 Test failed - auto-win-msvc-64-opt-mir |
@bors: retry On Fri, Apr 22, 2016 at 2:44 AM, bors [email protected] wrote:
|
…ichaelwoerister Sanity check Python on OSX for LLDB tests Two primary changes: * Don't get past the configure stage if `python` isn't coming from `/usr/bin` * Call `debugger.Terminate()` to prevent segfaults on newer versions of LLDB. Closes rust-lang#32994
…ster Sanity check Python on OSX for LLDB tests Two primary changes: * Don't get past the configure stage if `python` isn't coming from `/usr/bin` * Call `debugger.Terminate()` to prevent segfaults on newer versions of LLDB. Closes #32994
Two primary changes:
python
isn't coming from/usr/bin
debugger.Terminate()
to prevent segfaults on newer versions of LLDB.Closes #32994