2018-08-29 00:06:33 -07:00
|
|
|
Release Process
|
|
|
|
===============
|
|
|
|
|
|
|
|
This document describes the process for creating new releases.
|
|
|
|
|
2019-09-26 10:30:37 -07:00
|
|
|
1. **Create a release branch:** Create the branch from the desired commit on master
|
|
|
|
In order to create the branch, locally checkout the commit ID i.e.,
|
|
|
|
``git checkout <hash>``. Then checkout a new branch of the format
|
|
|
|
``releases/<release-version>``. Then push that branch to the ray repo:
|
|
|
|
``git push upstream releases/<release-version>``.
|
2018-08-29 00:06:33 -07:00
|
|
|
|
2019-12-16 15:51:39 -08:00
|
|
|
2. **Update the release branch version:** Push a commit directly to the
|
|
|
|
newly-created release branch that increments the Python package version in
|
|
|
|
python/ray/__init__.py and src/ray/raylet/main.cc. See this
|
|
|
|
`sample commit for bumping the release branch version`_.
|
2019-09-26 10:30:37 -07:00
|
|
|
|
2019-12-16 23:57:42 -08:00
|
|
|
3. **Update the master branch version:**
|
|
|
|
|
|
|
|
For a new minor release (e.g., 0.7.0): Create a pull request to
|
2019-12-16 15:51:39 -08:00
|
|
|
increment the dev version in of the master branch. See this
|
|
|
|
`sample PR for bumping a minor release version`_. **NOTE:** Not all of
|
|
|
|
the version numbers should be replaced. For example, ``0.7.0`` appears in
|
|
|
|
this file but should not be updated.
|
2019-06-10 23:04:01 -07:00
|
|
|
|
2019-12-16 23:57:42 -08:00
|
|
|
For a new micro release (e.g., 0.7.1): No action is required.
|
2019-09-06 00:03:57 -07:00
|
|
|
|
2020-02-24 21:18:53 -08:00
|
|
|
4. **Testing:** Before releasing, the following sets of tests should be run.
|
|
|
|
The results of each of these tests for previous releases are checked in
|
|
|
|
under ``doc/dev/release_tests``, and should be compared against to identify
|
|
|
|
any regressions.
|
2019-06-10 23:04:01 -07:00
|
|
|
|
2019-12-16 15:51:39 -08:00
|
|
|
1. Long-running tests
|
|
|
|
|
|
|
|
.. code-block:: bash
|
|
|
|
|
|
|
|
ray/ci/long_running_tests/README.rst
|
|
|
|
|
|
|
|
Follow the instructions to kick off the tests and check the status of the workloads
|
|
|
|
These tests should run for at least 24 hours (printing new iterations and CPU load
|
|
|
|
stable in the AWS console).
|
|
|
|
|
2020-02-24 21:18:53 -08:00
|
|
|
2. Multi-node regression tests
|
2019-06-10 23:04:01 -07:00
|
|
|
|
2020-02-24 21:18:53 -08:00
|
|
|
Follow the same instruction as long running stress tests. The large scale distributed
|
|
|
|
regression tests identify potential performance regression in distributed environment.
|
|
|
|
The following test should be ran:
|
2019-06-10 23:04:01 -07:00
|
|
|
|
2020-02-24 21:18:53 -08:00
|
|
|
- ``ci/regression_test/rllib_regression-tests`` run the compact regression test for rllib.
|
|
|
|
- ``ci/regression_test/rllib_stress_tests`` run multinode 8hr IMPALA trial.
|
|
|
|
- ``ci/regression_test/stress_tests`` contains two tests: ``many_tasks`` and ``dead_actors``.
|
|
|
|
Each of the test runs on 105 spot instances.
|
2019-06-10 23:04:01 -07:00
|
|
|
|
2019-12-16 15:51:39 -08:00
|
|
|
Make sure that these pass. For the RLlib regression tests, see the comment on the
|
2019-11-13 12:22:55 -08:00
|
|
|
file for the pass criteria. For the rest, it will be obvious if they passed.
|
2019-06-10 23:04:01 -07:00
|
|
|
This will use the autoscaler to start a bunch of machines and run some tests.
|
2019-07-15 14:46:54 -07:00
|
|
|
**Caution!**: By default, the stress tests will require expensive GPU instances.
|
2019-06-10 23:04:01 -07:00
|
|
|
|
2019-12-16 15:51:39 -08:00
|
|
|
The summaries printed by each test should be checked in under
|
|
|
|
``doc/dev/release_logs/<version>``.
|
2019-09-26 10:30:37 -07:00
|
|
|
|
2019-12-16 15:51:39 -08:00
|
|
|
3. Microbenchmarks
|
2019-09-26 10:30:37 -07:00
|
|
|
|
2020-02-24 21:18:53 -08:00
|
|
|
Run the ``ci/microbenchmark`` with the commit. Under the hood, the session will
|
|
|
|
run `ray microbenchmark` on an `m4.16xl` instance running `Ubuntu 18.04` with `Python 3`
|
|
|
|
to get the latest microbenchmark numbers.
|
2019-12-16 15:51:39 -08:00
|
|
|
|
2019-12-17 15:56:50 -08:00
|
|
|
The results should be checked in under ``doc/dev/release_logs/<version>``.
|
2019-09-26 10:30:37 -07:00
|
|
|
|
2019-06-10 23:04:01 -07:00
|
|
|
5. **Resolve release-blockers:** If a release blocking issue arises, there are
|
|
|
|
two ways the issue can be resolved: 1) Fix the issue on the master branch and
|
|
|
|
cherry-pick the relevant commit (using ``git cherry-pick``) onto the release
|
2019-09-06 00:03:57 -07:00
|
|
|
branch (recommended). 2) Revert the commit that introduced the bug on the
|
|
|
|
release branch (using ``git revert``), but not on the master (not recommended).
|
2019-06-10 23:04:01 -07:00
|
|
|
|
|
|
|
These changes should then be pushed directly to the release branch.
|
2019-04-25 00:05:19 -07:00
|
|
|
|
2019-12-16 15:51:39 -08:00
|
|
|
6. **Create a GitHub release:** Create a `GitHub release`_. This should include
|
|
|
|
**release notes**. Copy the style and formatting used by previous releases.
|
|
|
|
Create a draft of the release notes containing information about substantial
|
|
|
|
changes/updates/bugfixes and their PR numbers. Once you have a draft, send it
|
|
|
|
out to other Ray developers (especially those who contributed heavily during
|
|
|
|
this release) for feedback. At the end of the release note, you should also
|
2020-02-24 21:18:53 -08:00
|
|
|
add a list of contributors. Make sure Ray, Tune, RLLib, Autoscaler are
|
|
|
|
capitalized correctly.
|
2019-12-16 15:51:39 -08:00
|
|
|
|
|
|
|
Run ``doc/dev/get_contributors.py`` to generate the list of commits corresponding
|
2020-02-24 21:18:53 -08:00
|
|
|
to this release and the formatted list of contributors.
|
2019-12-16 15:51:39 -08:00
|
|
|
You will need to provide a GitHub personal access token
|
|
|
|
(github.com -> settings -> developer settings -> personal access tokens).
|
|
|
|
|
|
|
|
.. code-block:: bash
|
|
|
|
|
|
|
|
# Must be run from inside the Ray repository.
|
|
|
|
pip install PyGitHub tqdm
|
|
|
|
python get_contributors.py --help
|
|
|
|
python get_contributors.py \
|
|
|
|
--access-token=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx \
|
|
|
|
--prev-release-commit="<COMMIT_SHA>" \
|
|
|
|
--curr-release-commit="<COMMIT_SHA>"
|
|
|
|
|
|
|
|
7. **Download all the wheels:** Now the release is ready to begin final
|
2019-04-25 00:05:19 -07:00
|
|
|
testing. The wheels are automatically uploaded to S3, even on the release
|
2019-05-23 18:06:07 -07:00
|
|
|
branch. To test, ``pip install`` from the following URLs:
|
2019-01-30 19:37:48 -08:00
|
|
|
|
|
|
|
.. code-block:: bash
|
|
|
|
|
2019-04-25 00:05:19 -07:00
|
|
|
export RAY_HASH=... # e.g., 618147f57fb40368448da3b2fb4fd213828fa12b
|
2019-05-23 18:06:07 -07:00
|
|
|
export RAY_VERSION=... # e.g., 0.7.0
|
2020-02-24 21:18:53 -08:00
|
|
|
|
|
|
|
# Linux Wheels
|
2019-06-10 23:04:01 -07:00
|
|
|
pip install -U https://s3-us-west-2.amazonaws.com/ray-wheels/releases/$RAY_VERSION/$RAY_HASH/ray-$RAY_VERSION-cp35-cp35m-manylinux1_x86_64.whl
|
|
|
|
pip install -U https://s3-us-west-2.amazonaws.com/ray-wheels/releases/$RAY_VERSION/$RAY_HASH/ray-$RAY_VERSION-cp36-cp36m-manylinux1_x86_64.whl
|
|
|
|
pip install -U https://s3-us-west-2.amazonaws.com/ray-wheels/releases/$RAY_VERSION/$RAY_HASH/ray-$RAY_VERSION-cp37-cp37m-manylinux1_x86_64.whl
|
2020-02-24 21:18:53 -08:00
|
|
|
|
|
|
|
# Mac Wheels
|
|
|
|
pip install -U https://s3-us-west-2.amazonaws.com/ray-wheels/releases/$RAY_VERSION/$RAY_HASH/ray-$RAY_VERSION-cp35-cp35m-macosx_10_13_intel.whl
|
|
|
|
pip install -U https://s3-us-west-2.amazonaws.com/ray-wheels/releases/$RAY_VERSION/$RAY_HASH/ray-$RAY_VERSION-cp36-cp36m-macosx_10_13_intel.whl
|
|
|
|
pip install -U https://s3-us-west-2.amazonaws.com/ray-wheels/releases/$RAY_VERSION/$RAY_HASH/ray-$RAY_VERSION-cp37-cp37m-macosx_10_13_intel.whl
|
2019-04-25 00:05:19 -07:00
|
|
|
|
2019-12-16 15:51:39 -08:00
|
|
|
8. **Upload to PyPI Test:** Upload the wheels to the PyPI test site using
|
|
|
|
``twine``.
|
2018-08-29 00:06:33 -07:00
|
|
|
|
|
|
|
.. code-block:: bash
|
|
|
|
|
2019-12-16 15:51:39 -08:00
|
|
|
# Downloads all of the wheels to the current directory.
|
2020-03-27 11:14:15 -07:00
|
|
|
RAY_VERSION=<version> RAY_HASH=<commit_sha> bash download_wheels.sh
|
2018-08-29 00:06:33 -07:00
|
|
|
|
2019-12-16 15:51:39 -08:00
|
|
|
# Will ask for your PyPI test credentials and require that you're a maintainer
|
|
|
|
# on PyPI test. If you are not, ask @robertnishihara to add you.
|
|
|
|
pip install twine
|
|
|
|
twine upload --repository-url https://test.pypi.org/legacy/ *.whl
|
2018-08-29 00:06:33 -07:00
|
|
|
|
2019-12-16 15:51:39 -08:00
|
|
|
Test that you can install the wheels with pip from the PyPI test repository:
|
2018-08-29 00:06:33 -07:00
|
|
|
|
|
|
|
.. code-block:: bash
|
|
|
|
|
2019-10-24 11:13:37 -07:00
|
|
|
# First install ray normally because installing from test.pypi.org won't
|
|
|
|
# be able to install some of the other dependencies.
|
|
|
|
pip install ray
|
|
|
|
pip uninstall ray
|
|
|
|
|
2018-08-29 00:06:33 -07:00
|
|
|
pip install --index-url https://test.pypi.org/simple/ ray
|
|
|
|
|
|
|
|
Then start Python, make sure you can ``import ray`` and run some simple Ray
|
|
|
|
scripts. Make sure that it is finding the version of Ray that you just
|
|
|
|
installed by checking ``ray.__version__`` and ``ray.__file__``.
|
|
|
|
|
2020-01-28 14:14:33 -08:00
|
|
|
Do this at least for MacOS and Linux.
|
2018-08-29 00:06:33 -07:00
|
|
|
|
2019-12-16 15:51:39 -08:00
|
|
|
9. **Upload to PyPI:** Now that you've tested the wheels on the PyPI test
|
2018-08-29 00:06:33 -07:00
|
|
|
repository, they can be uploaded to the main PyPI repository. Be careful,
|
|
|
|
**it will not be possible to modify wheels once you upload them**, so any
|
2019-12-16 15:51:39 -08:00
|
|
|
mistake will require a new release.
|
2018-08-29 00:06:33 -07:00
|
|
|
|
|
|
|
.. code-block:: bash
|
|
|
|
|
2019-12-16 15:51:39 -08:00
|
|
|
# Will ask for your real PyPI credentials and require that you're a maintainer
|
|
|
|
# on real PyPI. If you are not, ask @robertnishihara to add you.
|
|
|
|
twine upload --repository-url https://upload.pypi.org/legacy/ *.whl
|
2018-08-29 00:06:33 -07:00
|
|
|
|
2019-12-16 15:51:39 -08:00
|
|
|
Now, try installing from the real PyPI mirror. Verify that the correct version is
|
|
|
|
installed and that you can run some simple scripts.
|
2018-08-29 00:06:33 -07:00
|
|
|
|
|
|
|
.. code-block:: bash
|
|
|
|
|
|
|
|
pip install -U ray
|
|
|
|
|
2020-02-24 21:18:53 -08:00
|
|
|
10. **Create a point release on readthedocs page:** In the `read the docs project page`_,
|
|
|
|
mark the release branch as "active" so there is a point release for the documentation.
|
|
|
|
Add @richardliaw to add you if you don't have access.
|
|
|
|
|
|
|
|
11. **Improve the release process:** Find some way to improve the release
|
2019-06-10 23:04:01 -07:00
|
|
|
process so that whoever manages the release next will have an easier time.
|
2019-05-23 18:06:07 -07:00
|
|
|
|
2019-12-16 15:51:39 -08:00
|
|
|
.. _`sample PR for bumping a minor release version`: https://github.com/ray-project/ray/pull/6303
|
|
|
|
.. _`sample commit for bumping the release branch version`: https://github.com/ray-project/ray/commit/a39325d818339970e51677708d5596f4b8f790ce
|
|
|
|
.. _`GitHub release`: https://github.com/ray-project/ray/releases
|
2020-02-24 21:18:53 -08:00
|
|
|
.. _`read the docs project page`: https://readthedocs.org/projects/ray/
|