Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
99 changes: 51 additions & 48 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,14 @@ matrix:
- JDK='Oracle JDK 8'
- PYTHON=3.5 PYTHONWARNINGS=ignore
install:
- ./.travis/install-dependencies.sh
- ./ci/travis/install-dependencies.sh
- export PATH="$HOME/miniconda/bin:$PATH"
script:
- ./java/test.sh

# Test Bazel build
- rm -rf build
- ./.travis/install-bazel.sh
- ./ci/travis/install-bazel.sh
- bazel build ...

- os: linux
Expand All @@ -47,10 +47,10 @@ matrix:
- sudo apt-get install -qq clang-format-3.8
install: []
script:
- .travis/check-git-clang-format-output.sh
- ./ci/travis/check-git-clang-format-output.sh
# Try generating Sphinx documentation. To do this, we need to install
# Ray first.
- ./.travis/install-dependencies.sh
- ./ci/travis/install-dependencies.sh
- export PATH="$HOME/miniconda/bin:$PATH"
- cd doc
- pip install -q -r requirements-doc.txt
Expand All @@ -59,7 +59,7 @@ matrix:
- cd ..
# Run Python linting, ignore dict vs {} (C408), others are defaults
- flake8 --exclude=python/ray/core/generated/,doc/source/conf.py,python/ray/cloudpickle/ --ignore=C408,E121,E123,E126,E226,E24,E704,W503,W504,W605
- .travis/format.sh --all
- ./ci/travis/format.sh --all
# Make sure that the README is formatted properly.
- cd python
- python setup.py check --restructuredtext --strict --metadata
Expand All @@ -72,7 +72,7 @@ matrix:
- export GOPATH="$HOME/go_dir"
- export PATH="$GOROOT/bin:$GOPATH/bin:$PATH"
- go get github.com/bazelbuild/buildtools/buildifier
- ./.travis/bazel-format.sh
- ./ci/travis/bazel-format.sh

- os: linux
dist: trusty
Expand All @@ -81,10 +81,10 @@ matrix:
- sudo apt-get update -qq
- sudo apt-get install -qq valgrind
install:
- ./.travis/install-dependencies.sh
- ./ci/travis/install-dependencies.sh
- export PATH="$HOME/miniconda/bin:$PATH"
- ./.travis/install-ray.sh
- ./.travis/install-with-cache-libs.sh
- ./ci/travis/install-ray.sh
- ./ci/travis/install-with-cache-libs.sh

script:
- cd build
Expand All @@ -98,33 +98,33 @@ matrix:

# # Python3.5+ only. Otherwise we will get `SyntaxError` regardless of how we set the tester.
- python -c 'import sys;exit(sys.version_info>=(3,5))' || python -m pytest -v --durations=10 python/ray/experimental/test/async_test.py
- python -m pytest -v --durations=10 test/mini_test.py
- python -m pytest -v --durations=10 test/array_test.py
- python -m pytest -v --durations=10 test/multi_node_test_2.py
- python -m pytest -v --durations=10 test/node_manager_test.py
- python -m pytest -v --durations=10 python/ray/tests/test_mini.py
- python -m pytest -v --durations=10 python/ray/tests/test_array.py
- python -m pytest -v --durations=10 python/ray/tests/test_multi_node_2.py
- python -m pytest -v --durations=10 python/ray/tests/test_node_manager.py


# Build Linux wheels.
- os: linux
dist: trusty
env: LINUX_WHEELS=1 PYTHONWARNINGS=ignore
install:
- ./.travis/install-dependencies.sh
- ./ci/travis/install-dependencies.sh
# This command should be kept in sync with ray/python/README-building-wheels.md.
- docker run --rm -w /ray -v `pwd`:/ray -ti quay.io/xhochy/arrow_manylinux1_x86_64_base:latest /ray/python/build-wheel-manylinux1.sh
script:
- ./.travis/test-wheels.sh
- ./ci/travis/test-wheels.sh

# Build MacOS wheels.
- os: osx
osx_image: xcode7
env: MAC_WHEELS=1 PYTHONWARNINGS=ignore
install:
- ./.travis/install-dependencies.sh
- ./ci/travis/install-dependencies.sh
# This command should be kept in sync with ray/python/README-building-wheels.md.
- ./python/build-wheel-macos.sh
script:
- ./.travis/test-wheels.sh
- ./ci/travis/test-wheels.sh

# Test GCS integration
- os: linux
Expand All @@ -136,10 +136,10 @@ matrix:


install:
- ./.travis/install-dependencies.sh
- ./ci/travis/install-dependencies.sh
- export PATH="$HOME/miniconda/bin:$PATH"
- ./.travis/install-ray.sh
- ./.travis/install-cython-examples.sh
- ./ci/travis/install-ray.sh
- ./ci/travis/install-cython-examples.sh

- cd build
- bash ../src/ray/test/run_gcs_tests.sh
Expand All @@ -162,7 +162,7 @@ script:
# class definitions: The main module of tests that are run
# with pytest have the same name as the test file -- and this
# module is only found if the test directory is in the PYTHONPATH.
- export PYTHONPATH="$PYTHONPATH:./test/"
# - export PYTHONPATH="$PYTHONPATH:./ci/"

# ray tune tests
- python python/ray/tune/test/dependency_test.py
Expand All @@ -182,43 +182,46 @@ script:
# Python3.5+ only. Otherwise we will get `SyntaxError` regardless of how we set the tester.
- python -c 'import sys;exit(sys.version_info>=(3,5))' || python -m pytest -v --durations=10 python/ray/experimental/test/async_test.py

- python -m pytest -v --durations=10 python/ray/test/test_global_state.py
- python -m pytest -v --durations=10 python/ray/test/test_queue.py
- python -m pytest -v --durations=10 python/ray/test/test_ray_init.py
- python -m pytest -v --durations=10 test/mini_test.py

- python -m pytest -v --durations=10 test/runtest.py
- python -m pytest -v --durations=10 test/array_test.py
- python -m pytest -v --durations=10 test/actor_test.py
- python -m pytest -v --durations=10 test/autoscaler_test.py
- python -m pytest -v --durations=10 test/tensorflow_test.py
- python -m pytest -v --durations=10 test/failure_test.py
- python -m pytest -v --durations=10 test/microbenchmarks.py
- python -m pytest -v --durations=10 test/stress_tests.py
- python -m pytest -v --durations=10 test/component_failures_test.py
- python -m pytest -v --durations=10 test/multi_node_test.py
- python -m pytest -v --durations=10 test/multi_node_test_2.py
- python -m pytest -v --durations=10 test/recursion_test.py
- python -m pytest -v --durations=10 test/monitor_test.py
- python -m pytest -v --durations=10 test/cython_test.py
- python -m pytest -v --durations=10 test/credis_test.py
- python -m pytest -v --durations=10 test/node_manager_test.py
- python -m pytest -v --durations=10 test/test_signal.py
# ray tests
# TODO(williamma12): We cannot use pytests built-in test discovery because
# it causes a lot of the tests to fail on travis' apple builds even though
# it runs without issue on an apple build locally.
- python -m pytest -v --durations=10 python/ray/tests/test_global_state.py
- python -m pytest -v --durations=10 python/ray/tests/test_queue.py
- python -m pytest -v --durations=10 python/ray/tests/test_ray_init.py
- python -m pytest -v --durations=10 python/ray/tests/test_mini.py

- python -m pytest -v --durations=10 python/ray/tests/test_basic.py
- python -m pytest -v --durations=10 python/ray/tests/test_array.py
- python -m pytest -v --durations=10 python/ray/tests/test_actor.py
- python -m pytest -v --durations=10 python/ray/tests/test_autoscaler.py
- python -m pytest -v --durations=10 python/ray/tests/test_tensorflow.py
- python -m pytest -v --durations=10 python/ray/tests/test_failure.py
- python -m pytest -v --durations=10 python/ray/tests/test_microbenchmarks.py
- python -m pytest -v --durations=10 python/ray/tests/test_stress.py
- python -m pytest -v --durations=10 python/ray/tests/test_component_failures.py
- python -m pytest -v --durations=10 python/ray/tests/test_multi_node.py
- python -m pytest -v --durations=10 python/ray/tests/test_multi_node_2.py
- python -m pytest -v --durations=10 python/ray/tests/test_recursion.py
- python -m pytest -v --durations=10 python/ray/tests/test_monitors.py
- python -m pytest -v --durations=10 python/ray/tests/test_cython.py
- python -m pytest -v --durations=10 python/ray/tests/test_credis.py
- python -m pytest -v --durations=10 python/ray/tests/test_node_manager.py
- python -m pytest -v --durations=10 python/ray/tests/test_signal.py
# TODO(yuhguo): object_manager_test.py requires a lot of CPU/memory, and
# better be put in Jenkins. However, it fails frequently in Jenkins, but
# works well in Travis. We should consider moving it back to Jenkins once
# we figure out the reason.
- python -m pytest -v --durations=10 test/object_manager_test.py
- python -m pytest -v --durations=10 python/ray/tests/test_object_manager.py
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this will run test_object_manager.py twice, right? Maybe we can move the above comment to the test_object_manager.py file, and don't need to make this a separate command. cc @guoyuhong

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I reworded the comment so that I could keep the comment in .travis.yml and delete the line so test_object_manager.py won't be ran twice


