Skip to content
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

[Dependencies] Remove kubernetes requirement #36333

Merged

Conversation

architkulkarni
Copy link
Contributor

Why are these changes needed?

The kubernetes package is installed with ray["all"] but it's currently only used in two places:

  1. A helper function for converting units
  2. The GCS FT on K8s release test:
    from kubernetes import client, config, watch

This PR removes kubernetes from Ray's dependencies and removes it from the Ray docker image. This change is needed to reduce the overall package size of ray["all"].

For the helper function, we vendor it from the upstream.

For the release test, kubernetes is installed separately:

. I've also added it to release/requirements.txt to be safe.

Related issue number

Closes #36331

Checks

  • I've signed off every commit(by using the -s flag, i.e., git commit -s) in this PR.
  • I've run scripts/format.sh to lint the changes in this PR.
  • I've included any doc changes needed for https://docs.ray.io/en/master/.
    • I've added any new APIs to the API Reference. For example, if I added a
      method in Tune, I've added it in doc/source/tune/api/ under the
      corresponding .rst file.
  • I've made sure the tests are passing. Note that there might be a few flaky tests, see the recent failures at https://flakey-tests.ray.io/
  • Testing Strategy
    • Unit tests
    • Release tests
    • This PR is not tested :(

Signed-off-by: Archit Kulkarni <architkulkarni@users.noreply.github.com>
Signed-off-by: Archit Kulkarni <architkulkarni@users.noreply.github.com>
Signed-off-by: Archit Kulkarni <architkulkarni@users.noreply.github.com>
Signed-off-by: Archit Kulkarni <architkulkarni@users.noreply.github.com>
Signed-off-by: Archit Kulkarni <architkulkarni@users.noreply.github.com>
Signed-off-by: Archit Kulkarni <architkulkarni@users.noreply.github.com>
Signed-off-by: Archit Kulkarni <architkulkarni@users.noreply.github.com>
@architkulkarni
Copy link
Contributor Author

Assigning @iycheng as a codeowner from Ray Core

Comment on lines 1 to 5
# Source:
# https://github.com/kubernetes-client/python/blob/master/kubernetes/utils/quantity.py
from decimal import Decimal, InvalidOperation


Copy link
Contributor

Choose a reason for hiding this comment

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

This LGTM as this code has remained pretty much static in the upstream.

Copy link
Contributor

@ijrsvt ijrsvt left a comment

Choose a reason for hiding this comment

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

LGTM!

Copy link
Contributor

@edoakes edoakes left a comment

Choose a reason for hiding this comment

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

stamping dependency change

Signed-off-by: Archit Kulkarni <architkulkarni@users.noreply.github.com>
@architkulkarni
Copy link
Contributor Author

huggingface_text_classification broken on master, unrelated
rllib:learning_tests_two_step_game_qmix flaky on master, unrelated
RLlib memory leak failure Error in download: java.io.IOException: Error downloading [https://dl.google.com/go/go1.18.linux-amd64.tar.gz] unrelated
RLlib failure nested_action_spaces_ppo_torch unrelated
Build images failure flaky on master

@architkulkarni architkulkarni added the tests-ok The tagger certifies test failures are unrelated and assumes personal liability. label Jun 12, 2023
@architkulkarni architkulkarni merged commit b935406 into ray-project:master Jun 12, 2023
@architkulkarni architkulkarni deleted the remove-kubernetes-import branch June 12, 2023 23:30
arvind-chandra pushed a commit to lmco/ray that referenced this pull request Aug 31, 2023
The kubernetes package is installed with ray["all"] but it's currently only used in two places:

A helper function for converting units
The GCS FT on K8s release test:
ray/release/k8s_tests/run_gcs_ft_on_k8s.py

Line 4 in 4070624

 from kubernetes import client, config, watch
This PR removes kubernetes from Ray's dependencies and removes it from the Ray docker image. This change is needed to reduce the overall package size of ray["all"].

For the helper function, we vendor it from the upstream.

For the release test, kubernetes is installed separately:

ray/release/k8s_tests/app_config.yaml

Line 13 in 4070624

 - kubernetes
. I've also added it to release/requirements.txt to be safe.
Related issue number
Closes ray-project#36331

---------

Signed-off-by: Archit Kulkarni <architkulkarni@users.noreply.github.com>
Signed-off-by: e428265 <arvind.chandramouli@lmco.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tests-ok The tagger certifies test failures are unrelated and assumes personal liability.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Core] Remove kubernetes from dependencies
6 participants