-
Notifications
You must be signed in to change notification settings - Fork 207
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
MOTOR-1095 Make Rust Compiler available for Cryptography build #194
Conversation
.evergreen/run-tox.sh
Outdated
@@ -39,7 +39,7 @@ if [ "${INSTALL_TOX}" = "true" ]; then | |||
source motorenv/Scripts/activate | |||
fi | |||
set -o xtrace | |||
pip install tox>=3.18 | |||
pip install "tox>=3.18,<4" |
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.
Why make this change?
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.
[2023/02/14 17:07:14.554] tornado6-py38: failed with env name tornado6-py38 conflicting with base python c:\python\Python38\python.exe
[2023/02/14 17:07:14.561] tornado6-py38: FAIL code 1 (0.02 seconds)
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.
Ah, does tox 4.0+ not support Python 3.8?
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.
Let me try removing it again, tox 4 came out in December, we most likely would have seen this before now.
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.
Ah, it appears to be a case sensitivity issue on Windows: Python3.8
~= python 3.8
in our basepython
config.
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 believe this was caused by tox-dev/tox#2824, which was released on 5 Jan and first started affecting our waterfall on 11 Jan.
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.
Okay, separating the py37
and synchro
envs allows it to work.
# Installation of cryptography requires a rust compiler on some machines | ||
curl https://sh.rustup.rs -sSf | sh -s -- -y --no-modify-path | ||
export PATH="$HOME/.cargo/bin:$PATH" | ||
rustup toolchain install nightly -c rustc |
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.
Can we use the existing rust toolchain like we do in PyMongo instead of installing it? See https://github.com/mongodb/mongo-python-driver/blob/a4c90ae157ffcb1d4a073ceeb9177400126ad871/.evergreen/config.yml#L77-L78
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.
There was no /home/admin
, nor /home/ubuntu/.cargo
on the host, so I followed what is done in bson-rust
.
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.
Okay then SGTM.
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.
LGTM, could you open a ticket for this new synchro failure:
[2023/02/15 03:25:48.583] ERROR: Failure: AttributeError (module 'test.test_typing' has no attribute '/data/mci/fe8df805654ae951594d8b1dfb2f6ea9/src/.tox/synchro37/tmp/mongo-python-driver/test/mypy_fails/insert_many_dict.py')
[2023/02/15 03:25:48.583] ----------------------------------------------------------------------
[2023/02/15 03:25:48.583] Traceback (most recent call last):
[2023/02/15 03:25:48.583] File "/data/mci/fe8df805654ae951594d8b1dfb2f6ea9/src/.tox/synchro37/lib/python3.7/site-packages/nose/failure.py", line 39, in runTest
[2023/02/15 03:25:48.583] raise self.exc_val.with_traceback(self.tb)
[2023/02/15 03:25:48.583] File "/data/mci/fe8df805654ae951594d8b1dfb2f6ea9/src/.tox/synchro37/lib/python3.7/site-packages/nose/loader.py", line 255, in generate
[2023/02/15 03:25:48.583] test_func = getattr(m, test_func)
[2023/02/15 03:25:48.583] AttributeError: module 'test.test_typing' has no attribute '/data/mci/fe8df805654ae951594d8b1dfb2f6ea9/src/.tox/synchro37/tmp/mongo-python-driver/test/mypy_fails/insert_many_dict.py'
No description provided.