# ray temp file tests
- python -m pytest -v --durations=10 test/tempfile_test.py
- python -m pytest -v --durations=10 python/ray/tests/test_tempfile.py

# ray debug tools tests
- python -m pytest -v --durations=10 test/debug_tools_test.py
- python -m pytest -v --durations=10 python/ray/tests/test_debug_tools.py

# modin test files
- python -m pytest -v --durations=10 python/ray/test/test_modin.py

- python -m pytest -v --durations=10 python/ray/tests/test_modin.py
deploy:
- provider: s3
access_key_id: AKIAJ2L7XDUSZVTXI5QA
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
import time

import ray
from ray.test.test_utils import (_wait_for_nodes_to_join, _broadcast_event,
_wait_for_event)
from ray.tests.utils import (_wait_for_nodes_to_join, _broadcast_event,
_wait_for_event)

# This test should be run with 5 nodes, which have 0, 0, 5, 6, and 50 GPUs for
# a total of 61 GPUs. It should be run with a large number of drivers (e.g.,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
import time

import ray
from ray.test.test_utils import (_wait_for_nodes_to_join, _broadcast_event,
_wait_for_event, wait_for_pid_to_exit)
from ray.tests.utils import (_wait_for_nodes_to_join, _broadcast_event,
_wait_for_event, wait_for_pid_to_exit)

