-
Notifications
You must be signed in to change notification settings - Fork 5.9k
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
[requirements] Split requirements into different tiers [build_base] #36808
Conversation
Signed-off-by: Kai Fricke <kai@anyscale.com>
Signed-off-by: Kai Fricke <kai@anyscale.com>
Signed-off-by: Kai Fricke <kai@anyscale.com>
Signed-off-by: Kai Fricke <kai@anyscale.com>
Signed-off-by: Kai Fricke <kai@anyscale.com>
Signed-off-by: Kai Fricke <kai@anyscale.com>
Signed-off-by: Kai Fricke <kai@anyscale.com>
Signed-off-by: Kai Fricke <kai@anyscale.com>
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.
It probably doesn't make sense to have all these in an air
directory, I wonder if we can just put these directly in requirements
instead.
@pcmoritz PTAL and leave any suggestions on how to organize this.
Signed-off-by: Kai Fricke <kai@anyscale.com>
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 feel that this setup is going to be quite hard to maintain over time. like if I add a dependency, or require pinning a transient dependency, how do I know / keep track which file I should update? I think in the long run:
if we use bazel to compile the dependencies, this is basically what bazel will do. sadly, bazel does not have ver great support for multi-python+multi-platform, or at least it will take a lot of efforts. that said, the dependency graph compilation for third-party dependencies is basically done by pip, which means we can do it in our own way if we want to. maybe the challenging part is actually "properly splitting ray into sub components". |
Signed-off-by: Kai Fricke <kai@anyscale.com>
It's what we're doing right now, but the renaming actually enables e.g. dependabot to make updates easier in the future.
Again no real change here, usually we pin these where the core dependency is defined.
The goal of these restructurings is not to solve the dependency issues for different ray components. It is mostly about improving the state of our docker containers. We are shipping docker containers, and we ship installed dependencies in them. Users are asking for lists of these dependencies to be able to install them in their own setups, and they expect that these dependency versions are also tested - which is currently not the case. This renaming and the follow-up (pip-compile) will ensure consistent versions between the docker images and CI. For actual test-only dependencies (in this PR the |
Signed-off-by: Kai Fricke <kai@anyscale.com>
Signed-off-by: Kai Fricke <kai@anyscale.com>
Signed-off-by: Kai Fricke <kai@anyscale.com>
# Conflicts: # docker/ray-ml/Dockerfile # python/requirements/ml/dl-cpu-requirements.txt
Signed-off-by: Kai Fricke <kai@anyscale.com>
Signed-off-by: Kai Fricke <kai@anyscale.com>
Signed-off-by: Kai Fricke <kai@anyscale.com>
Signed-off-by: Kai Fricke <kai@anyscale.com>
Signed-off-by: Kai Fricke <kai@anyscale.com>
…ld_base] (ray-project#36983) Following up from ray-project#36808, this PR now uses the compiled constraints file in the installation of the dependencies in CI and in the ray-ml docker images. In result, both environments will share the same versions of (sub)dependencies. Signed-off-by: Kai Fricke <kai@anyscale.com>
…ld_base] (ray-project#36983) Following up from ray-project#36808, this PR now uses the compiled constraints file in the installation of the dependencies in CI and in the ray-ml docker images. In result, both environments will share the same versions of (sub)dependencies. Signed-off-by: Kai Fricke <kai@anyscale.com>
…ld_base] (ray-project#36983) Following up from ray-project#36808, this PR now uses the compiled constraints file in the installation of the dependencies in CI and in the ray-ml docker images. In result, both environments will share the same versions of (sub)dependencies. Signed-off-by: Kai Fricke <kai@anyscale.com> Signed-off-by: NripeshN <nn2012@hw.ac.uk>
…ay-project#36808) This PR splits the requirements files into different tiers: - `air/core-requirements.txt` - these are the most important requirements (tier 1) - `air/[library]-requirements.txt` - these are pinned dependencies for libraries (tier 2+3) - `air/[library]-test-requirements.txt` - these are pinned test-dependencies for libraries (tier 4) (tier 2 and 3 may get merged into one tier, tbd). This does not change any packages and should not affect installed packages in docker or CI. The naming format was chosen to be compatible with dependabot. In a follow-up PR, we will compile the tier 1-3 dependencies to ensure all CI runners and Docker images run on the same dependency versions. This PR will split existing requirement files. In total, there will be 4 more such files (`rllib-test-requirements.txt`, `tune-test-requirements.txt`, `train-test-requirements.txt`, `docker/ray-docker-requirements.txt` Signed-off-by: Kai Fricke <kai@anyscale.com> Signed-off-by: e428265 <arvind.chandramouli@lmco.com>
…ld_base] (ray-project#36983) Following up from ray-project#36808, this PR now uses the compiled constraints file in the installation of the dependencies in CI and in the ray-ml docker images. In result, both environments will share the same versions of (sub)dependencies. Signed-off-by: Kai Fricke <kai@anyscale.com> Signed-off-by: e428265 <arvind.chandramouli@lmco.com>
…ld_base] (ray-project#36983) Following up from ray-project#36808, this PR now uses the compiled constraints file in the installation of the dependencies in CI and in the ray-ml docker images. In result, both environments will share the same versions of (sub)dependencies. Signed-off-by: Kai Fricke <kai@anyscale.com> Signed-off-by: Victor <vctr.y.m@example.com>
Why are these changes needed?
This PR splits the requirements files into different tiers:
air/core-requirements.txt
- these are the most important requirements (tier 1)air/[library]-requirements.txt
- these are pinned dependencies for libraries (tier 2+3)air/[library]-test-requirements.txt
- these are pinned test-dependencies for libraries (tier 4)(tier 2 and 3 may get merged into one tier, tbd).
This does not change any packages and should not affect installed packages in docker or CI.
The naming format was chosen to be compatible with dependabot.
In a follow-up PR, we will compile the tier 1-3 dependencies to ensure all CI runners and Docker images run on the same dependency versions.
This PR will split existing requirement files. In total, there will be 4 more such files (
rllib-test-requirements.txt
,tune-test-requirements.txt
,train-test-requirements.txt
,docker/ray-docker-requirements.txt
Background
We currently ship different subdependencies in different environments. The packages installed in CI differ between jobs, and the packages in the docker images differ between python versions and image type (ray vs ray-ml).
The reason for that is in those environments only a subset of dependencies are installed. Generally the more dependencies are installed in one go, the more restrictive the subdependencies are and the older the shipped versions. This can lead to a situation where we ship packages in our docker images that are not tested on CI and can actually fail.
The plan going forward is to pip-compile the full list of dependencies into a constraints file. This constraints file is then used in subsequent jobs to install the packages. By utilizing the constraints file we can ensure that the package versions match between CI and docker containers, but we don't have to install all packages in all environments.
Related issue number
Checks
git commit -s
) in this PR.scripts/format.sh
to lint the changes in this PR.method in Tune, I've added it in
doc/source/tune/api/
under thecorresponding
.rst
file.