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

feat(sdk): Extend SDK client with disable/delete run methods #6754

Merged
28 changes: 28 additions & 0 deletions sdk/python/kfp/_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -1056,6 +1056,34 @@ def __repr__(self):
)
return RunPipelineResult(self, run_info)

def delete_run(self, run_id):
johnmacnamararseg marked this conversation as resolved.
Show resolved Hide resolved
"""Delete run.

Args:
run_id: id of the run.

Returns:
Object. If the method is called asynchronously, returns the request thread.

Throws:
johnmacnamararseg marked this conversation as resolved.
Show resolved Hide resolved
Exception if run is not found.
"""
return self._job_api.delete_job(id=run_id)

def disable_run(self, run_id):
"""Disable run.

Args:
run_id: id of the pipeline.

Returns:
Object. If the method is called asynchronously, returns the request thread.

Throws:
Exception if pipeline is not found.
"""
return self._job_api.disable_job(id=run_id)

def list_runs(self,
page_token='',
page_size=10,
Expand Down