-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
SDK/Components/PythonContainerOp - Switch from dict to ComponentSpec #396
SDK/Components/PythonContainerOp - Switch from dict to ComponentSpec #396
Conversation
/test presubmit-e2e-test |
implementation=ImplementationSpec( | ||
container=ContainerSpec( | ||
image=target_image, | ||
#command=['python3', program_file], #TODO: Include the command line |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We don't need the command right? The entrypoint is already built into the image. So remove the commented line?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Command line needs to be known for the operations to be manageable. I think we should promote this. In this particular case this would require small refactoring.
/lgtm |
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: Ark-kun 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 |
1 similar comment
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: Ark-kun 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 |
component_spec = ComponentSpec( | ||
name=component_name, | ||
description=component_description, | ||
inputs=[InputSpec(name=input_name, type='str') for input_name in input_names], #TODO: Chnage type to actual type |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is no need to change the type to actual type.
The component built already does the serialization, thus the types here are all strings.
This changes the interface between PythonContainerOp and materializer from schema-less dict to
ComponentSpec
. This ensures the interface is not silently broken.This change is