# This test should be run with 5 nodes, which have 0, 1, 2, 3, and 4 GPUs for a
# total of 10 GPUs. It should be run with 7 drivers. Drivers 2 through 6 must
Expand Down
File renamed without changes.
File renamed without changes.
4 changes: 2 additions & 2 deletions .travis/bazel-format.sh → ci/travis/bazel-format.sh
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ while [[ $# > 0 ]]; do
shift
done

pushd $ROOT_DIR/..
pushd $ROOT_DIR/../..
BAZEL_FILES="bazel/BUILD bazel/BUILD.plasma bazel/ray.bzl BUILD.bazel WORKSPACE"
buildifier -mode=$RUN_TYPE -diff_command="diff -u" $BAZEL_FILES
buildifier -mode=$RUN_TYPE -diff_command="diff -u" $BAZEL_FILES
popd
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ else
base_commit="$TRAVIS_BRANCH"
echo "Running clang-format against branch $base_commit, with hash $(git rev-parse $base_commit)"
fi
output="$(.travis/git-clang-format --binary clang-format-3.8 --commit $base_commit --diff --exclude '(.*thirdparty/|.*redismodule.h|.*.js)')"
output="$(ci/travis/git-clang-format --binary clang-format-3.8 --commit $base_commit --diff --exclude '(.*thirdparty/|.*redismodule.h|.*.js)')"
if [ "$output" == "no modified files to format" ] || [ "$output" == "clang-format did not modify any files" ] ; then
echo "clang-format passed."
exit 0
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ ROOT_DIR=$(cd "$(dirname "${BASH_SOURCE:-$0}")"; pwd)

echo "PYTHON is $PYTHON"

cython_examples="$ROOT_DIR/../examples/cython"
cython_examples="$ROOT_DIR/../../examples/cython"

if [[ "$PYTHON" == "2.7" ]]; then

Expand Down
File renamed without changes.
6 changes: 3 additions & 3 deletions .travis/install-ray.sh → ci/travis/install-ray.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,21 +9,21 @@ echo "PYTHON is $PYTHON"

if [[ "$PYTHON" == "2.7" ]]; then

pushd "$ROOT_DIR/../python"
pushd "$ROOT_DIR/../../python"
python setup.py install --user
popd

elif [[ "$PYTHON" == "3.5" ]]; then
export PATH="$HOME/miniconda/bin:$PATH"

pushd "$ROOT_DIR/../python"
pushd "$ROOT_DIR/../../python"
python setup.py install --user
popd

elif [[ "$LINT" == "1" ]]; then
export PATH="$HOME/miniconda/bin:$PATH"

pushd "$ROOT_DIR/../python"
pushd "$ROOT_DIR/../../python"
python setup.py install --user
popd

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,15 @@ ROOT_DIR=$(cd "$(dirname "${BASH_SOURCE:-$0}")"; pwd)

# Copy the libs to thirdparty/external_project_libs.
# -n means do not build again.
bash $ROOT_DIR/../thirdparty/scripts/collect_dependent_libs.sh -n
bash $ROOT_DIR/../../thirdparty/scripts/collect_dependent_libs.sh -n

# Import all the libs cached in local to environment variables.
source $ROOT_DIR/../thirdparty/external_project_libs/resource.txt
source $ROOT_DIR/../../thirdparty/external_project_libs/resource.txt

# Clean the arrow building libs and use the cache libs.
pushd $ROOT_DIR/../build/external/arrow/src/arrow_ep
pushd $ROOT_DIR/../../build/external/arrow/src/arrow_ep
echo "Clean Arrow building files."
rm -rf $ROOT_DIR/../build/external/arrow/src/arrow_ep-build/
rm -rf $ROOT_DIR/../../build/external/arrow/src/arrow_ep-build/
popd

# Rebuild ray with libs cache environment variables, which is fast.
Expand Down
File renamed without changes.
File renamed without changes.
10 changes: 5 additions & 5 deletions .travis/test-wheels.sh → ci/travis/test-wheels.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ else
exit 1
fi

TEST_SCRIPT=$ROOT_DIR/../test/microbenchmarks.py
TEST_SCRIPT=$ROOT_DIR/../../python/ray/tests/test_microbenchmarks.py

if [[ "$platform" == "linux" ]]; then
# First test Python 2.7.
Expand All @@ -31,7 +31,7 @@ if [[ "$platform" == "linux" ]]; then
bash miniconda2.sh -b -p $HOME/miniconda2

# Find the right wheel by grepping for the Python version.
PYTHON_WHEEL=$(find $ROOT_DIR/../.whl -type f -maxdepth 1 -print | grep -m1 '27')
PYTHON_WHEEL=$(find $ROOT_DIR/../../.whl -type f -maxdepth 1 -print | grep -m1 '27')

# Install the wheel.
$HOME/miniconda2/bin/pip install $PYTHON_WHEEL
Expand All @@ -46,7 +46,7 @@ if [[ "$platform" == "linux" ]]; then
bash miniconda3.sh -b -p $HOME/miniconda3

# Find the right wheel by grepping for the Python version.
PYTHON_WHEEL=$(find $ROOT_DIR/../.whl -type f -maxdepth 1 -print | grep -m1 '36')
PYTHON_WHEEL=$(find $ROOT_DIR/../../.whl -type f -maxdepth 1 -print | grep -m1 '36')

# Install the wheel.
$HOME/miniconda3/bin/pip install $PYTHON_WHEEL
Expand All @@ -55,7 +55,7 @@ if [[ "$platform" == "linux" ]]; then
$HOME/miniconda3/bin/python $TEST_SCRIPT

# Check that the other wheels are present.
NUMBER_OF_WHEELS=$(ls -1q $ROOT_DIR/../.whl/*.whl | wc -l)
NUMBER_OF_WHEELS=$(ls -1q $ROOT_DIR/../../.whl/*.whl | wc -l)
if [[ "$NUMBER_OF_WHEELS" != "5" ]]; then
echo "Wrong number of wheels found."
ls -l $ROOT_DIR/../.whl/
Expand Down Expand Up @@ -84,7 +84,7 @@ elif [[ "$platform" == "macosx" ]]; then
PIP_CMD="$(dirname $PYTHON_EXE)/pip$PY_MM"

# Find the appropriate wheel by grepping for the Python version.
PYTHON_WHEEL=$(find $ROOT_DIR/../.whl -type f -maxdepth 1 -print | grep -m1 "$PY_WHEEL_VERSION")
PYTHON_WHEEL=$(find $ROOT_DIR/../../.whl -type f -maxdepth 1 -print | grep -m1 "$PY_WHEEL_VERSION")

# Install the wheel.
$PIP_CMD install $PYTHON_WHEEL
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion python/ray/rllib/train.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
import yaml

import ray
from ray.test.cluster_utils import Cluster
from ray.tests.cluster_utils import Cluster
from ray.tune.config_parser import make_parser
from ray.tune.trial import resources_to_json
from ray.tune.tune import _make_scheduler, run_experiments
Expand Down
File renamed without changes.
File renamed without changes.
Loading