pipelines icon indicating copy to clipboard operation
pipelines copied to clipboard

No experiment gets created by kfp.Client()

Open farshadsm opened this issue 3 years ago • 8 comments

Hi, I've deployed Kubeflow onto an AWS EKS cluster. I tried to create and run Kubeflow pipeline using notebook UI inside Kubeflow cluster. However, no experiment gets created. I followed the example in https://www.kubeflow.org/docs/components/pipelines/sdk/build-pipeline/ to build the pipeline. Furthermore, I followed the instructions in https://www.kubeflow.org/docs/distributions/aws/pipeline/ to authenticate Kubeflow Pipeline using SDK inside cluster. Below, you can find how I did the authentication:

authservice_session='<cookie I've obtained from notebook url which is http://localhost:8080/_/jupyter/>' ALB_ADDRESS='<Value of Address field obtained by executing command "kubectl get ingress -n istio-system">' HOST=ALB_ADDRESS+'/pipeline' client = kfp.Client(host=HOST, cookies=authservice_session)

When I executed the following command, I got an error. client.create_run_from_pipeline_package( pipeline_file='pipeline.yaml', arguments={ 'url': 'https://storage.googleapis.com/ml-pipeline-playground/iris-csv-files.tar.gz' })

The error is:

---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
<ipython-input-22-56afc4f05e24> in <module>
      2     pipeline_file='pipeline.yaml',
      3     arguments={
----> 4         'url': 'https://storage.googleapis.com/ml-pipeline-playground/iris-csv-files.tar.gz'
      5     })

/usr/local/lib/python3.6/dist-packages/kfp/_client.py in create_run_from_pipeline_package(self, pipeline_file, arguments, run_name, experiment_name, namespace)
    739                                 '%Y-%m-%d %H-%M-%S'))
    740     experiment = self.create_experiment(name=experiment_name, namespace=namespace)
--> 741     run_info = self.run_pipeline(experiment.id, run_name, pipeline_file, arguments)
    742     return RunPipelineResult(self, run_info)
    743 

/usr/local/lib/python3.6/dist-packages/kfp/_client.py in run_pipeline(self, experiment_id, job_name, pipeline_package_path, params, pipeline_id, version_id)
    548       import IPython
    549       html = ('<a href="%s/#/runs/details/%s" target="_blank" >Run details</a>.'
--> 550               % (self._get_url_prefix(), response.run.id))
    551       IPython.display.display(IPython.display.HTML(html))
    552     return response.run

AttributeError: 'NoneType' object has no attribute 'id'

farshadsm avatar May 12 '21 20:05 farshadsm

Can you please try some other Client methods like list_runs? There might be auth error.

Ark-kun avatar May 13 '21 01:05 Ark-kun

I executed client.list_runs(), where I defined client object in my first message, and I got the following result: {'experiments': None, 'next_page_token': None, 'total_size': None}

When I executed client.create_experiment(name="kubeflow"), no valid experiment was created. I checked the Experiment details, and I found following error message: "error":"Failed to authorize the request.: Failed to authorize with the experiment ID.: Failed to get namespace from experiment ID.: ResourceNotFoundError: Experiment None not found."

I also think the problem is with authentication. I followed https://www.kubeflow.org/docs/distributions/aws/pipeline/ to authenticate Kubeflow Pipeline using SDK inside cluster. But it seems it didn't work out properly for me.

farshadsm avatar May 13 '21 15:05 farshadsm

@PatrickXYS Hello Patrick, this looks like authentication issue, would you like to take a look?

zijianjoy avatar May 14 '21 00:05 zijianjoy

I think I need to follow the instructions in this url, https://www.kubeflow.org/docs/distributions/aws/authentication/authentication/, to provide TLS authentication for kubeflow. I'll try it and will let you know the outcome.

farshadsm avatar May 14 '21 16:05 farshadsm

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Aug 28 '21 17:08 stale[bot]

I'm not working on this issue since unassign myself

PatrickXYS avatar Dec 06 '21 19:12 PatrickXYS

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Apr 17 '22 07:04 stale[bot]

Any progress on this ?

amirhessam88 avatar Sep 07 '22 20:09 amirhessam88

I think I need to follow the instructions in this url, https://www.kubeflow.org/docs/distributions/aws/authentication/authentication/, to provide TLS authentication for kubeflow. I'll try it and will let you know the outcome.

It looks like that page is no longer maintained. Did you figure out how to enable TLS authentication on Kubeflow?

InterferencePattern avatar Oct 06 '22 19:10 InterferencePattern

Closing this issue. No activity for more than a year.

/close

rimolive avatar Apr 03 '24 21:04 rimolive

@rimolive: Closing this issue.

In response to this:

Closing this issue. No activity for more than a year.

/close

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

google-oss-prow[bot] avatar Apr 03 '24 21:04 google-oss-prow[bot]