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

Update ContainerOp in pipeline 07_container_components_pipeline #2

Open
strangiato opened this issue May 10, 2024 · 0 comments
Open

Comments

@strangiato
Copy link
Member

There is no longer a containerop in v2.

07_container_components_pipeline.py executes with the following error:

AttributeError: module 'kfp.dsl' has no attribute 'ContainerOp'. Did you mean: 'ContainerSpec'?

Full stack trace:

$ python pipelines/07_container_components_pipeline.py 
Traceback (most recent call last):
  File "/Users/my-user/code/rhai/kubeflow-pipelines-examples/pipelines/07_container_components_pipeline.py", line 20, in <module>
    @kfp.dsl.pipeline(
     ^^^^^^^^^^^^^^^^^
  File "/Users/my-user/code/rhai/kubeflow-pipelines-examples/.venv/lib/python3.11/site-packages/kfp/dsl/pipeline_context.py", line 65, in pipeline
    return component_factory.create_graph_component_from_func(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/my-user/code/rhai/kubeflow-pipelines-examples/.venv/lib/python3.11/site-packages/kfp/dsl/component_factory.py", line 673, in create_graph_component_from_func
    return graph_component.GraphComponent(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/my-user/code/rhai/kubeflow-pipelines-examples/.venv/lib/python3.11/site-packages/kfp/dsl/graph_component.py", line 58, in __init__
    pipeline_outputs = pipeline_func(*args_list)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/my-user/code/rhai/kubeflow-pipelines-examples/pipelines/07_container_components_pipeline.py", line 29, in add_pipeline
    add_op = kfp.dsl.ContainerOp(  # noqa: F841
             ^^^^^^^^^^^^^^^^^^^
AttributeError: module 'kfp.dsl' has no attribute 'ContainerOp'. Did you mean: 'ContainerSpec'?```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant