-
Notifications
You must be signed in to change notification settings - Fork 6.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
[Testing] Do not run any non-RLlib/core tests if only RLLib affected (except wheels). #7892
[Testing] Do not run any non-RLlib/core tests if only RLLib affected (except wheels). #7892
Conversation
…r generating the 2 wheels (OSX and Linux).
Can one of the admins verify this patch? |
…_test_all_of_ray_core_for_rllib_only_changes � Conflicts: � rllib/utils/__init__.py
Test FAILed. |
Test PASSed. |
Test FAILed. |
Test PASSed. |
…f_ray_core_for_rllib_only_changes
Test FAILed. |
Test PASSed. |
Test PASSed. |
…_test_all_of_ray_core_for_rllib_only_changes
.travis.yml
Outdated
@@ -56,16 +56,17 @@ matrix: | |||
- RAY_GCS_SERVICE_ENABLED=false | |||
install: | |||
- eval `python $TRAVIS_BUILD_DIR/ci/travis/determine_tests_to_run.py` | |||
- if [ $RAY_CI_SERVE_AFFECTED != "1" ] && [ $RAY_CI_TUNE_AFFECTED != "1" ] && [ $RAY_CI_PYTHON_AFFECTED != "1" ] && [ $RAY_CI_STREAMING_CPP_AFFECTED != "1" ] && [ $RAY_CI_JAVA_AFFECTED != "1" ]; then exit; fi |
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.
this condition doesn't work. It should run when RAY_CI_JAVA_AFFECTED
is 1
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.
and it does, no?
It will NOT(!) exit the install, if RAY_CI_JAVA_AFFECTED=1
Then, in the script section: if [ $RAY_CI_JAVA_AFFECTED == "1" ]; then ./java/test.sh; fi
.travis.yml
Outdated
@@ -76,13 +77,15 @@ matrix: | |||
- RAY_GCS_SERVICE_ENABLED=false | |||
install: | |||
- eval `python $TRAVIS_BUILD_DIR/ci/travis/determine_tests_to_run.py` | |||
- if [ $RAY_CI_PYTHON_AFFECTED != "1" ]; then exit; fi |
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.
for gcs_service test, we actually want to run it on every python changes
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.
Oh, so you mean, it should run even if only RAY_CI_RLLIB_AFFECTED=1?
Test PASSed. |
Let me create another var, which is 1 iff only RLLIB is affected (and nothing else). |
…ray-core stuff (except wheels) if only RLlib changed.
@mehrdadn can you help take a look at this PR as well? mostly verify the logic. |
Test PASSed. |
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.
The logic looks fine as far as I can tell @simon-mo. I'm a bit concerned it's becoming more brittle and getting increasingly difficult to reason about the testing logic. For example, the conditions for defining RAY_CI_ONLY_RLLIB_AFFECTED
form an almost-exhaustive list of exclusions, which will likely go out of sync later. Or for example, I think it'll become confusing later what "only" means in RAY_CI_ONLY_RLLIB_AFFECTED
, since wheels are also deemed affected here. I think right now it's clear that it means "only" with respect to the phase of compiling source code, but that will likely not stay so simple down the road.
We can (probably should) merge this for now to get builds through, but we should seriously consider a more scalable and robust solution later. I think the solution here would be using Bazel for everything, so that it can figure out dependencies for tests on its own (and we can insert our own scripts into the process to help it wherever needed). Probably something I can look into once I'm done with the higher priority stuff on the Windows side.
Thanks @mehrdadn! Sounds good, moving the dependency analysis to bazel make sense to me. Probably through some bazel query tool we can determine which sets of tests are necessary. |
Trying a re-test with only Rllib changes. |
I agree, it's probably better to take what-needs-to-be-tested-logic out of travis.yaml and move it into BAZEL. |
Test FAILed. |
…_test_all_of_ray_core_for_rllib_only_changes
Hey @simon-mo Could you merge? Tests are all ok, except for the known broken ones (tmp file creation currently broken: |
Yes please merge :) I'm doing surgery on CI so it'll make one of our lives very difficult if this isn't merged soon! |
Test FAILed. |
…(except wheels). (ray-project#7892) * Do not run any non-RLlib/core tests if only RLLib affected, except for generating the 2 wheels (OSX and Linux). * Test noop RLlib change. * Test noop RLlib change. * Fix broken RLlib tests in master. * Split BAZEL learning tests into cartpole and pendulum (reached the 60min barrier). * Fix error_outputs option in BAZEL for RLlib regression tests. * Fix. * Test. * WIP. * Add env flag RAY_CI_ONLY_RLLIB_AFFECTED to refrain from testing most ray-core stuff (except wheels) if only RLlib changed. * Test RLlib-only change.
Non-wheel & non-RLlib travis test jobs will not(!) be run if only RLLIB_AFFECTED.
Reasoning: If only RLlib files have changed, only RLlib tests should be re-run (and the wheels should be rebuilt/updated).
We already have in place: If only non-RLlib files have changed, only the RLlib learning tests are run to assure all our RL-algos are still learning.
This will significantly reduce the stress currently put on our travis resources.
Related issue number
Checks
scripts/format.sh
to lint the changes in this PR.