Skip to content
This repository was archived by the owner on Sep 19, 2022. It is now read-only.

Add watch function for PyTorchJob python Client API #246

Merged
merged 1 commit into from
Jan 3, 2020

Conversation

jinchihe
Copy link
Member

@jinchihe jinchihe commented Jan 2, 2020

Add watch function for the PyTorchJob python API to watch key info, such as status, like kubeflow get pytorchjob.
The PR is going to add watch function (added one more option watch=Flase) for PyTorchJob python Client get() and waiting_for_job() API, as below:

pytorch_client = PyTorchJobClient()
pytorch_client.wait_for_job('pytorch-dist-mnist-gloo', watch=True)
NAME                           STATE                TIME                          
pytorch-dist-mnist-gloo        Created              2020-01-02T09:37:48Z          
pytorch-dist-mnist-gloo        Running              2020-01-02T09:37:58Z          
pytorch-dist-mnist-gloo        Running              2020-01-02T09:37:58Z          
pytorch-dist-mnist-gloo        Running              2020-01-02T09:37:58Z          
pytorch-dist-mnist-gloo        Running              2020-01-02T09:37:58Z          
pytorch-dist-mnist-gloo        Running              2020-01-02T09:37:58Z          
pytorch-dist-mnist-gloo        Running              2020-01-02T09:37:58Z          
pytorch-dist-mnist-gloo        Succeeded            2020-01-02T09:42:47Z          

Due to CI tests failed while verifying code-gen, I also updated related files. Thanks.

@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

You'll be able to see Jupyter notebook diff and discuss changes. Powered by ReviewNB.

@coveralls
Copy link

coveralls commented Jan 2, 2020

Coverage Status

Coverage remained the same at 22.97% when pulling d539495 on jinchihe:add_watch_api into f117363 on kubeflow:master.

@johnugeorge
Copy link
Member

Can you make similar changes that you added for tf operator?

@jinchihe
Copy link
Member Author

jinchihe commented Jan 3, 2020

Can you make similar changes that you added for tf operator?

Yes, I'm going to do similar functions as for TFJob Python API. Thanks @johnugeorge

@jinchihe jinchihe changed the title Add watch function for PyTorchJob python Client API WIP: Add watch function for PyTorchJob python Client API Jan 3, 2020
@johnugeorge
Copy link
Member

Once you remove WIP status, I can review.
Thanks for your contribution

@jinchihe jinchihe changed the title WIP: Add watch function for PyTorchJob python Client API Add watch function for PyTorchJob python Client API Jan 3, 2020
@jinchihe
Copy link
Member Author

jinchihe commented Jan 3, 2020

Once you remove WIP status, I can review.

@johnugeorge Great thanks! That's ready for reviewing now.

@johnugeorge
Copy link
Member

Thanks
/lgtm

@johnugeorge
Copy link
Member

/approve

@k8s-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: johnugeorge

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot merged commit 94197a2 into kubeflow:master Jan 3, 2020
@jinchihe jinchihe deleted the add_watch_api branch January 3, 2020 05:34
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants