mirror of
https://github.com/wassname/ray.git
synced 2026-08-19 12:30:27 +08:00
Add __commit__ field to ray package in wheels (#7305)
This commit is contained in:
@@ -79,6 +79,13 @@ for ((i=0; i<${#PY_VERSIONS[@]}; ++i)); do
|
||||
$PIP_CMD install -q numpy==$NUMPY_VERSION cython==0.29.0
|
||||
# Install wheel to avoid the error "invalid command 'bdist_wheel'".
|
||||
$PIP_CMD install -q wheel
|
||||
# Set the commit SHA in __init__.py.
|
||||
if [ -n "$TRAVIS_COMMIT" ]; then
|
||||
sed -i.bak "s/{{RAY_COMMIT_SHA}}/$TRAVIS_COMMIT/g" ray/__init__.py && rm ray/__init__.py.bak
|
||||
else
|
||||
echo "TRAVIS_COMMIT variable not set - required to populated ray.__commit__."
|
||||
exit 1
|
||||
fi
|
||||
# Add the correct Python to the path and build the wheel. This is only
|
||||
# needed so that the installation finds the cython executable.
|
||||
PATH=$MACPYTHON_PY_PREFIX/$PY_MM/bin:$PATH $PYTHON_EXE setup.py bdist_wheel
|
||||
|
||||
Reference in New Issue
Block a user